Unintended alteration of what the NFT represents (e.g. token URI, payload, artistic content)
Brief Description
The SignatureVerifier library uses abi.encodePacked() to hash multiple dynamic strings (name, symbol, URI) for signature verification. This enables boundary-shift collision attacks where an attacker can craft different metadata combinations that produce identical hashes, allowing them to reuse a valid signature for unauthorized collection metadata.
When abi.encodePacked() concatenates multiple dynamic types (strings, bytes), it doesn't include length delimiters. This allows boundary-shift collisions:
Collection is created with unauthorized metadata that was never explicitly signed by the platform.
Immediate Fix
Replace abi.encodePacked with abi.encode in all signature verification functions:
Proof of Concept
Show PoC (bash script, Solidity tests, and sample output)
PoC Run Script (bash)
PoC Solidity Tests
Sample Output (abbreviated)
The PoC run confirms collisions with abi.encodePacked and shows that using abi.encode prevents them. Example excerpts:
Multiple collision examples: collisions found for pairs like ("Official","NFT") vs ("OfficialN","FT").
Real contract vulnerability: checkAccessTokenInfo and checkCreditTokenInfo hash results collide as demonstrated.
Fix verified: abi.encode produces different hashes for colliding inputs.
Full logs and test output are contained in the original PoC run (included above).
Recommendations
Replace all uses of abi.encodePacked for signature/hashing of multiple dynamic types with abi.encode to preserve unambiguous encoding and prevent boundary-shift collisions.
Review other places in the codebase where multiple dynamic types are packed and used for signature verification or critical identifiers, and apply the same fix where applicable.
References
Solidity docs on ABI encoding: https://docs.soliditylang.org
Example fix applied in immediate fix code snippet above