SPB Git

Repository Public

QYV-AUD-004.json 1.8 KB 21 lines json

1{2  "id": "QYV-AUD-004",3  "title": "Two low-severity items reported by the project's Semgrep rules: `try!` in SignedEIP1559Transaction.raw and `==` on a decapsulated probe secret",4  "severity": "low",5  "cvss_vector": "",6  "cvss_score": null,7  "cwe": "CWE-248",8  "masvs": "MASVS-CODE-4",9  "area": "wallet",10  "location": "Sources/QyvoraEthereum/Transaction.swift:153",11  "tool": "semgrep",12  "rule": "qyvora-force-try / qyvora-nonconstant-compare",13  "status": "fixed",14  "fix_commit": "ad48602",15  "regression_test": "Tests/QyvoraEthereumTests/AuditRegressionTests.swift (rawEncodingIsTheSignedFieldsFollowedByTheSignature); security/tests PropertyAuditTests (EIP-1559 sign → raw → decode round trip); QyvoraIdentityTests",16  "description": "(1) SignedEIP1559Transaction.raw rebuilt the list of signed fields by decoding the transaction's own RLP payload with `try!`. The decoder is stricter than the encoder in principle (nesting limit, canonical forms), so the absence of a trap rested on an unstated invariant between the two; a trap there would have crashed the application while building a transaction to broadcast. No input that triggers it was found (fuzzing and the round-trip property tests pass), hence low. (2) Identity(privateEncoding:) compared the secret decapsulated from a throw-away probe encapsulation with `==`. Both values are produced and discarded inside the check and protect nothing; the comparison is now uniform with the rest of the code. Impact of (2): none identified.",17  "recommendation": "Fixed: raw is built from the transaction's own field list (no decode, no `try!`); the probe comparison uses ConstantTime.equal.",18  "evidence": "Semgrep custom rules qyvora-parsers (try!) and qyvora-crypto (non-constant-time comparison), run of 2026-12-04.",19  "fingerprint": ""20}21
Files main
Menu

Theme