Description
In bitvm-node/node/src/rpc_service/auth.rs, the authentication hash covers only the auth domain (b"bitvm2-auth") and the timestamp string. It does not bind the HTTP method, path, or body, so a valid signature can be replayed across endpoints within the 300-second replay window (AUTH_WINDOW_SECS).
Affected component(s)
bitvm-node — rpc_service/auth.rs
- Scope area: Bridge State Machine (API)
Steps to reproduce
- Capture a valid signed request (e.g.
pegout).
- Within the 300s window, replay the same signature against
send_challenge (or vice versa).
Proof of concept
hasher.update(AUTH_DOMAIN); // b"bitvm2-auth"
hasher.update(timestamp_str.as_bytes()); // does not bind method/path/body!
Security impact
Cross-endpoint signature replay within the replay window. An attacker cannot forge a signature; they must intercept a valid one in the window, so this is Low/Medium. Recommended fix: include method, path, and a body hash in the signed payload.
Description
In
bitvm-node/node/src/rpc_service/auth.rs, the authentication hash covers only the auth domain (b"bitvm2-auth") and the timestamp string. It does not bind the HTTP method, path, or body, so a valid signature can be replayed across endpoints within the 300-second replay window (AUTH_WINDOW_SECS).Affected component(s)
bitvm-node—rpc_service/auth.rsSteps to reproduce
pegout).send_challenge(or vice versa).Proof of concept
Security impact
Cross-endpoint signature replay within the replay window. An attacker cannot forge a signature; they must intercept a valid one in the window, so this is Low/Medium. Recommended fix: include method, path, and a body hash in the signed payload.