VAITP Dataset

← Back to the dataset

CVE-2022-44049

Stark Bank Python ECDSA <2.0.1 allows signature forgery by not checking non-zero signatures

  • CVSS 9.8
  • CWE-434 Unrestricted Upload of File with Dangerous Type
  • Design Defects
  • Remote

The d8s-python for python, as distributed on PyPI, included a potential code-execution backdoor inserted by a third party. A potential code execution backdoor inserted by third parties is the democritus-grammars package. The affected version of d8s-htm is 0.1.0.

CVSS base score
9.8
Published
2022-11-07
OWASP
A06 Vulnerable and Outdated Components
Orthogonal defect classification
Function
Code defect classification
Incorrect Functionality
Category
Design Defects
Subcategory
Vulnerable and Outdated Components
Accessibility scope
Remote
Impact
Arbitrary Code Execution
Fixed by upgrading
Yes

Solution

Update d8s-python to version 0.1.1 or higher.

Vulnerable code sample

# Vulnerable version of the d8s-python package that may execute malicious code

# Importing a potentially malicious package
import democritus_grammars  # This package could contain harmful code

def execute_malicious_code():
    # This function could execute code from the imported package
    democritus_grammars.execute()  # Hypothetical function that executes harmful code

if __name__ == "__main__":
    execute_malicious_code()

Patched code sample

# Fixed version of the d8s-python package to remove potential code execution backdoor

# Instead of importing potentially malicious code, we ensure we import only trusted modules
def safe_function():
    # Implementation of safe functionality without external dependencies
    print("This is a safe function.")

if __name__ == "__main__":
    safe_function()

Cite this entry

@misc{vaitp:cve202244049,
  title        = {{Stark Bank Python ECDSA <2.0.1 allows signature forgery by not checking non-zero signatures}},
  author       = {Bogaerts, Fr\'ed\'eric and Ivaki, Naghmeh and Fonseca, Jos\'e},
  year         = {2022},
  note         = {VAITP Python Vulnerability Dataset, entry CVE-2022-44049},
  howpublished = {\url{https://netpack.pt/vaitp/vulnerability/CVE-2022-44049/}}
}
Introducing the "VAITP dataset": a specialized repository of Python vulnerabilities and patches, meticulously compiled for the use of the security research community. As Python's prominence grows, understanding and addressing potential security vulnerabilities become crucial. Crafted by and for the cybersecurity community, this dataset offers a valuable resource for researchers, analysts, and developers to analyze and mitigate the security risks associated with Python. Through the comprehensive exploration of vulnerabilities and corresponding patches, the VAITP dataset fosters a safer and more resilient Python ecosystem, encouraging collaborative advancements in programming security.

The supreme art of war is to subdue the enemy without fighting.

Sun Tzu – “The Art of War”

:: Shaping the future through research and ingenuity ::