Replace chrono with httpdate internally #361
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Remove chrono as a dependency to avoid any connection to the transitive CVE-2020-26235 in
time
0.2. This also requires removing chrono from the public API ofCookieBuilder
(added in #349), which is probably for the best anyway before it is released so that we aren't tied to it. ExposeSystemTime
types instead, which both chrono andtime
are compatible with, should the consumer of the API choose to use either of those crates.Replace formatting and parsing of HTTP date formats with the aptly-named
httpdate
crate, which implements exactly those two operations and no more. As a side benefit this reduces our total transitive dependency count by 3 when thecookies
feature is enabled.This has been the only thing holding back a 1.6.0 release with #349 in it, since CVE-2020-26235 was brought to wider attention shortly after its merge and I've been thinking on how to best address that concern before the API is released and can't be changed without a BC break.