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

secrecy: add SecretString replacement; ?Sized bounds #1213

Merged
merged 1 commit into from
Sep 17, 2024

Conversation

tony-iqlusion
Copy link
Member

Adds a type alias for SecretBox<str> to replace the previous SecretString type and provide a better migration path.

To support this, we need to add ?Sized bounds to SecretBox so SecretBox<str> is valid.

Adds a type alias for `SecretBox<str>` to replace the previous
`SecretString` type and provide a better migration path.

To support this, we need to add `?Sized` bounds to `SecretBox` so
`SecretBox<str>` is valid.
@tony-iqlusion tony-iqlusion force-pushed the secrecy/secret-string-replacement branch from 6a28b6a to fd19727 Compare September 17, 2024 19:16
@tony-iqlusion tony-iqlusion merged commit 23d134d into main Sep 17, 2024
10 checks passed
@tony-iqlusion tony-iqlusion deleted the secrecy/secret-string-replacement branch September 17, 2024 19:55
@tony-iqlusion tony-iqlusion changed the title secrecy: add SecretString replacement; ?Sized bounds secrecy: add SecretString replacement; ?Sized bounds Sep 17, 2024
@tony-iqlusion tony-iqlusion mentioned this pull request Sep 17, 2024
@wiktor-k
Copy link

It seems one significant change is that previously (in 0.8) SecretString implemented CloneableSecret and the new SecretString cannot be cloned. Is this by design or a simple omission?

@tony-iqlusion
Copy link
Member Author

@wiktor-k fixed in #1217

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

Successfully merging this pull request may close these issues.

2 participants