diff --git a/src/main.rs b/src/main.rs index ade0a58..e75cc84 100644 --- a/src/main.rs +++ b/src/main.rs @@ -221,11 +221,15 @@ fn format_output( }), ) } else { - ( - "unrecoverable".to_string(), - Some("all pairs have s1 == s2".to_string()), - None, - ) + let reason = match vuln.attack_type.as_str() { + "nonce-reuse" => "all signature pairs have identical s values", + "polynonce" => "elimination polynomial roots did not produce a valid key", + _ if vuln.attack_type.starts_with("biased-nonce") => { + "lattice reduction did not yield the private key" + } + _ => "recovery did not produce a valid key", + }; + ("unrecoverable".to_string(), Some(reason.to_string()), None) }; vuln_outputs.push(VulnerabilityOutput {