Skip to content

Adjust deprecation to better reflect real-world usage #499

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 21, 2025

Conversation

cjbarth
Copy link
Contributor

@cjbarth cjbarth commented Apr 21, 2025

This PR is to pull these changes from #498 to the 6.x branch.

@cjbarth cjbarth merged commit ab1c69e into node-saml:6.x Apr 21, 2025
@cjbarth cjbarth deleted the 6.1.0-changes branch April 21, 2025 15:31
@@ -573,6 +575,7 @@ export class SignedXml {
// thus the `canonXml` and _only_ the `canonXml` can be trusted.
// Append this to `signedReferences`.
this.signedReferences.push(canonXml);
ref.signedReference = canonXml;
Copy link

@srd90 srd90 Apr 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If there exist >1 references and any of the 1+n ( n > 0 ) reference validation fails then it seems based on quick code browsing that at least ref numer 1's signedReference points to canonical representation of ref XML and it is "labelled" as "signed" even though actual signature validation has not occured at all. At this stage only reference digest is validated but attacker might have recalculated digest after altering content at the end of reference "pointer". I.e. this looks similar case that there was with signedReferences array which was not resetted if any of the 1+n references validation failed.

Edit: aforementioned comment was meant to another PR. Any possible further discussion should take place at #498 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants