-
Notifications
You must be signed in to change notification settings - Fork 68
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
Allow base64 encoded bytes as argument to --secret #144
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ceharris Thanks for the PR, and congrats on your first contribution to a rust project! Just a few notes, otherwise I think this PR is a good addition!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the review delay @ceharris! Just a few notes for the tests, otherwise this looks great!
Thanks again for this @ceharris! There are a few other breaking changes on |
Thanks to you for making jwt-cli! Happy to contribute a little... |
Summary
To simplify use in scripted applications, this PR adds a new
b64:
format prefix for the--secret
argument, to allow the secret to be specified as base64-encoded bytes.The same outcome can be achieved by writing the bytes of the key to a file and using
--secret @filename
, but directly supporting base64 avoids the need to write the key to a file.Example
N.B. -- this is my first experience contributing to a Rust-based project.