Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

k5test should use passed in paths, even when system krb5 is present #2

Open
DirectXMan12 opened this issue Mar 29, 2016 · 1 comment
Labels

Comments

@DirectXMan12
Copy link
Member

Currently, the _discover_path function in realm.py does the following:

  1. checks $PATH with which, return that if present
  2. if not found on $PATH, check in the user-specified paths dict, and return that if present
  3. if not found in the user-specified paths dict, return some default path (/usr/sbin/xyz or /usr/bin/xyz).

This means that system copies installed on $PATH would always be chosen over manually specified paths in the constructor. Instead, the logic should probably instead be:

  1. check in the user-specified paths dict, and return that if present
  2. if not found in the user-specified paths dict, check $PATH with which, return that if present
  3. if not found on $PATH, return some default value

This way, if a user manually specifies a path for some binary, we use that even if there's a system copy installed on $PATH (note that the default value is necessary since /usr/sbin isn't generally on $PATH for non-root users)

@svmhdvn
Copy link
Contributor

svmhdvn commented Jun 18, 2024

This should be resolved with #31, as is recommended by both Heimdal and MIT krb5. Passing in a custom KRB5CONFIG=/path/to/krb5-config should work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants