{"id":"CVE-2023-40178","aliases":["CVE-2023-40178","GHSA-vx8m-6fhw-pccw"],"related":[],"kind":"vulnerability","state":"published","title":"@node-saml/node-saml's validatePostRequestAsync does not include checkTimestampsValidityError","summary":"Node-SAML is a SAML library not dependent on any frameworks that runs in Node. 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. 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. This issue was patched in version 4.0.5.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Node-SAML is a SAML library not dependent on any frameworks that runs in Node. 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. 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. This issue was patched in version 4.0.5.","source":"cvelist"},{"lang":"en","text":"### Summary\n\nThe lack of checking of current timestamp allows a LogoutRequest XML to be reused multiple times even when the current time is past the NotOnOrAfter. \n\n### Details\n\nIt 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.). \n\n### PoC\n\nI 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.\n\n### Impact\n\nThis 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.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Node-SAML es una librería SAML que no depende de ningún framework que se ejecute en Node. La falta de comprobación de la marca de tiempo actual permite que un LogoutRequest XML se reutilice varias veces incluso cuando el tiempo actual ha pasado el NotOnOrAfter. Esto podría afectar al usuario, que podría cerrar la sesión con un LogoutRequest caducado. En contextos más grandes, si los LogoutRequests son enviados en masa a diferentes SPs, esto podría afectar a muchos usuarios a gran escala. Este problema fue corregido en la versión 4.0.5.","source":"nvd"}],"published":"2023-08-21T20:13:05.000Z","modified":"2026-09-10T03:49:57.758Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","score":5.3,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","score":5.3,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","score":5.3,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","score":5.3,"rating":"MEDIUM"}],"cwes":["CWE-347","CWE-613"],"affected":[{"ranges":[{"version":"< 4.0.5","status":"affected"}],"vendor":"node-saml","product":"node-saml","source":"cvelist"},{"ranges":[{"type":"custom","introduced":"0","fixed":"4.0.5","status":"affected"}],"vendor":"node-saml","product":"node-saml","cpe":"cpe:2.3:a:node-saml:node-saml:*:*:*:*:*:*:*:*","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"4.0.5"}],"ecosystem":"npm","package":"@node-saml/node-saml","purl":"pkg:npm/%40node-saml/node-saml","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"4.0.5"}],"vendor":"node_saml_project","product":"node_saml","cpe":"cpe:2.3:a:node_saml_project:node_saml:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://github.com/node-saml/node-saml/security/advisories/GHSA-vx8m-6fhw-pccw","tags":["vendor-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/node-saml/node-saml/commit/045e3b9c54211fdb95f96edf363679845b195cec","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/node-saml/node-saml/releases/tag/v4.0.5","tags":["release-notes","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-40178","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/node-saml/node-saml","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"yes","technicalImpact":"partial","date":"2024-10-02T18:49:43.816Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2023-40178","url":"https://www.cve.org/CVERecord?id=CVE-2023-40178","licence":"CVE Terms of Use","modified":"2024-10-02T18:56:08.820Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-vx8m-6fhw-pccw","url":"https://github.com/advisories/GHSA-vx8m-6fhw-pccw","licence":"CC-BY-4.0","modified":"2026-09-10T03:49:57.758Z"},{"source":"nvd","name":"NVD","id":"CVE-2023-40178","url":"https://nvd.nist.gov/vuln/detail/CVE-2023-40178","licence":"Public domain","modified":"2026-06-17T06:16:34.627Z"}],"updatedAt":"2026-11-25T22:58:27.321Z","epss":{"score":0.00491,"percentile":0.43826,"date":"2026-12-01T12:00:22.000Z"}}