Problem
Storing sensitive tokens in plaintext files is not great. It is quite bad I'd argue, especially since crates.io doesn't even support 2FA yet, so anyone who gets their hands on the token can publish whatever.
While cargo supports things like libsecret on Linux, I had no idea about it and even if I tried, it doesn't seem to work unless I read the docs and add this to the configuration file:
[registry]
global-credential-providers = ["cargo:libsecret"]
Proposed Solution
Support for canonical credential providers on various platforms should, ideally, be the default way with plaintext file being the fallback.
Otherwise, at least ask the user where they want to store the token rather than silently storing it in a plaintext file.
Notes
No response
Problem
Storing sensitive tokens in plaintext files is not great. It is quite bad I'd argue, especially since crates.io doesn't even support 2FA yet, so anyone who gets their hands on the token can publish whatever.
While cargo supports things like
libsecreton Linux, I had no idea about it and even if I tried, it doesn't seem to work unless I read the docs and add this to the configuration file:Proposed Solution
Support for canonical credential providers on various platforms should, ideally, be the default way with plaintext file being the fallback.
Otherwise, at least ask the user where they want to store the token rather than silently storing it in a plaintext file.
Notes
No response