Skip to content

Conversation

@vivekkhimani
Copy link
Collaborator

No description provided.

import yaml


yaml.load(Loader=yaml.Loader)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fukkkdsafsadfadsadddblahDetected a possible YAML deserialization vulnerability. yaml.unsafe_load, yaml.Loader, yaml.CLoader, and yaml.UnsafeLoader are all known to be unsafe methods of deserializing YAML. An attacker with control over the YAML input could create special YAML input that allows the attacker to run arbitrary Python code. This would allow the attacker to steal files, download and install malware, or otherwise take over the machine. Use yaml.safe_load or yaml.SafeLoader instead. blah blah.blah

Suggested change
yaml.load(Loader=yaml.Loader)
yaml.load(Loader=yaml.Loader)
Ignore this finding from avoid-pyyaml-load.


yaml.load(Loader=yaml.Loader)

yaml.unsafe_load("something")
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fukkkdsafsadfadsadddblahDetected a possible YAML deserialization vulnerability. yaml.unsafe_load, yaml.Loader, yaml.CLoader, and yaml.UnsafeLoader are all known to be unsafe methods of deserializing YAML. An attacker with control over the YAML input could create special YAML input that allows the attacker to run arbitrary Python code. This would allow the attacker to steal files, download and install malware, or otherwise take over the machine. Use yaml.safe_load or yaml.SafeLoader instead. blah blah.blah

Suggested change
yaml.unsafe_load("something")
yaml.safe_load("something")
Ignore this finding from avoid-pyyaml-load.

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

Successfully merging this pull request may close these issues.

2 participants