GHSA-rrfw-hg9m-j47h: Github.com/russellhaering/goxmldsig Signature Validation Bypass Vulnerability

CRITICAL
CWE-347
Published
Advisory Summary

GHSA-rrfw-hg9m-j47h is a CRITICAL signature validation bypass vulnerability (CWE-347: Improper Verification of Cryptographic Signature) affecting Github.com/russellhaering/goxmldsig libraries in the Go ecosystem. The issue involves signature validation bypass. Remediation is available by upgrading affected packages to version 0.4.2.

GHSA-rrfw-hg9m-j47h at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-rrfw-hg9m-j47h
Severity CRITICAL
CVSS v3.1 Base Score N/A
CWE Classification CWE-347: Improper Verification of Cryptographic Signature
Affected Product Github.com/russellhaering/goxmldsig
Package Ecosystem Go
Published Date
Last Updated

How to Fix GHSA-rrfw-hg9m-j47h

To remediate this vulnerability, upgrade all affected Github.com/russellhaering/goxmldsig dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/russellhaering/goxmldsig fixed: 0.4.2
Upgrade github.com/russellhaering/goxmldsig to 0.4.2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/russellhaering/goxmldsig

How to Check if You Are Affected

To determine whether your application is affected by GHSA-rrfw-hg9m-j47h, inspect your project dependencies for Github.com/russellhaering/goxmldsig:

inspect dependencies for github.com/russellhaering/goxmldsig

Analyze the terminal output to locate any version of Github.com/russellhaering/goxmldsig in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.4.2), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-347: Improper Verification of Cryptographic Signature, where the product does not verify, or incorrectly verifies, the cryptographic signature for data. In Github.com/russellhaering/goxmldsig, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact An authentication bypass exists in the [goxmldsig](https://github.com/russellhaering/goxmldsig/security/advisories/GHSA-q547-gmf8-8jr7) this library uses to determine if SAML assertions are genuine. An attacker could craft a SAML response that would appear to be valid but would not have been genuinely issued by the IDP. ### Patches Version 0.4.2 bumps the dependency which should fix the issue. ### For more information Please see [the advisory in goxmldsig](https://github.com/russellhaering/goxmldsig/security/advisories/GHSA-q547-gmf8-8jr7) ## Credits The original vulnerability was discovered by @jupenur. Thanks to @russellhaering for the heads up.

GHSA-rrfw-hg9m-j47h Affected Github.com/russellhaering/goxmldsig Versions

1 component(s)
Fixed Versions:
0.4.2
Product / Package Ecosystem Affected Versions Fixed Version
github.com/russellhaering/goxmldsig
Go
< 0.4.2
0.4.2

References

Frequently Asked Questions

What is GHSA-rrfw-hg9m-j47h?
GHSA-rrfw-hg9m-j47h is a security vulnerability in Github.com/russellhaering/goxmldsig involving Signature Validation Bypass under CWE-347: Improper Verification of Cryptographic Signature.
Which Github.com/russellhaering/goxmldsig versions are affected?
Affected versions include releases prior to 0.4.2 across affected packages: github.com/russellhaering/goxmldsig.
What version fixes GHSA-rrfw-hg9m-j47h?
Upgrading to 0.4.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/russellhaering/goxmldsig affected?
Yes, github.com/russellhaering/goxmldsig is affected in releases prior to 0.4.2. Upgrade your dependency to 0.4.2 or later.
What CWE is associated with GHSA-rrfw-hg9m-j47h?
GHSA-rrfw-hg9m-j47h is classified under CWE-347: Improper Verification of Cryptographic Signature (The product does not verify, or incorrectly verifies, the cryptographic signature for data.).
How can I check Go dependencies for GHSA-rrfw-hg9m-j47h?
Run the dependency tree command: 'inspect dependencies for github.com/russellhaering/goxmldsig'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-rrfw-hg9m-j47h",
  "modified" : "2021-10-08T21:25:26Z",
  "published" : "2021-05-24T16:59:42Z",
  "aliases" : [ ],
  "summary" : "Signature Validation Bypass",
  "details" : "### Impact\n\nAn authentication bypass exists in the [goxmldsig](https://github.com/russellhaering/goxmldsig/security/advisories/GHSA-q547-gmf8-8jr7) this library uses to determine if SAML assertions are genuine. An attacker could craft a SAML response that would appear to be valid but would not have been genuinely issued by the IDP.\n\n### Patches\n\nVersion 0.4.2 bumps the dependency which should fix the issue.\n\n### For more information\n\nPlease see [the advisory in goxmldsig](https://github.com/russellhaering/goxmldsig/security/advisories/GHSA-q547-gmf8-8jr7)\n\n## Credits\n\nThe original vulnerability was discovered by @jupenur. Thanks to @russellhaering for the heads up.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/russellhaering/goxmldsig"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.4.2"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 0.4.1"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/crewjam/saml/security/advisories/GHSA-rrfw-hg9m-j47h"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/russellhaering/goxmldsig"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-347" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2021-05-21T22:23:03Z",
    "nvd_published_at" : null
  }
}