# Untyped data signing

Rigor signed raw untyped data without domain separator, chain ID, or type hash, allowing signature replay across projects, chains, functions, and phishing DApps.

- Payout: Contest reward
- Severity: high
- Program: Rigor Protocol
- Credited: Lambda
- Disclosed: 2022-09-12
- Write-up quality: 7/10
- Original: https://github.com/code-423n4/2022-08-rigor-findings/issues/75
- Library page: https://bugbountylibrary.com/r/c4%3A2022-08-rigor%3AH-01
- Tags: domain:web3 impact:integrity kind:contest platform:code4rena sev:high tech:evm tech:solidity technique:source-review vuln:auth-bypass vuln:signature-replay

**Target:** Solidity contracts (Community.sol, Project.sol, Disputes.sol) signature verification
**Root cause:** Application data is hashed and signed without EIP-712 domain separator, chain ID, or function type hash, so signatures are not bound to contract, chain, or function.
**Steps:**
1. Identify functions like `updateProjectHash`, `updateTaskHash`, `inviteContractor`, `setComplete` that verify signatures over raw encoded data.
2. For cross-project replay: owner Bob signs `updateProjectHash(_hash, _nonce=0)` on project A; attacker replays same `_data`/`_signature` to a fresh project B owned by Bob with nonce 0.
3. For cross-chain replay: replay Ethereum signatures on a Polygon deployment where addresses match.
4. For cross-function replay: submit `inviteContractor` data/signature to `setComplete` (reverts only if no matching task exists).
5. For phishing: trick owner into signing identical-format payload via a benign DApp.
**How found:** Code review of signature verification paths noticed raw `keccak256(abi.encode(...))` without domain separator, chain ID, or type hash, then reasoned about replay surfaces.
**Exploitation:** Attacker captures or obtains a valid signature (from mempool, prior tx, or phishing) and replays it against another Rigor project, another chain, or another function where nonce/state aligns, causing unauthorized state changes such as hash updates or task completion.
**Escalation:** Chaining replay across projects/chains/functions and phishing DApps broadens the set of exploitable signatures.
**Insight:** When auditing signature checks, enumerate every signed struct and check for domain separator, chain ID, contract address, and function type hash; missing any one enables a distinct replay class.
