Ecosyste.ms: Advisories

An open API service providing security vulnerability metadata for many open source software ecosystems.

Security Advisories: GSA_kwCzR0hTQS12eDhtLTZmaHctcGNjd84AA1aW

@node-saml/node-saml's validatePostRequestAsync does not include checkTimestampsValidityError

Summary

The lack of checking of current timestamp allows a LogoutRequest XML to be reused multiple times even when the current time is past the NotOnOrAfter.

Details

It was noticed that in the validatePostRequestAsync() flow in saml.js, the current timestamp is never checked. This could present a vulnerability where a user who has an XML LogoutRequest could validated it if the IssueInstance and the NotOnOrAfter are valid along with valid credentials (signature, certificate etc.).

PoC

I was able to validate a sample valid LogoutRequest XML multiple times through postman by sending it to my endpoint regardless if the current present time was past the NotOnOrAfter time. After some further testing, it seems that only the IssueInstance is checked against NotOnOrAfter. Not sure if this was the intended behaviour but I believe having a never expiring valid LogoutRequest could be dangerous.

Impact

This could impact the user where they would be logged out from an expired LogoutRequest. In bigger contexts, if LogoutRequests are sent out in mass to different SPs, this could impact many users on a large scale.

Permalink: https://github.com/advisories/GHSA-vx8m-6fhw-pccw
JSON: https://advisories.ecosyste.ms/api/v1/advisories/GSA_kwCzR0hTQS12eDhtLTZmaHctcGNjd84AA1aW
Source: GitHub Advisory Database
Origin: Unspecified
Severity: Moderate
Classification: General
Published: 9 months ago
Updated: 6 months ago


CVSS Score: 5.3
CVSS vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

Identifiers: GHSA-vx8m-6fhw-pccw, CVE-2023-40178
References: Repository: https://github.com/node-saml/node-saml
Blast Radius: 10.2

Affected Packages

npm:@node-saml/node-saml
Dependent packages: 14
Dependent repositories: 85
Downloads: 552,945 last month
Affected Version Ranges: < 4.0.5
Fixed in: 4.0.5
All affected versions: 4.0.0, 4.0.1, 4.0.2, 4.0.3, 4.0.4
All unaffected versions: 4.0.5, 5.0.0