-
Notifications
You must be signed in to change notification settings - Fork 15
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
Support loading password from file #24
Comments
@Sohalt that is a good idea. Also being able to read the password from an environment variable would be nice to have. FWIW, the password can also be in the form of a MD5 hash. echo -n "my-password" | md5sum | cut -f 1 -d " " |
An md5sum is not very cryptographically secure. But yes, in general using a secure cryptographic hash function would also work. But I'd prefer the separate file. |
@Sohalt not sure if it was clear but hashes are already supported in the configuration file. |
The whole discussion about hashed passwords misses the point. |
True, I didn't think things trough. Mpdscribble obviously needs to authenticate, so it needs a secret, which ideally should not be in the configuration file, to allow the configuration to be shared and readable, as e.g. in the case of NixOS. |
Hi, just migrated to mpd (from mopidy) and over there most passwords can be queried from secret-tool and stored in the system's keyring, this approach adds a dependency in the form of secret. Another possibility was raised in an old issue (#12), by getting the password from a user defined utility like Gnu pass or secret-tool or even gpg, this approach is quite flexible and it is used in some email utilities like mbsync. The best approach will be dependent on how the configuration is parsed, but it would be a great addition since having the password in plain text is not very secure, regardless of being md5sum hashed or not. |
It would be helpful to support loading the password from a separate file, because it would allow to keep secrets separate from configuration.
Specifically it would help with using mpdscribble as a NixOS module, because NixOS auto-generates a world readable configuration file, which, in the current setup, has to contain the password.
Something like:
The text was updated successfully, but these errors were encountered: