Advisories

Vyper through 0.5.0b1 Literal Value Substitution via Multi-byte Characters

Go back
Severity
medium
Date
Affecting
  • vyper >= 0.1.0b1, < 0.1.0b12

  • vyper >= 0.1.0b14, < 0.1.0b15

  • vyper >= 0.4.1, <= 0.5.0b1

CWE
  • CWE-176 Improper Handling of Unicode Encoding
CVSS
6.0
CVSS V4 Vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N
Credit
hyeon-Sec
Description
Vyper 0.1.0b1 before 0.1.0b12, 0.1.0b14, and 0.4.1 through 0.5.0b1 mix character-based line offsets with Python's UTF-8 byte col_offset values in vyper/ast/parse.py, so multi-byte characters shift the source slices used to reconstruct later numeric literals. An attacker contributing source with non-ASCII identifiers that NFKC-normalize to ASCII, or an invisible byte-order mark, can silently substitute addresses, integers or other constants in compiled code.

Ready to get Started?

Explore VulnCheck, a next-generation Cyber Threat Intelligence platform, which provides exploit and vulnerability intelligence to help you prioritize and remediate vulnerabilities that matter.
  • Vulnerability Prioritization
    Prioritize vulnerabilities that matter based on the threat landscape and defer vulnerabilities that don't.
  • Early Warning System
    Real-time alerting of changes in the vulnerability landscape so that you can take action before the attacks start.