Skip to content
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

XML signature fails to verify #31117

Closed
componentspace opened this issue Oct 9, 2019 · 2 comments
Closed

XML signature fails to verify #31117

componentspace opened this issue Oct 9, 2019 · 2 comments
Labels
area-System.Security untriaged New issue has not been triaged by the area owner

Comments

@componentspace
Copy link

An XML signature in a SAML response fails to verify using System.Security.Cryptography.Xml.SignedXml.

I believe the XML signature should verify as it does when using a Java application.

The attached zip includes:

samlresponse-fails.xml - signed XML that fails to verify
samlresponse-verifies.xml - signed XML that does verify, for comparison

Program.cs - .NET Core console application demonstrating the problem
VerifySignature.java - Java application that can successfully verify the signatures for both files

The samlresponse-fails.xml includes a SAML response that's signed and a SAML assertion that's also signed. It's the SAML response signature that fails to verify in the .NET Core console application but does verify in the Java application.

The samlresponse-verifies.xml includes a SAML response that's signed and this verifies in both the .NET Core console application and the Java application.

The .NET Core console application was built using .NET Core 3.0 and System.Security.Cryptography.Xml v4.6.

dotnet --info
.NET Core SDK (reflecting any global.json):
Version: 3.0.100
Commit: 04339c3a26

Runtime Environment:
OS Name: Windows
OS Version: 10.0.18362
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\3.0.100\

xml-signature-issue.zip

@vcsjones
Copy link
Member

vcsjones commented Oct 9, 2019

A quick glace to me suggests this is related to, or a duplicate of, #27500.

@msftgits msftgits transferred this issue from dotnet/corefx Feb 1, 2020
@maryamariyan maryamariyan added the untriaged New issue has not been triaged by the area owner label Feb 23, 2020
@bartonjs
Copy link
Member

bartonjs commented Jul 7, 2020

Closing as duplicate of #27500.

@bartonjs bartonjs closed this as completed Jul 7, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 12, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.Security untriaged New issue has not been triaged by the area owner
Projects
None yet
Development

No branches or pull requests

4 participants