Commit 24c715ed authored by Robert Czechowski's avatar Robert Czechowski
Browse files

Fix Oauth school selector: Correctly format hash hex bytes

parent 4d325768
......@@ -1137,12 +1137,13 @@ fn oauth<C>(req: &mut Request) -> IronResult<Response>
println!("{}", string_to_hash);
let hashed_string = hasher.result();
let hash: String = format!("{:X?}", hashed_string).chars()
let hash: String = format!("{:02X?}", hashed_string).chars()
.filter(|c| c.is_ascii_alphanumeric())
println!("{}", hash);
let params = [("schoolId", school_id.clone()), ("hash", hash)];
println!("{:?}", params);
let res =;
let school_data: OAuthSchoolData =
res.expect("network error").json().expect("malformed json");
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment