Skip to content

[ruby]: add YAML/Psych/Plist unsafe deserialization sinks #732

Closed
@am0o0

Description

@am0o0

Query PR

github/codeql#12301
github/codeql#13431

Language

Ruby

CVE(s) ID list

CWE

CWE-502: Deserialization of Untrusted Data

Report

  1. Deserialization of Untrusted Data from a yaml serialized document
  2. with user controllable inputs such as yaml strings or yaml files, it is possible to execute code.
  3. I add some additional sinks and taint tracking steps of paramiko library.
  4. with Psych >= 4.0.0 Psych.load is secure by default, so I think the current codeql std lib for ruby should change it to. There are many other sinks that developers can use it in their applications, so I put my time to find all insecure ways/methods that currently are dangerous.

Are you planning to discuss this vulnerability submission publicly? (Blog Post, social networks, etc).

  • Yes
  • No

Blog post link

A series of Blog posts will be forthcoming soon!

Metadata

Metadata

Assignees

No one assigned

    Labels

    All For OneSubmissions to the All for One, One for All bounty

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions