Skip to content

Go: Mark WebSocket reads as untrusted #96

@ghost

Description

CVE

This query has not been tested against all lgtm projects yet. So, there is no CVE found using this PR.

Report

This PR marks data read from a websocket connection as a source of untrusted input. It models the following golang packages.

  1. gorilla websocket (11.7k stars)
  2. golang/x/net/websocket (2.1k stars)
  3. gobwas websocket (3.1k stars)
  4. nhooyr.io websocket (1.3k stars)

Apart from these, the initial version of this PR also modelled the write functions. However, since there were concerns with the false positives which may have increased due to them, the writes were removed leaving only the reads.

This PR includes library as well as query tests, the qhelp file along with well documented code.

Link to the PR:[github/codeql-go#109]

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