mirror of
https://github.com/fafhrd91/actix-web
synced 2025-06-25 06:39:22 +02:00
actix-http: Update sha-1
to 0.9 (#1586)
This commit is contained in:
@ -5,6 +5,8 @@
|
||||
### Changed
|
||||
|
||||
* Migrate cookie handling to `cookie` crate.
|
||||
* Update `sha-1` to 0.9
|
||||
* MSRV is now 1.41.1
|
||||
|
||||
## [2.0.0-alpha.4] - 2020-05-21
|
||||
|
||||
|
@ -76,7 +76,7 @@ rand = "0.7"
|
||||
regex = "1.3"
|
||||
serde = "1.0"
|
||||
serde_json = "1.0"
|
||||
sha-1 = "0.8"
|
||||
sha-1 = "0.9"
|
||||
slab = "0.4"
|
||||
serde_urlencoded = "0.6.1"
|
||||
time = { version = "0.2.7", default-features = false, features = ["std"] }
|
||||
|
@ -208,10 +208,10 @@ pub fn hash_key(key: &[u8]) -> String {
|
||||
use sha1::Digest;
|
||||
let mut hasher = sha1::Sha1::new();
|
||||
|
||||
hasher.input(key);
|
||||
hasher.input(WS_GUID.as_bytes());
|
||||
hasher.update(key);
|
||||
hasher.update(WS_GUID.as_bytes());
|
||||
|
||||
base64::encode(hasher.result().as_ref())
|
||||
base64::encode(&hasher.finalize())
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
Reference in New Issue
Block a user