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

Always enable hpke/std feature (was: Re-expose hpke/std feature) #15

Merged
merged 1 commit into from
Jul 28, 2022

Conversation

tgeoghegan
Copy link
Contributor

Adds a feature hpke-std which enables feature std on crate hpke.
This allows hpke-dispatch clients who use default-features = false
to re-enable hpke/std alongside whatever KEMs, KDFs and AEADs they
want.

@tgeoghegan tgeoghegan requested review from a team and jbr as code owners July 28, 2022 18:45
@jbr
Copy link
Contributor

jbr commented Jul 28, 2022

Are there known circumstances in users of this crate wouldn't want this enabled? Are people using this crate in a no-std context?

@jbr
Copy link
Contributor

jbr commented Jul 28, 2022

Unless we explicitly want to make sure we support no-std rust, I'd be inclined just to add this feature for everyone for now.

@tgeoghegan
Copy link
Contributor Author

So you're arguing to do this instead:

hpke = { version = "0.9.0", default-features = false, features = ["std"] }

...and continue to use hpke-dispatch's features to gate turning on other features on hpke? Sure, that makes sense to me.

@jbr
Copy link
Contributor

jbr commented Jul 28, 2022

Yeah exactly that. One fewer feature for users to have to toggle back on (assuming they probably want it on)

Copy link
Contributor

@jbr jbr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

Unconditionally enable `hpke`'s `std` feature so that `hpke-dispatch`
clients who use `default-features = false` can still get the
`std::error::Error` implementation on `HpkeError`.
@tgeoghegan tgeoghegan force-pushed the timg/hpke-std-feature branch from a697b9a to 145db44 Compare July 28, 2022 19:00
@tgeoghegan tgeoghegan changed the title Re-expose hpke/std feature Always enable hpke/std feature (was: Re-expose hpke/std feature) Jul 28, 2022
@tgeoghegan tgeoghegan merged commit 51e6a56 into main Jul 28, 2022
@branlwyd branlwyd deleted the timg/hpke-std-feature branch July 28, 2022 19:02
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.

3 participants