feat: u2f-sign
This commit is contained in:
@@ -107,16 +107,14 @@ impl Command for CommandImpl {
|
|||||||
information!("Public key: {}", base64::encode(&public_key));
|
information!("Public key: {}", base64::encode(&public_key));
|
||||||
information!("Signed message: {}", base64::encode(&msg));
|
information!("Signed message: {}", base64::encode(&msg));
|
||||||
|
|
||||||
let authorization = u2f::authorization::parse_sign_response(
|
let authorization_result = u2f::authorization::parse_sign_response(
|
||||||
app_id.to_string(),
|
app_id.to_string(),
|
||||||
client_data,
|
client_data,
|
||||||
public_key,
|
public_key,
|
||||||
sign_data,
|
sign_data,
|
||||||
);
|
);
|
||||||
match authorization {
|
let authorization = opt_result!(authorization_result, "Parse authorization failed: {}");
|
||||||
Ok(authorization) => success!("Parse authorization success, counter: {}", authorization.counter),
|
success!("Parse authorization success, counter: {}", authorization.counter);
|
||||||
Err(e) => failure!("Parse authorization failed: {}", e),
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Ok(None)
|
Ok(None)
|
||||||
|
|||||||
Reference in New Issue
Block a user