CVE-2020-5261: Sustainsys.Saml2 Missing Token Replay Detection Vulnerability

HIGH
Advisory Identifier: GHSA-g6j2-ch25-5mmv
CVSS 8.2
CWE-294
Published
Advisory Summary

CVE-2020-5261 is a HIGH (CVSS 8.2) missing token replay detection vulnerability (CWE-294: Authentication Bypass by Capture-replay) affecting Sustainsys.Saml2 libraries in the NuGet ecosystem. The issue involves missing token replay detection in saml2 authentication services for asp.net. Remediation is available by upgrading affected packages to version 2.5.0.

CVE-2020-5261 at a Glance

CVE Identifier CVE-2020-5261
GHSA Identifier GHSA-g6j2-ch25-5mmv
Severity HIGH
CVSS v3.1 Base Score 8.2
CWE Classification CWE-294: Authentication Bypass by Capture-replay
Affected Product Sustainsys.Saml2
Package Ecosystem NuGet
Published Date
Last Updated

Security Impact

CVSS: 8.2

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity High (I:H)
Availability None (A:N)

How to Fix CVE-2020-5261

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

Sustainsys.Saml2 fixed: 2.5.0
Upgrade Sustainsys.Saml2 to 2.5.0
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 Sustainsys.Saml2

How to Check if You Are Affected

To determine whether your application is affected by CVE-2020-5261, inspect your project dependencies for Sustainsys.Saml2:

inspect dependencies for Sustainsys.Saml2

Analyze the terminal output to locate any version of Sustainsys.Saml2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.5.0), 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-294: Authentication Bypass by Capture-replay, where a capture-replay flaw exists when the design of the product makes it possible for a malicious user to sniff network traffic and bypass authentication by replaying it to the server in question to the same effect as the original message (or with minor changes). In Sustainsys.Saml2, 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 Token Replay Detection is an important defence in depth measure for Single Sign On solutions. In all previous 2.X versions, the Token Replay Detection is not properly implemented. Note that version 1.0.1 is not affected. It has a correct Token Replay Implementation and is safe to use. ### Patches The 2.5.0 version is patched. ### Workarounds There are no workarounds with existing versions. Fixing the issue requires code updates. ### References https://en.wikipedia.org/wiki/Replay_attack ### For more information If you have any questions or comments about this advisory: * Comment on #711. * Email us at [security@sustainsys.com](mailto:security@susatinsys.com) if you think that there are further security issues.

CVE-2020-5261 Affected Sustainsys.Saml2 Versions

1 component(s)
Fixed Versions:
2.5.0
Product / Package Ecosystem Affected Versions Fixed Version
Sustainsys.Saml2
NuGet
≥ 2.0.0
< 2.5.0
2.5.0

References

Frequently Asked Questions

What is CVE-2020-5261?
CVE-2020-5261 is a security vulnerability in Sustainsys.Saml2 involving Missing Token Replay Detection in Saml2 Authentication services for ASP.NET under CWE-294: Authentication Bypass by Capture-replay.
Which Sustainsys.Saml2 versions are affected?
Affected versions include releases prior to 2.5.0 across affected packages: Sustainsys.Saml2.
What version fixes CVE-2020-5261?
Upgrading to 2.5.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is Sustainsys.Saml2 affected?
Yes, Sustainsys.Saml2 is affected in releases prior to 2.5.0. Upgrade your dependency to 2.5.0 or later.
What is the CVSS score of CVE-2020-5261?
CVE-2020-5261 has a CVSS v3.1 base score of 8.2 (HIGH) with vector string CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:N.
What CWE is associated with CVE-2020-5261?
CVE-2020-5261 is classified under CWE-294: Authentication Bypass by Capture-replay (A capture-replay flaw exists when the design of the product makes it possible for a malicious user to sniff network traffic and bypass authentication by replaying it to the server in question to the same effect as the original message (or with minor changes).).
How can I check NuGet dependencies for CVE-2020-5261?
Run the dependency tree command: 'inspect dependencies for Sustainsys.Saml2'. 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-g6j2-ch25-5mmv",
  "modified" : "2021-01-08T20:24:58Z",
  "published" : "2020-03-25T16:52:49Z",
  "aliases" : [ "CVE-2020-5261" ],
  "summary" : "Missing Token Replay Detection in Saml2 Authentication services for ASP.NET",
  "details" : "### Impact\nToken Replay Detection is an important defence in depth measure for Single Sign On solutions. In all previous 2.X versions, the Token Replay Detection is not properly implemented. \n\nNote that version 1.0.1 is not affected. It has a correct Token Replay Implementation and is safe to use.\n\n### Patches\nThe 2.5.0 version is patched.\n\n### Workarounds\nThere are no workarounds with existing versions. Fixing the issue requires code updates.\n\n### References\nhttps://en.wikipedia.org/wiki/Replay_attack\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Comment on #711.\n* Email us at [security@sustainsys.com](mailto:security@susatinsys.com) if you think that there are further security issues.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "NuGet",
      "name" : "Sustainsys.Saml2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.0.0"
      }, {
        "fixed" : "2.5.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/Sustainsys/Saml2/security/advisories/GHSA-g6j2-ch25-5mmv"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-5261"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/Sustainsys/Saml2/issues/711"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/Sustainsys/Saml2/commit/e58e0a1aff2b1ead6aca080b7cdced55ee6d5241"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-294" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-03-25T01:16:34Z",
    "nvd_published_at" : "2020-03-25T02:15:00Z"
  }
}