ruby-saml 0.8.12 → 0.8.13
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of ruby-saml might be problematic. Click here for more details.
- checksums.yaml +7 -7
- data/lib/onelogin/ruby-saml/logoutresponse.rb +1 -24
- data/lib/onelogin/ruby-saml/response.rb +3 -1
- data/lib/onelogin/ruby-saml/utils.rb +65 -0
- data/lib/onelogin/ruby-saml/version.rb +1 -1
- data/lib/xml_security.rb +216 -86
- data/test/certificates/ruby-saml-2.crt +15 -0
- data/test/response_test.rb +20 -0
- data/test/responses/adfs_response_xmlns.xml +45 -0
- data/test/responses/invalids/multiple_signed.xml.base64 +1 -0
- data/test/responses/invalids/no_signature.xml.base64 +1 -0
- data/test/responses/invalids/response_with_concealed_signed_assertion.xml +51 -0
- data/test/responses/invalids/response_with_doubled_signed_assertion.xml +49 -0
- data/test/responses/invalids/signature_wrapping_attack.xml.base64 +1 -0
- data/test/responses/response_with_signed_assertion_3.xml +30 -0
- data/test/responses/response_with_signed_message_and_assertion.xml +34 -0
- data/test/responses/response_with_undefined_recipient.xml.base64 +1 -0
- data/test/responses/valid_response_without_x509certificate.xml.base64 +1 -0
- data/test/test_helper.rb +62 -30
- data/test/xml_security_test.rb +281 -37
- metadata +70 -45
@@ -0,0 +1,15 @@
|
|
1
|
+
-----BEGIN CERTIFICATE-----
|
2
|
+
MIICVDCCAb2gAwIBAgIBADANBgkqhkiG9w0BAQ0FADBHMQswCQYDVQQGEwJ1czEQ
|
3
|
+
MA4GA1UECAwHZXhhbXBsZTEQMA4GA1UECgwHZXhhbXBsZTEUMBIGA1UEAwwLZXhh
|
4
|
+
bXBsZS5jb20wHhcNMTcwNDA3MDgzMDAzWhcNMjcwNDA1MDgzMDAzWjBHMQswCQYD
|
5
|
+
VQQGEwJ1czEQMA4GA1UECAwHZXhhbXBsZTEQMA4GA1UECgwHZXhhbXBsZTEUMBIG
|
6
|
+
A1UEAwwLZXhhbXBsZS5jb20wgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAKhP
|
7
|
+
S4/0azxbQekHHewQGKD7Pivr3CDpsrKxY3xlVanxj427OwzOb5KUVzsDEazumt6s
|
8
|
+
ZFY8HfidsjXY4EYA4ZzyL7ciIAR5vlAsIYN9nJ4AwVDnN/RjVwj+TN6BqWPLpVIp
|
9
|
+
Hc6Dl005HyE0zJnk1DZDn2tQVrIzbD3FhCp7YeotAgMBAAGjUDBOMB0GA1UdDgQW
|
10
|
+
BBRYZx4thASfNvR/E7NsCF2IaZ7wIDAfBgNVHSMEGDAWgBRYZx4thASfNvR/E7Ns
|
11
|
+
CF2IaZ7wIDAMBgNVHRMEBTADAQH/MA0GCSqGSIb3DQEBDQUAA4GBACz4aobx9aG3
|
12
|
+
kh+rNyrlgM3K6dYfnKG1/YH5sJCAOvg8kDr0fQAQifH8lFVWumKUMoAe0bFTfwWt
|
13
|
+
p/VJ8MprrEJth6PFeZdczpuv+fpLcNj2VmNVJqvQYvS4m36OnBFh1QFZW8UrbFIf
|
14
|
+
dtm2nuZ+twSKqfKwjLdqcoX0p39h7Uw/
|
15
|
+
-----END CERTIFICATE-----
|
data/test/response_test.rb
CHANGED
@@ -126,6 +126,26 @@ class ResponseTest < Minitest::Test
|
|
126
126
|
assert_nil response_wrapped.name_id
|
127
127
|
end
|
128
128
|
|
129
|
+
it "raise when no signature" do
|
130
|
+
response_no_signed_elements = OneLogin::RubySaml::Response.new(read_invalid_response("no_signature.xml.base64"))
|
131
|
+
settings.idp_cert_fingerprint = signature_fingerprint_1
|
132
|
+
response_no_signed_elements.settings = settings
|
133
|
+
error_msg = "Found an unexpected number of Signature Element. SAML Response rejected"
|
134
|
+
assert_raises(OneLogin::RubySaml::ValidationError, error_msg) do
|
135
|
+
response_no_signed_elements.validate!
|
136
|
+
end
|
137
|
+
end
|
138
|
+
|
139
|
+
it "raise when multiple signatures" do
|
140
|
+
response_multiple_signed = OneLogin::RubySaml::Response.new(read_invalid_response("multiple_signed.xml.base64"))
|
141
|
+
settings.idp_cert_fingerprint = signature_fingerprint_1
|
142
|
+
response_multiple_signed.settings = settings
|
143
|
+
error_msg = "Duplicated ID. SAML Response rejected"
|
144
|
+
assert_raises(OneLogin::RubySaml::ValidationError, error_msg) do
|
145
|
+
response_multiple_signed.validate!
|
146
|
+
end
|
147
|
+
end
|
148
|
+
|
129
149
|
it "support dynamic namespace resolution on signature elements" do
|
130
150
|
response = OneLogin::RubySaml::Response.new(fixture("no_signature_ns.xml"))
|
131
151
|
response.stubs(:conditions).returns(nil)
|
@@ -0,0 +1,45 @@
|
|
1
|
+
<samlp:Response Consent='urn:oasis:names:tc:SAML:2.0:consent:unspecified' Destination='https://someone.example.com/endpoint' ID='_0263a07b-205f-479c-90fc-7495715ecbbf' InResponseTo='_fc4a34b0-7efb-012e-caae-782bcb13bb38' IssueInstant='2011-06-22T12:49:30.348Z' Version='2.0' xmlns:samlp='urn:oasis:names:tc:SAML:2.0:protocol'>
|
2
|
+
<Issuer xmlns='urn:oasis:names:tc:SAML:2.0:assertion'>http://login.example.com/issuer</Issuer>
|
3
|
+
<samlp:Status>
|
4
|
+
<samlp:StatusCode Value='urn:oasis:names:tc:SAML:2.0:status:Success'/>
|
5
|
+
</samlp:Status>
|
6
|
+
<Assertion ID='_721b4a5a-d7e1-4861-9754-a9b197b6f9ab' IssueInstant='2011-06-22T12:49:30.348Z' Version='2.0' xmlns='urn:oasis:names:tc:SAML:2.0:assertion'>
|
7
|
+
<Issuer>http://login.example.com/issuer</Issuer>
|
8
|
+
<Signature xmlns='http://www.w3.org/2000/09/xmldsig#'>
|
9
|
+
<SignedInfo>
|
10
|
+
<CanonicalizationMethod Algorithm='http://www.w3.org/2001/10/xml-exc-c14n#'/>
|
11
|
+
<SignatureMethod Algorithm='http://www.w3.org/2001/04/xmldsig-more#rsa-sha256'/>
|
12
|
+
<Reference URI='#_721b4a5a-d7e1-4861-9754-a9b197b6f9ab'>
|
13
|
+
<Transforms>
|
14
|
+
<Transform Algorithm='http://www.w3.org/2000/09/xmldsig#enveloped-signature'/>
|
15
|
+
<Transform Algorithm='http://www.w3.org/2001/10/xml-exc-c14n#'/>
|
16
|
+
</Transforms>
|
17
|
+
<DigestMethod Algorithm='http://www.w3.org/2001/04/xmlenc#sha256'/>
|
18
|
+
<DigestValue>5mUndDm7OQSGNYVTevsJw3JRVZiwvlDnR2nprJ+6Mhc=</DigestValue>
|
19
|
+
</Reference>
|
20
|
+
</SignedInfo>
|
21
|
+
<SignatureValue>Ck3p/BPGWEY4PCkMuQv1q4ZkOTwIJletF8eXVsS00JWVakW07FBMRehtjDBOzQ3yN+nJFqoLs8Za1wFCZoW//kAlhchR5XVDr3dv/8GDtZHGrDgfSMxT+IO0HCVY80bzpq/LYUJhRVHTl+CReBvr2Crj5iHf5uTTsV+rm8YycFH0ZmT/2Ve2UqDrvmGrW3/nzM9NfAVCkFbu/rVvqfa/H3Hf3zW8DxO1g5FAeMp5mT0d4c5Yi3UD2vHaiSI3ITOJF7o/sc/WGCW7KDFLn/ewviDGkXiPy56P8BUFLQTciUhD5ONvtithSOCtHTDyPU3Sg52P6X+3oLCdsPc9/J247g==</SignatureValue>
|
22
|
+
<KeyInfo xmlns='http://www.w3.org/2000/09/xmldsig#'>
|
23
|
+
<X509Data>
|
24
|
+
<X509Certificate>LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSURPVENDQWlHZ0F3SUJBZ0lCQWpBTkJna3Foa2lHOXcwQkFRc0ZBREJDTVJNd0VRWUtDWkltaVpQeUxHUUIKR1JZRGIzSm5NUmt3RndZS0NaSW1pWlB5TEdRQkdSWUpjblZpZVMxc1lXNW5NUkF3RGdZRFZRUUREQWRTZFdKNQpJRU5CTUI0WERURTBNRGd3TmpJeE1UTXhPRm9YRFRFMU1EZ3dOakl4TVRNeE9Gb3dTekVUTUJFR0NnbVNKb21UCjhpeGtBUmtXQTI5eVp6RVpNQmNHQ2dtU0pvbVQ4aXhrQVJrV0NYSjFZbmt0YkdGdVp6RVpNQmNHQTFVRUF3d1EKV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SUTlKcm1zaHp0enpqdzBmd2VuTmY0U096cFBTVmp2YXFTUkVPWjg2NTgwUG5HUHJyOFMyNGNwSGt2OQpqbFpjZHRic2NYTjhIS3NsT2c9PQotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0tCg==</X509Certificate>
|
25
|
+
</X509Data>
|
26
|
+
</KeyInfo>
|
27
|
+
</Signature>
|
28
|
+
<Subject>
|
29
|
+
<NameID Format='urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress'>hello@example.com</NameID>
|
30
|
+
<SubjectConfirmation Method='urn:oasis:names:tc:SAML:2.0:cm:bearer'>
|
31
|
+
<SubjectConfirmationData InResponseTo='_fc4a34b0-7efb-012e-caae-782bcb13bb38' NotOnOrAfter='2011-06-22T12:54:30.348Z' Recipient='https://someone.example.com/endpoint'/>
|
32
|
+
</SubjectConfirmation>
|
33
|
+
</Subject>
|
34
|
+
<Conditions NotBefore='2011-06-22T12:49:30.332Z' NotOnOrAfter='2011-06-22T13:49:30.332Z'>
|
35
|
+
<AudienceRestriction>
|
36
|
+
<Audience>example.com</Audience>
|
37
|
+
</AudienceRestriction>
|
38
|
+
</Conditions>
|
39
|
+
<AuthnStatement AuthnInstant='2011-06-22T12:49:30.112Z' SessionIndex='_721b4a5a-d7e1-4861-9754-a9b197b6f9ab'>
|
40
|
+
<AuthnContext>
|
41
|
+
<AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</AuthnContextClassRef>
|
42
|
+
</AuthnContext>
|
43
|
+
</AuthnStatement>
|
44
|
+
</Assertion>
|
45
|
+
</samlp:Response>
|
@@ -0,0 +1 @@
|
|
1
|
+
PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6cHJvdG9jb2wiIHhtbG5zOnNhbWw9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDphc3NlcnRpb24iIElEPSJwZngwNWYzY2UxMC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W1scDpSZXNwb25zZT4=
|
@@ -0,0 +1,51 @@
|
|
1
|
+
<?xml version="1.0"?>
|
2
|
+
<samlp:Response xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol" ID="pfx0a3cfa31-f178-71f2-9b94-ad4047591acc" Version="2.0" IssueInstant="2012-04-04T07:33:10.921Z" Destination="https://example.com/endpoint">
|
3
|
+
<saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">idp.example.com</saml:Issuer>
|
4
|
+
<samlp:Status>
|
5
|
+
<samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Success"/>
|
6
|
+
</samlp:Status>
|
7
|
+
<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" Version="2.0" IssueInstant="2012-04-04T07:33:10.923Z" ID="unsigned-assertion">
|
8
|
+
<saml:Issuer>idp.myexample.org</saml:Issuer><ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
|
9
|
+
<ds:SignedInfo><ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
|
10
|
+
<ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
|
11
|
+
<ds:Reference URI="#pfx7fca52d6-8991-5d99-3147-4f9d7c278d78"><ds:Transforms><ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/><ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/></ds:Transforms><ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/><ds:DigestValue>FA0AbR4w9oYdx7MFjERARVJAHps=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:SignatureValue>GDH5jhCNX9PFxW+71SOJPyusAOwzECwmd57NDhvA/VKWHnV3PpvpNkOLyamoBNdZ4qxponnobg2zneLESrFnLJdJ1cgs51YvtBJTxKoA7oZMMNKReZFST8g7pDdrBC82n5rTdzxclaJkpwz1yjcho3K3TjxK+gU1svVrEKMUwyo=</ds:SignatureValue>
|
12
|
+
<ds:KeyInfo><ds:X509Data><ds:X509Certificate>MIICGzCCAYQCCQCNNcQXom32VDANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJVUzELMAkGA1UECBMCSU4xFTATBgNVBAcTDEluZGlhbmFwb2xpczERMA8GA1UEChMIT25lTG9naW4xDDAKBgNVBAsTA0VuZzAeFw0xNDA0MjMxODQxMDFaFw0xNTA0MjMxODQxMDFaMFIxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJJTjEVMBMGA1UEBxMMSW5kaWFuYXBvbGlzMREwDwYDVQQKEwhPbmVMb2dpbjEMMAoGA1UECxMDRW5nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDo6m+QZvYQ/xL0ElLgupK1QDcYL4f5PckwsNgS9pUvV7fzTqCHk8ThLxTk42MQ2McJsOeUJVP728KhymjFCqxgP4VuwRk9rpAl0+mhy6MPdyjyA6G14jrDWS65ysLchK4t/vwpEDz0SQlEoG1kMzllSm7zZS3XregA7DjNaUYQqwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBALM2vGCiQ/vm+a6v40+VX2zdqHA2Q/1vF1ibQzJ54MJCOVWvs+vQXfZFhdm0OPM2IrDU7oqvKPqP6xOAeJK6H0yP7M4YL3fatSvIYmmfyXC9kt3Svz/NyrHzPhUnJ0ye/sUSXxnzQxwcm/9PwAqrQaA3QpQkH57ybF/OoryPe+2h</ds:X509Certificate></ds:X509Data></ds:KeyInfo></ds:Signature>
|
13
|
+
<saml:Subject>
|
14
|
+
<saml:NameID NameQualifier="idp.example.com" Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress">victim@example.com</saml:NameID>
|
15
|
+
<saml:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
|
16
|
+
<saml:SubjectConfirmationData Recipient="https://example.com/endpoint" InResponseTo="_f7201940-6055-012f-3bc1-782bcb13c426"/>
|
17
|
+
</saml:SubjectConfirmation>
|
18
|
+
</saml:Subject>
|
19
|
+
<saml:Conditions NotBefore="2012-04-04T07:28:11.442Z" NotOnOrAfter="2012-04-04T07:38:11.442Z">
|
20
|
+
<saml:AudienceRestriction>
|
21
|
+
<saml:Audience>example.com</saml:Audience>
|
22
|
+
</saml:AudienceRestriction>
|
23
|
+
</saml:Conditions>
|
24
|
+
<saml:AuthnStatement AuthnInstant="2012-04-04T07:33:11.442Z">
|
25
|
+
<saml:AuthnContext>
|
26
|
+
<saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
|
27
|
+
</saml:AuthnContext>
|
28
|
+
</saml:AuthnStatement>
|
29
|
+
</saml:Assertion>
|
30
|
+
<foo>
|
31
|
+
<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" Version="2.0" IssueInstant="2012-04-04T07:33:10.923Z" ID="pfx7fca52d6-8991-5d99-3147-4f9d7c278d78">
|
32
|
+
<saml:Issuer>idp.myexample.org</saml:Issuer>
|
33
|
+
<saml:Subject>
|
34
|
+
<saml:NameID NameQualifier="idp.example.com" Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress">someone@example.org</saml:NameID>
|
35
|
+
<saml:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
|
36
|
+
<saml:SubjectConfirmationData Recipient="https://example.com/endpoint" InResponseTo="_f7201940-6055-012f-3bc1-782bcb13c426"/>
|
37
|
+
</saml:SubjectConfirmation>
|
38
|
+
</saml:Subject>
|
39
|
+
<saml:Conditions NotBefore="2012-04-04T07:28:11.442Z" NotOnOrAfter="2012-04-04T07:38:11.442Z">
|
40
|
+
<saml:AudienceRestriction>
|
41
|
+
<saml:Audience>example.com</saml:Audience>
|
42
|
+
</saml:AudienceRestriction>
|
43
|
+
</saml:Conditions>
|
44
|
+
<saml:AuthnStatement AuthnInstant="2012-04-04T07:33:11.442Z">
|
45
|
+
<saml:AuthnContext>
|
46
|
+
<saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
|
47
|
+
</saml:AuthnContext>
|
48
|
+
</saml:AuthnStatement>
|
49
|
+
</saml:Assertion>
|
50
|
+
</foo>
|
51
|
+
</samlp:Response>
|
@@ -0,0 +1,49 @@
|
|
1
|
+
<?xml version="1.0"?>
|
2
|
+
<samlp:Response xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol" ID="pfx0a3cfa31-f178-71f2-9b94-ad4047591acc" Version="2.0" IssueInstant="2012-04-04T07:33:10.921Z" Destination="https://example.com/endpoint">
|
3
|
+
<saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">idp.example.com</saml:Issuer>
|
4
|
+
<samlp:Status>
|
5
|
+
<samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Success"/>
|
6
|
+
</samlp:Status>
|
7
|
+
<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" Version="2.0" IssueInstant="2012-04-04T07:33:10.923Z" ID="unsigned-assertion">
|
8
|
+
<saml:Issuer>idp.myexample.org</saml:Issuer><ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
|
9
|
+
<ds:SignedInfo><ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
|
10
|
+
<ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
|
11
|
+
<ds:Reference URI="#pfx7fca52d6-8991-5d99-3147-4f9d7c278d78"><ds:Transforms><ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/><ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/></ds:Transforms><ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/><ds:DigestValue>FA0AbR4w9oYdx7MFjERARVJAHps=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:SignatureValue>GDH5jhCNX9PFxW+71SOJPyusAOwzECwmd57NDhvA/VKWHnV3PpvpNkOLyamoBNdZ4qxponnobg2zneLESrFnLJdJ1cgs51YvtBJTxKoA7oZMMNKReZFST8g7pDdrBC82n5rTdzxclaJkpwz1yjcho3K3TjxK+gU1svVrEKMUwyo=</ds:SignatureValue>
|
12
|
+
<ds:KeyInfo><ds:X509Data><ds:X509Certificate>MIICGzCCAYQCCQCNNcQXom32VDANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJVUzELMAkGA1UECBMCSU4xFTATBgNVBAcTDEluZGlhbmFwb2xpczERMA8GA1UEChMIT25lTG9naW4xDDAKBgNVBAsTA0VuZzAeFw0xNDA0MjMxODQxMDFaFw0xNTA0MjMxODQxMDFaMFIxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJJTjEVMBMGA1UEBxMMSW5kaWFuYXBvbGlzMREwDwYDVQQKEwhPbmVMb2dpbjEMMAoGA1UECxMDRW5nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDo6m+QZvYQ/xL0ElLgupK1QDcYL4f5PckwsNgS9pUvV7fzTqCHk8ThLxTk42MQ2McJsOeUJVP728KhymjFCqxgP4VuwRk9rpAl0+mhy6MPdyjyA6G14jrDWS65ysLchK4t/vwpEDz0SQlEoG1kMzllSm7zZS3XregA7DjNaUYQqwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBALM2vGCiQ/vm+a6v40+VX2zdqHA2Q/1vF1ibQzJ54MJCOVWvs+vQXfZFhdm0OPM2IrDU7oqvKPqP6xOAeJK6H0yP7M4YL3fatSvIYmmfyXC9kt3Svz/NyrHzPhUnJ0ye/sUSXxnzQxwcm/9PwAqrQaA3QpQkH57ybF/OoryPe+2h</ds:X509Certificate></ds:X509Data></ds:KeyInfo></ds:Signature>
|
13
|
+
<saml:Subject>
|
14
|
+
<saml:NameID NameQualifier="idp.example.com" Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress">victim@example.com</saml:NameID>
|
15
|
+
<saml:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
|
16
|
+
<saml:SubjectConfirmationData Recipient="https://example.com/endpoint" InResponseTo="_f7201940-6055-012f-3bc1-782bcb13c426"/>
|
17
|
+
</saml:SubjectConfirmation>
|
18
|
+
</saml:Subject>
|
19
|
+
<saml:Conditions NotBefore="2012-04-04T07:28:11.442Z" NotOnOrAfter="2012-04-04T07:38:11.442Z">
|
20
|
+
<saml:AudienceRestriction>
|
21
|
+
<saml:Audience>example.com</saml:Audience>
|
22
|
+
</saml:AudienceRestriction>
|
23
|
+
</saml:Conditions>
|
24
|
+
<saml:AuthnStatement AuthnInstant="2012-04-04T07:33:11.442Z">
|
25
|
+
<saml:AuthnContext>
|
26
|
+
<saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
|
27
|
+
</saml:AuthnContext>
|
28
|
+
</saml:AuthnStatement>
|
29
|
+
</saml:Assertion>
|
30
|
+
<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" Version="2.0" IssueInstant="2012-04-04T07:33:10.923Z" ID="pfx7fca52d6-8991-5d99-3147-4f9d7c278d78">
|
31
|
+
<saml:Issuer>idp.myexample.org</saml:Issuer>
|
32
|
+
<saml:Subject>
|
33
|
+
<saml:NameID NameQualifier="idp.example.com" Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress">someone@example.org</saml:NameID>
|
34
|
+
<saml:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
|
35
|
+
<saml:SubjectConfirmationData Recipient="https://example.com/endpoint" InResponseTo="_f7201940-6055-012f-3bc1-782bcb13c426"/>
|
36
|
+
</saml:SubjectConfirmation>
|
37
|
+
</saml:Subject>
|
38
|
+
<saml:Conditions NotBefore="2012-04-04T07:28:11.442Z" NotOnOrAfter="2012-04-04T07:38:11.442Z">
|
39
|
+
<saml:AudienceRestriction>
|
40
|
+
<saml:Audience>example.com</saml:Audience>
|
41
|
+
</saml:AudienceRestriction>
|
42
|
+
</saml:Conditions>
|
43
|
+
<saml:AuthnStatement AuthnInstant="2012-04-04T07:33:11.442Z">
|
44
|
+
<saml:AuthnContext>
|
45
|
+
<saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
|
46
|
+
</saml:AuthnContext>
|
47
|
+
</saml:AuthnStatement>
|
48
|
+
</saml:Assertion>
|
49
|
+
</samlp:Response>
|
@@ -0,0 +1 @@
|
|
1
|
+
PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6cHJvdG9jb2wiIHhtbG5zOnNhbWw9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDphc3NlcnRpb24iIElEPSJwZnhjM2QyYjU0Mi0wZjdlLTg3NjctOGU4Ny01YjBkYzY5MTMzNzUiIFZlcnNpb249IjIuMCIgSXNzdWVJbnN0YW50PSIyMDE0LTAzLTIxVDEzOjQxOjA5WiIgRGVzdGluYXRpb249Imh0dHBzOi8vcGl0YnVsay5uby1pcC5vcmcvbmV3b25lbG9naW4vZGVtbzEvaW5kZXgucGhwP2FjcyIgSW5SZXNwb25zZVRvPSJPTkVMT0dJTl81ZDllMzE5YzFiOGE2N2RhNDgyMjc5NjRjMjhkMjgwZTc4NjBmODA0Ij48c2FtbDpJc3N1ZXI+aHR0cHM6Ly9waXRidWxrLm5vLWlwLm9yZy9zaW1wbGVzYW1sL3NhbWwyL2lkcC9tZXRhZGF0YS5waHA8L3NhbWw6SXNzdWVyPjxzYW1scDpTdGF0dXM+PHNhbWxwOlN0YXR1c0RldGFpbD48c2FtbHA6UmVzcG9uc2UgeG1sbnM6c2FtbHA9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDpwcm90b2NvbCIgeG1sbnM6c2FtbD0idXJuOm9hc2lzO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SJ4czpzdHJpbmciPnVzZXI8L3NhbWw6QXR0cmlidXRlVmFsdWU+PHNhbWw6QXR0cmlidXRlVmFsdWUgeHNpOnR5cGU9InhzOnN0cmluZyI+YWRtaW48L3NhbWw6QXR0cmlidXRlVmFsdWU+PC9zYW1sOkF0dHJpYnV0ZT48L3NhbWw6QXR0cmlidXRlU3RhdGVtZW50Pjwvc2FtbDpBc3NlcnRpb24+PC9zYW1scDpSZXNwb25zZT4=
|
@@ -0,0 +1,30 @@
|
|
1
|
+
<?xml version="1.0"?>
|
2
|
+
<samlp:Response xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol" ID="pfx0a3cfa31-f178-71f2-9b94-ad4047591acc" Version="2.0" IssueInstant="2012-04-04T07:33:10.921Z" Destination="https://example.com/endpoint">
|
3
|
+
<saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">idp.example.com</saml:Issuer>
|
4
|
+
<samlp:Status>
|
5
|
+
<samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Success"/>
|
6
|
+
</samlp:Status>
|
7
|
+
<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" Version="2.0" IssueInstant="2012-04-04T07:33:10.923Z" ID="pfx7fca52d6-8991-5d99-3147-4f9d7c278d78">
|
8
|
+
<saml:Issuer>idp.myexample.org</saml:Issuer><ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
|
9
|
+
<ds:SignedInfo><ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
|
10
|
+
<ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
|
11
|
+
<ds:Reference URI="#pfx7fca52d6-8991-5d99-3147-4f9d7c278d78"><ds:Transforms><ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/><ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/></ds:Transforms><ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/><ds:DigestValue>FA0AbR4w9oYdx7MFjERARVJAHps=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:SignatureValue>GDH5jhCNX9PFxW+71SOJPyusAOwzECwmd57NDhvA/VKWHnV3PpvpNkOLyamoBNdZ4qxponnobg2zneLESrFnLJdJ1cgs51YvtBJTxKoA7oZMMNKReZFST8g7pDdrBC82n5rTdzxclaJkpwz1yjcho3K3TjxK+gU1svVrEKMUwyo=</ds:SignatureValue>
|
12
|
+
<ds:KeyInfo><ds:X509Data><ds:X509Certificate>MIICGzCCAYQCCQCNNcQXom32VDANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJVUzELMAkGA1UECBMCSU4xFTATBgNVBAcTDEluZGlhbmFwb2xpczERMA8GA1UEChMIT25lTG9naW4xDDAKBgNVBAsTA0VuZzAeFw0xNDA0MjMxODQxMDFaFw0xNTA0MjMxODQxMDFaMFIxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJJTjEVMBMGA1UEBxMMSW5kaWFuYXBvbGlzMREwDwYDVQQKEwhPbmVMb2dpbjEMMAoGA1UECxMDRW5nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDo6m+QZvYQ/xL0ElLgupK1QDcYL4f5PckwsNgS9pUvV7fzTqCHk8ThLxTk42MQ2McJsOeUJVP728KhymjFCqxgP4VuwRk9rpAl0+mhy6MPdyjyA6G14jrDWS65ysLchK4t/vwpEDz0SQlEoG1kMzllSm7zZS3XregA7DjNaUYQqwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBALM2vGCiQ/vm+a6v40+VX2zdqHA2Q/1vF1ibQzJ54MJCOVWvs+vQXfZFhdm0OPM2IrDU7oqvKPqP6xOAeJK6H0yP7M4YL3fatSvIYmmfyXC9kt3Svz/NyrHzPhUnJ0ye/sUSXxnzQxwcm/9PwAqrQaA3QpQkH57ybF/OoryPe+2h</ds:X509Certificate></ds:X509Data></ds:KeyInfo></ds:Signature>
|
13
|
+
<saml:Subject>
|
14
|
+
<saml:NameID NameQualifier="idp.example.com" Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress">someone@example.org</saml:NameID>
|
15
|
+
<saml:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
|
16
|
+
<saml:SubjectConfirmationData Recipient="https://example.com/endpoint" InResponseTo="_f7201940-6055-012f-3bc1-782bcb13c426"/>
|
17
|
+
</saml:SubjectConfirmation>
|
18
|
+
</saml:Subject>
|
19
|
+
<saml:Conditions NotBefore="2012-04-04T07:28:11.442Z" NotOnOrAfter="2012-04-04T07:38:11.442Z">
|
20
|
+
<saml:AudienceRestriction>
|
21
|
+
<saml:Audience>example.com</saml:Audience>
|
22
|
+
</saml:AudienceRestriction>
|
23
|
+
</saml:Conditions>
|
24
|
+
<saml:AuthnStatement AuthnInstant="2012-04-04T07:33:11.442Z">
|
25
|
+
<saml:AuthnContext>
|
26
|
+
<saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
|
27
|
+
</saml:AuthnContext>
|
28
|
+
</saml:AuthnStatement>
|
29
|
+
</saml:Assertion>
|
30
|
+
</samlp:Response>
|
@@ -0,0 +1,34 @@
|
|
1
|
+
<?xml version="1.0"?>
|
2
|
+
<samlp:Response xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol" ID="pfx0a3cfa31-f178-71f2-9b94-ad4047591acc" Version="2.0" IssueInstant="2012-04-04T07:33:10.921Z" Destination="https://example.com/endpoint">
|
3
|
+
<saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">idp.example.com</saml:Issuer><ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
|
4
|
+
<ds:SignedInfo><ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
|
5
|
+
<ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
|
6
|
+
<ds:Reference URI="#pfx0a3cfa31-f178-71f2-9b94-ad4047591acc"><ds:Transforms><ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/><ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/></ds:Transforms><ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/><ds:DigestValue>hi2Ouec0ovl90Cz+OXAP6FD5X70=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:SignatureValue>tJiaa5aZNzLFbBiIsyc0MBI4G1caG+gOW0joGlbMAyY86ERaDwDi1sz98+vykZOgjwkfZLT7K/AScdmp27PsaN4+NpLFRv/fUDyzKwjnDKMEzMBLi5nxDXVlYk1q5RCZbsV0W0He28Kl/+xwHP722CI/eWByU3rmR2H2wej8zZY=</ds:SignatureValue>
|
7
|
+
<ds:KeyInfo><ds:X509Data><ds:X509Certificate>MIICGzCCAYQCCQCNNcQXom32VDANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJVUzELMAkGA1UECBMCSU4xFTATBgNVBAcTDEluZGlhbmFwb2xpczERMA8GA1UEChMIT25lTG9naW4xDDAKBgNVBAsTA0VuZzAeFw0xNDA0MjMxODQxMDFaFw0xNTA0MjMxODQxMDFaMFIxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJJTjEVMBMGA1UEBxMMSW5kaWFuYXBvbGlzMREwDwYDVQQKEwhPbmVMb2dpbjEMMAoGA1UECxMDRW5nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDo6m+QZvYQ/xL0ElLgupK1QDcYL4f5PckwsNgS9pUvV7fzTqCHk8ThLxTk42MQ2McJsOeUJVP728KhymjFCqxgP4VuwRk9rpAl0+mhy6MPdyjyA6G14jrDWS65ysLchK4t/vwpEDz0SQlEoG1kMzllSm7zZS3XregA7DjNaUYQqwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBALM2vGCiQ/vm+a6v40+VX2zdqHA2Q/1vF1ibQzJ54MJCOVWvs+vQXfZFhdm0OPM2IrDU7oqvKPqP6xOAeJK6H0yP7M4YL3fatSvIYmmfyXC9kt3Svz/NyrHzPhUnJ0ye/sUSXxnzQxwcm/9PwAqrQaA3QpQkH57ybF/OoryPe+2h</ds:X509Certificate></ds:X509Data></ds:KeyInfo></ds:Signature>
|
8
|
+
<samlp:Status>
|
9
|
+
<samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Success"/>
|
10
|
+
</samlp:Status>
|
11
|
+
<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" Version="2.0" IssueInstant="2012-04-04T07:33:10.923Z" ID="pfx7fca52d6-8991-5d99-3147-4f9d7c278d78">
|
12
|
+
<saml:Issuer>idp.myexample.org</saml:Issuer><ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
|
13
|
+
<ds:SignedInfo><ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
|
14
|
+
<ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
|
15
|
+
<ds:Reference URI="#pfx7fca52d6-8991-5d99-3147-4f9d7c278d78"><ds:Transforms><ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/><ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/></ds:Transforms><ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/><ds:DigestValue>FA0AbR4w9oYdx7MFjERARVJAHps=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:SignatureValue>GDH5jhCNX9PFxW+71SOJPyusAOwzECwmd57NDhvA/VKWHnV3PpvpNkOLyamoBNdZ4qxponnobg2zneLESrFnLJdJ1cgs51YvtBJTxKoA7oZMMNKReZFST8g7pDdrBC82n5rTdzxclaJkpwz1yjcho3K3TjxK+gU1svVrEKMUwyo=</ds:SignatureValue>
|
16
|
+
<ds:KeyInfo><ds:X509Data><ds:X509Certificate>MIICGzCCAYQCCQCNNcQXom32VDANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJVUzELMAkGA1UECBMCSU4xFTATBgNVBAcTDEluZGlhbmFwb2xpczERMA8GA1UEChMIT25lTG9naW4xDDAKBgNVBAsTA0VuZzAeFw0xNDA0MjMxODQxMDFaFw0xNTA0MjMxODQxMDFaMFIxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJJTjEVMBMGA1UEBxMMSW5kaWFuYXBvbGlzMREwDwYDVQQKEwhPbmVMb2dpbjEMMAoGA1UECxMDRW5nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDo6m+QZvYQ/xL0ElLgupK1QDcYL4f5PckwsNgS9pUvV7fzTqCHk8ThLxTk42MQ2McJsOeUJVP728KhymjFCqxgP4VuwRk9rpAl0+mhy6MPdyjyA6G14jrDWS65ysLchK4t/vwpEDz0SQlEoG1kMzllSm7zZS3XregA7DjNaUYQqwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBALM2vGCiQ/vm+a6v40+VX2zdqHA2Q/1vF1ibQzJ54MJCOVWvs+vQXfZFhdm0OPM2IrDU7oqvKPqP6xOAeJK6H0yP7M4YL3fatSvIYmmfyXC9kt3Svz/NyrHzPhUnJ0ye/sUSXxnzQxwcm/9PwAqrQaA3QpQkH57ybF/OoryPe+2h</ds:X509Certificate></ds:X509Data></ds:KeyInfo></ds:Signature>
|
17
|
+
<saml:Subject>
|
18
|
+
<saml:NameID NameQualifier="idp.example.com" Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress">someone@example.org</saml:NameID>
|
19
|
+
<saml:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
|
20
|
+
<saml:SubjectConfirmationData Recipient="https://example.com/endpoint" InResponseTo="_f7201940-6055-012f-3bc1-782bcb13c426"/>
|
21
|
+
</saml:SubjectConfirmation>
|
22
|
+
</saml:Subject>
|
23
|
+
<saml:Conditions NotBefore="2012-04-04T07:28:11.442Z" NotOnOrAfter="2012-04-04T07:38:11.442Z">
|
24
|
+
<saml:AudienceRestriction>
|
25
|
+
<saml:Audience>example.com</saml:Audience>
|
26
|
+
</saml:AudienceRestriction>
|
27
|
+
</saml:Conditions>
|
28
|
+
<saml:AuthnStatement AuthnInstant="2012-04-04T07:33:11.442Z">
|
29
|
+
<saml:AuthnContext>
|
30
|
+
<saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
|
31
|
+
</saml:AuthnContext>
|
32
|
+
</saml:AuthnStatement>
|
33
|
+
</saml:Assertion>
|
34
|
+
</samlp:Response>
|
@@ -0,0 +1 @@
|
|
1
|
+
DQo8c2FtbHA6UmVzcG9uc2UgeG1sbnM6c2FtbD0idXJuOm9hc2lzOm5hbWVzOnRjOlNBTUw6Mi4wOmFzc2VydGlvbiIgeG1sbnM6c2FtbHA9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDpwcm90b2NvbCIgSUQ9IkdPU0FNTFIxMjkwMTE3NDU3MTc5NCIgVmVyc2lvbj0iMi4wIiBJc3N1ZUluc3RhbnQ9IjIwMTAtMTEtMThUMjE6NTc6MzdaIiBEZXN0aW5hdGlvbj0ie3JlY2lwaWVudH0iPg0KICA8c2FtbHA6U3RhdHVzPg0KICAgIDxzYW1scDpTdGF0dXNDb2RlIFZhbHVlPSJ1cm46b2FzaXM6bmFtZXM6dGM6U0FNTDoyLjA6c3RhdHVzOlN1Y2Nlc3MiLz48L3NhbWxwOlN0YXR1cz4NCiAgPHNhbWw6QXNzZXJ0aW9uIHhtbG5zOnhzPSJodHRwOi8vd3d3LnczLm9yZy8yMDAxL1hNTFNjaGVtYSIgeG1sbnM6eHNpPSJodHRwOi8vd3d3LnczLm9yZy8yMDAxL1hNTFNjaGVtYS1pbnN0YW5jZSIgVmVyc2lvbj0iMi4wIiBJRD0icGZ4YTQ2NTc0ZGYtYjNiMC1hMDZhLTIzYzgtNjM2NDE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wX0VORHo2Cs/lq7PkBTfpRNPeP5I/gb3g4oXfnyRKGE7f/TR8i/8OH09ljMD3p1uXs8NejbM/b20y2SGlT7lsDTsGolr0+sGQVHUYLQkDKqtE/g4b97SjcHOfVS8fZsb+djyMyhxybdWz662ArrcYdgZ9m4XqMdlqOH6PEs5otz7cclPgW8RNsdShtuR44zU6bvGlw/o+xVhnRIr4FojbWhdZzNDQ+6iOB1ctCOw2n8qTUSqrQUJecZn1KRSl6T+lN/ddu/k3mNfx+5gFnSVpilN1Yn73XO0zyMAYsQJgvAw2xwsYFV5fsUvQTBaJUz0M76gXra+caSFqkUMortn/rTXMI+dmnDQUdQdPysyyzfgCtClQNc55SOpuUb6C13aULmpazQF92SqRknX7vS91wyXPQgjdghfMig6rneBO0YVyveWbvodvPyqnzqTkrTxDkWiCjMn9xoUd6J2iEF6ptHQgdMQorfZ07ftIKUBIT5DkthAKMvFaLJoD92CNNn5i7pDRVBSt1wDXI9INHz9Peq28iEpIyTruv9M+SC3qlnzy6s0Cr26HgQtWCHQA/8G3PV4tWe7ejp55M27dM718=
|
data/test/test_helper.rb
CHANGED
@@ -30,6 +30,10 @@ class Minitest::Test
|
|
30
30
|
RUBY_VERSION < '1.9' ? "_#{UUID.new.generate}" : "_#{SecureRandom.uuid}"
|
31
31
|
end
|
32
32
|
|
33
|
+
def read_invalid_response(response)
|
34
|
+
File.read(File.join(File.dirname(__FILE__), "responses", "invalids", response))
|
35
|
+
end
|
36
|
+
|
33
37
|
def read_response(response)
|
34
38
|
File.read(File.join(File.dirname(__FILE__), "responses", response))
|
35
39
|
end
|
@@ -81,6 +85,14 @@ class Minitest::Test
|
|
81
85
|
response_document_valid_signed ||= File.read(File.join(File.dirname(__FILE__), 'responses', 'valid_response.xml.base64'))
|
82
86
|
end
|
83
87
|
|
88
|
+
def response_document_valid_signed_without_x509certificate
|
89
|
+
@response_document_valid_signed_without_x509certificate ||= read_response("valid_response_without_x509certificate.xml.base64")
|
90
|
+
end
|
91
|
+
|
92
|
+
def response_document_without_recipient
|
93
|
+
@response_document_without_recipient ||= read_response("response_with_undefined_recipient.xml.base64")
|
94
|
+
end
|
95
|
+
|
84
96
|
def wrapped_response_2
|
85
97
|
@wrapped_response_2 ||= File.read(File.join(File.dirname(__FILE__), 'responses', 'wrapped_response_2.xml.base64'))
|
86
98
|
end
|
@@ -116,40 +128,60 @@ class Minitest::Test
|
|
116
128
|
def response_multiple_attr_values
|
117
129
|
@response_multiple_attr_values = OneLogin::RubySaml::Response.new(fixture(:response_with_multiple_attribute_values))
|
118
130
|
end
|
119
|
-
end
|
120
131
|
|
121
|
-
def
|
122
|
-
|
123
|
-
end
|
132
|
+
def ruby_saml_cert
|
133
|
+
@ruby_saml_cert ||= OpenSSL::X509::Certificate.new(ruby_saml_cert_text)
|
134
|
+
end
|
124
135
|
|
125
|
-
def
|
126
|
-
|
127
|
-
end
|
136
|
+
def ruby_saml_cert2
|
137
|
+
@ruby_saml_cert2 ||= OpenSSL::X509::Certificate.new(ruby_saml_cert_text2)
|
138
|
+
end
|
128
139
|
|
129
|
-
def
|
130
|
-
|
131
|
-
end
|
140
|
+
def ruby_saml_cert_fingerprint
|
141
|
+
@ruby_saml_cert_fingerprint ||= Digest::SHA1.hexdigest(ruby_saml_cert.to_der).scan(/../).join(":")
|
142
|
+
end
|
132
143
|
|
133
|
-
def
|
134
|
-
|
135
|
-
|
144
|
+
def ruby_saml_cert_text
|
145
|
+
read_certificate("ruby-saml.crt")
|
146
|
+
end
|
136
147
|
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
148
|
+
def ruby_saml_cert_text2
|
149
|
+
read_certificate("ruby-saml-2.crt")
|
150
|
+
end
|
151
|
+
|
152
|
+
def ruby_saml_key_text
|
153
|
+
read_certificate("ruby-saml.key")
|
154
|
+
end
|
155
|
+
|
156
|
+
def ruby_saml_key
|
157
|
+
@ruby_saml_key ||= OpenSSL::PKey::RSA.new(ruby_saml_key_text)
|
158
|
+
end
|
159
|
+
|
160
|
+
def read_certificate(certificate)
|
161
|
+
File.read(File.join(File.dirname(__FILE__), "certificates", certificate))
|
162
|
+
end
|
143
163
|
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
164
|
+
def decode_saml_request_payload(unauth_url)
|
165
|
+
payload = CGI.unescape(unauth_url.split("SAMLRequest=").last)
|
166
|
+
decoded = Base64.decode64(payload)
|
167
|
+
|
168
|
+
zstream = Zlib::Inflate.new(-Zlib::MAX_WBITS)
|
169
|
+
inflated = zstream.inflate(decoded)
|
170
|
+
zstream.finish
|
171
|
+
zstream.close
|
172
|
+
inflated
|
173
|
+
end
|
174
|
+
|
175
|
+
# decodes a base64 encoded SAML response for use in SloLogoutresponse tests
|
176
|
+
#
|
177
|
+
def decode_saml_response_payload(unauth_url)
|
178
|
+
payload = CGI.unescape(unauth_url.split("SAMLResponse=").last)
|
179
|
+
decoded = Base64.decode64(payload)
|
180
|
+
|
181
|
+
zstream = Zlib::Inflate.new(-Zlib::MAX_WBITS)
|
182
|
+
inflated = zstream.inflate(decoded)
|
183
|
+
zstream.finish
|
184
|
+
zstream.close
|
185
|
+
inflated
|
186
|
+
end
|
155
187
|
end
|
data/test/xml_security_test.rb
CHANGED
@@ -4,81 +4,187 @@ class XmlSecurityTest < Minitest::Test
|
|
4
4
|
include XMLSecurity
|
5
5
|
|
6
6
|
describe "XmlSecurity" do
|
7
|
+
|
8
|
+
let(:decoded_response) { Base64.decode64(response_document_without_recipient) }
|
9
|
+
let(:document) { XMLSecurity::SignedDocument.new(decoded_response) }
|
10
|
+
let(:settings) { OneLogin::RubySaml::Settings.new() }
|
11
|
+
|
7
12
|
before do
|
8
|
-
@
|
9
|
-
@base64cert = @document.elements["//ds:X509Certificate"].text
|
13
|
+
@base64cert = document.elements["//ds:X509Certificate"].text
|
10
14
|
end
|
11
15
|
|
12
16
|
it "should run validate without throwing NS related exceptions" do
|
13
|
-
assert
|
17
|
+
assert !document.validate_signature(@base64cert, true)
|
14
18
|
end
|
15
19
|
|
16
20
|
it "should run validate with throwing NS related exceptions" do
|
17
21
|
assert_raises(OneLogin::RubySaml::ValidationError) do
|
18
|
-
|
22
|
+
document.validate_signature(@base64cert, false)
|
19
23
|
end
|
20
24
|
end
|
21
25
|
|
22
26
|
it "not raise an error when softly validating the document multiple times" do
|
23
|
-
2.times {
|
27
|
+
2.times { assert_equal document.validate_signature(@base64cert, true), false }
|
28
|
+
end
|
29
|
+
|
30
|
+
it "not raise an error when softly validating the document and the X509Certificate is missing" do
|
31
|
+
decoded_response.sub!(/<ds:X509Certificate>.*<\/ds:X509Certificate>/, "")
|
32
|
+
mod_document = XMLSecurity::SignedDocument.new(decoded_response)
|
33
|
+
assert !mod_document.validate_document("a fingerprint", true) # The fingerprint isn't relevant to this test
|
24
34
|
end
|
25
35
|
|
26
36
|
it "should raise Fingerprint mismatch" do
|
27
37
|
exception = assert_raises(OneLogin::RubySaml::ValidationError) do
|
28
|
-
|
38
|
+
document.validate_document("no:fi:ng:er:pr:in:t", false)
|
29
39
|
end
|
30
40
|
assert_equal("Fingerprint mismatch", exception.message)
|
31
41
|
end
|
32
42
|
|
33
43
|
it "should raise Digest mismatch" do
|
34
44
|
exception = assert_raises(OneLogin::RubySaml::ValidationError) do
|
35
|
-
|
45
|
+
document.validate_signature(@base64cert, false)
|
36
46
|
end
|
37
47
|
assert_equal("Digest mismatch", exception.message)
|
38
48
|
end
|
39
49
|
|
40
50
|
it "should raise Key validation error" do
|
41
|
-
|
42
|
-
response.sub!("<ds:DigestValue>pJQ7MS/ek4KRRWGmv/H43ReHYMs=</ds:DigestValue>",
|
51
|
+
decoded_response.sub!("<ds:DigestValue>pJQ7MS/ek4KRRWGmv/H43ReHYMs=</ds:DigestValue>",
|
43
52
|
"<ds:DigestValue>b9xsAXLsynugg3Wc1CI3kpWku+0=</ds:DigestValue>")
|
44
|
-
|
45
|
-
base64cert =
|
53
|
+
mod_document = XMLSecurity::SignedDocument.new(decoded_response)
|
54
|
+
base64cert = mod_document.elements["//ds:X509Certificate"].text
|
46
55
|
exception = assert_raises(OneLogin::RubySaml::ValidationError) do
|
47
|
-
|
56
|
+
mod_document.validate_signature(base64cert, false)
|
48
57
|
end
|
49
58
|
assert_equal("Key validation error", exception.message)
|
50
59
|
end
|
51
60
|
|
52
|
-
it "
|
53
|
-
|
54
|
-
|
55
|
-
|
61
|
+
it "correctly obtain the digest method with alternate namespace declaration" do
|
62
|
+
adfs_document = XMLSecurity::SignedDocument.new(fixture(:adfs_response_xmlns, false))
|
63
|
+
base64cert = adfs_document.elements["//X509Certificate"].text
|
64
|
+
assert adfs_document.validate_signature(base64cert, false)
|
65
|
+
end
|
66
|
+
|
67
|
+
it "raise validation error when the X509Certificate is missing and no cert provided" do
|
68
|
+
decoded_response.sub!(/<ds:X509Certificate>.*<\/ds:X509Certificate>/, "")
|
69
|
+
mod_document = XMLSecurity::SignedDocument.new(decoded_response)
|
56
70
|
exception = assert_raises(OneLogin::RubySaml::ValidationError) do
|
57
|
-
|
71
|
+
mod_document.validate_document("a fingerprint", false) # The fingerprint isn't relevant to this test
|
58
72
|
end
|
59
|
-
assert_equal("Certificate element missing in response (ds:X509Certificate)", exception.message)
|
73
|
+
assert_equal("Certificate element missing in response (ds:X509Certificate) and not cert provided at settings", exception.message)
|
74
|
+
end
|
75
|
+
|
76
|
+
it "invalidaties when the X509Certificate is missing and the cert is provided but mismatches" do
|
77
|
+
decoded_response.sub!(/<ds:X509Certificate>.*<\/ds:X509Certificate>/, "")
|
78
|
+
mod_document = XMLSecurity::SignedDocument.new(decoded_response)
|
79
|
+
cert = OpenSSL::X509::Certificate.new(ruby_saml_cert)
|
80
|
+
assert !mod_document.validate_document("a fingerprint", true, :cert => cert) # The fingerprint isn't relevant to this test
|
60
81
|
end
|
61
82
|
end
|
62
83
|
|
63
|
-
describe "
|
84
|
+
describe "#canon_algorithm" do
|
85
|
+
it "C14N_EXCLUSIVE_1_0" do
|
86
|
+
canon_algorithm = Nokogiri::XML::XML_C14N_EXCLUSIVE_1_0
|
87
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("http://www.w3.org/2001/10/xml-exc-c14n#")
|
88
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("http://www.w3.org/2001/10/xml-exc-c14n#WithComments")
|
89
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("other")
|
90
|
+
end
|
91
|
+
|
92
|
+
it "C14N_1_0" do
|
93
|
+
canon_algorithm = Nokogiri::XML::XML_C14N_1_0
|
94
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("http://www.w3.org/TR/2001/REC-xml-c14n-20010315")
|
95
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("http://www.w3.org/TR/2001/REC-xml-c14n-20010315#WithComments")
|
96
|
+
end
|
97
|
+
|
98
|
+
it "XML_C14N_1_1" do
|
99
|
+
canon_algorithm = Nokogiri::XML::XML_C14N_1_1
|
100
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("http://www.w3.org/2006/12/xml-c14n11")
|
101
|
+
assert_equal canon_algorithm, XMLSecurity::BaseDocument.new.canon_algorithm("http://www.w3.org/2006/12/xml-c14n11#WithComments")
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
describe "#algorithm" do
|
106
|
+
it "SHA1" do
|
107
|
+
alg = OpenSSL::Digest::SHA1
|
108
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2000/09/xmldsig#rsa-sha1")
|
109
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2000/09/xmldsig#sha1")
|
110
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("other")
|
111
|
+
end
|
112
|
+
|
113
|
+
it "SHA256" do
|
114
|
+
alg = OpenSSL::Digest::SHA256
|
115
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2001/04/xmldsig-more#rsa-sha256")
|
116
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2001/04/xmldsig-more#sha256")
|
117
|
+
end
|
118
|
+
|
119
|
+
it "SHA384" do
|
120
|
+
alg = OpenSSL::Digest::SHA384
|
121
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2001/04/xmldsig-more#rsa-sha384")
|
122
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2001/04/xmldsig-more#sha384")
|
123
|
+
end
|
124
|
+
|
125
|
+
it "SHA512" do
|
126
|
+
alg = OpenSSL::Digest::SHA512
|
127
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2001/04/xmldsig-more#rsa-sha512")
|
128
|
+
assert_equal alg, XMLSecurity::BaseDocument.new.algorithm("http://www.w3.org/2001/04/xmldsig-more#sha512")
|
129
|
+
end
|
130
|
+
end
|
131
|
+
|
132
|
+
describe "Fingerprint Algorithms" do
|
133
|
+
let(:response_fingerprint_test) { OneLogin::RubySaml::Response.new(fixture(:adfs_response_sha1, false)) }
|
134
|
+
|
135
|
+
it "validate using SHA1" do
|
136
|
+
sha1_fingerprint = "F1:3C:6B:80:90:5A:03:0E:6C:91:3E:5D:15:FA:DD:B0:16:45:48:72"
|
137
|
+
sha1_fingerprint_downcase = "f13c6b80905a030e6c913e5d15faddb016454872"
|
138
|
+
|
139
|
+
assert response_fingerprint_test.document.validate_document(sha1_fingerprint)
|
140
|
+
assert response_fingerprint_test.document.validate_document(sha1_fingerprint, true, :fingerprint_alg => XMLSecurity::Document::SHA1)
|
141
|
+
|
142
|
+
assert response_fingerprint_test.document.validate_document(sha1_fingerprint_downcase)
|
143
|
+
assert response_fingerprint_test.document.validate_document(sha1_fingerprint_downcase, true, :fingerprint_alg => XMLSecurity::Document::SHA1)
|
144
|
+
end
|
145
|
+
|
146
|
+
it "validate using SHA256" do
|
147
|
+
sha256_fingerprint = "C4:C6:BD:41:EC:AD:57:97:CE:7B:7D:80:06:C3:E4:30:53:29:02:0B:DD:2D:47:02:9E:BD:85:AD:93:02:45:21"
|
148
|
+
|
149
|
+
assert !response_fingerprint_test.document.validate_document(sha256_fingerprint)
|
150
|
+
assert response_fingerprint_test.document.validate_document(sha256_fingerprint, true, :fingerprint_alg => XMLSecurity::Document::SHA256)
|
151
|
+
end
|
152
|
+
|
153
|
+
it "validate using SHA384" do
|
154
|
+
sha384_fingerprint = "98:FE:17:90:31:E7:68:18:8A:65:4D:DA:F5:76:E2:09:97:BE:8B:E3:7E:AA:8D:63:64:7C:0C:38:23:9A:AC:A2:EC:CE:48:A6:74:4D:E0:4C:50:80:40:B4:8D:55:14:14"
|
155
|
+
|
156
|
+
assert !response_fingerprint_test.document.validate_document(sha384_fingerprint)
|
157
|
+
assert response_fingerprint_test.document.validate_document(sha384_fingerprint, true, :fingerprint_alg => XMLSecurity::Document::SHA384)
|
158
|
+
end
|
159
|
+
|
160
|
+
it "validate using SHA512" do
|
161
|
+
sha512_fingerprint = "5A:AE:BA:D0:BA:9D:1E:25:05:01:1E:1A:C9:E9:FF:DB:ED:FA:6E:F7:52:EB:45:49:BD:DB:06:D8:A3:7E:CC:63:3A:04:A2:DD:DF:EE:61:05:D9:58:95:2A:77:17:30:4B:EB:4A:9F:48:4A:44:1C:D0:9E:0B:1E:04:77:FD:A3:D2"
|
162
|
+
|
163
|
+
assert !response_fingerprint_test.document.validate_document(sha512_fingerprint)
|
164
|
+
assert response_fingerprint_test.document.validate_document(sha512_fingerprint, true, :fingerprint_alg => XMLSecurity::Document::SHA512)
|
165
|
+
end
|
166
|
+
|
167
|
+
end
|
168
|
+
|
169
|
+
describe "Signature Algorithms" do
|
64
170
|
it "validate using SHA1" do
|
65
|
-
|
66
|
-
assert
|
171
|
+
document = XMLSecurity::SignedDocument.new(fixture(:adfs_response_sha1, false))
|
172
|
+
assert document.validate_document("F1:3C:6B:80:90:5A:03:0E:6C:91:3E:5D:15:FA:DD:B0:16:45:48:72")
|
67
173
|
end
|
68
174
|
|
69
175
|
it "validate using SHA256" do
|
70
|
-
|
71
|
-
assert
|
176
|
+
document = XMLSecurity::SignedDocument.new(fixture(:adfs_response_sha256, false))
|
177
|
+
assert document.validate_document("28:74:9B:E8:1F:E8:10:9C:A8:7C:A9:C3:E3:C5:01:6C:92:1C:B4:BA")
|
72
178
|
end
|
73
179
|
|
74
180
|
it "validate using SHA384" do
|
75
|
-
|
76
|
-
assert
|
181
|
+
document = XMLSecurity::SignedDocument.new(fixture(:adfs_response_sha384, false))
|
182
|
+
assert document.validate_document("F1:3C:6B:80:90:5A:03:0E:6C:91:3E:5D:15:FA:DD:B0:16:45:48:72")
|
77
183
|
end
|
78
184
|
|
79
185
|
it "validate using SHA512" do
|
80
|
-
|
81
|
-
assert
|
186
|
+
document = XMLSecurity::SignedDocument.new(fixture(:adfs_response_sha512, false))
|
187
|
+
assert document.validate_document("F1:3C:6B:80:90:5A:03:0E:6C:91:3E:5D:15:FA:DD:B0:16:45:48:72")
|
82
188
|
end
|
83
189
|
end
|
84
190
|
|
@@ -103,35 +209,95 @@ class XmlSecurityTest < Minitest::Test
|
|
103
209
|
|
104
210
|
it 'support inclusive canonicalization' do
|
105
211
|
skip('test not yet implemented')
|
106
|
-
|
107
212
|
response = OneLogin::RubySaml::Response.new(fixture("tdnf_response.xml"))
|
108
213
|
response.stubs(:conditions).returns(nil)
|
109
214
|
assert !response.is_valid?
|
110
|
-
settings = OneLogin::RubySaml::Settings.new
|
111
215
|
assert !response.is_valid?
|
112
216
|
response.settings = settings
|
113
217
|
assert !response.is_valid?
|
114
218
|
settings.idp_cert_fingerprint = "e6 38 9a 20 b7 4f 13 db 6a bc b1 42 6a e7 52 1d d6 56 d4 1b".upcase.gsub(" ", ":")
|
115
|
-
assert response.
|
219
|
+
assert response.is_valid?
|
116
220
|
end
|
117
221
|
|
118
|
-
it "return
|
222
|
+
it "return nil when inclusive namespace element is missing" do
|
119
223
|
response = fixture(:no_signature_ns, false)
|
120
224
|
response.slice! %r{<InclusiveNamespaces xmlns="http://www.w3.org/2001/10/xml-exc-c14n#" PrefixList="#default saml ds xs xsi"/>}
|
121
225
|
|
122
226
|
document = XMLSecurity::SignedDocument.new(response)
|
123
227
|
inclusive_namespaces = document.send(:extract_inclusive_namespaces)
|
124
228
|
|
125
|
-
assert inclusive_namespaces.
|
229
|
+
assert inclusive_namespaces.nil?
|
126
230
|
end
|
127
231
|
end
|
128
232
|
|
129
|
-
describe "
|
233
|
+
describe "XMLSecurity::DSIG" do
|
130
234
|
before do
|
235
|
+
settings.idp_sso_target_url = "https://idp.example.com/sso"
|
236
|
+
settings.protocol_binding = "urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
|
237
|
+
settings.idp_slo_target_url = "https://idp.example.com/slo",
|
238
|
+
settings.sp_entity_id = "https://sp.example.com/saml2"
|
239
|
+
settings.assertion_consumer_service_url = "https://sp.example.com/acs"
|
240
|
+
settings.single_logout_service_url = "https://sp.example.com/sls"
|
241
|
+
end
|
242
|
+
|
243
|
+
it "sign an AuthNRequest" do
|
244
|
+
request = OneLogin::RubySaml::Authrequest.new.create_authentication_xml_doc(settings)
|
245
|
+
request.sign_document(ruby_saml_key, ruby_saml_cert)
|
246
|
+
# verify our signature
|
247
|
+
signed_doc = XMLSecurity::SignedDocument.new(request.to_s)
|
248
|
+
assert signed_doc.validate_document(ruby_saml_cert_fingerprint, false)
|
249
|
+
|
250
|
+
request2 = OneLogin::RubySaml::Authrequest.new.create_authentication_xml_doc(settings)
|
251
|
+
request2.sign_document(ruby_saml_key, ruby_saml_cert_text)
|
252
|
+
# verify our signature
|
253
|
+
signed_doc2 = XMLSecurity::SignedDocument.new(request2.to_s)
|
254
|
+
assert signed_doc2.validate_document(ruby_saml_cert_fingerprint, false)
|
255
|
+
end
|
256
|
+
|
257
|
+
it "sign an AuthNRequest with certificate as text" do
|
258
|
+
request = OneLogin::RubySaml::Authrequest.new.create_authentication_xml_doc(settings)
|
259
|
+
request.sign_document(ruby_saml_key, ruby_saml_cert_text)
|
260
|
+
|
261
|
+
# verify our signature
|
262
|
+
signed_doc = XMLSecurity::SignedDocument.new(request.to_s)
|
263
|
+
assert signed_doc.validate_document(ruby_saml_cert_fingerprint, false)
|
264
|
+
end
|
265
|
+
|
266
|
+
it "sign a LogoutRequest" do
|
267
|
+
logout_request = OneLogin::RubySaml::Logoutrequest.new.create_logout_request_xml_doc(settings)
|
268
|
+
logout_request.sign_document(ruby_saml_key, ruby_saml_cert)
|
269
|
+
# verify our signature
|
270
|
+
signed_doc = XMLSecurity::SignedDocument.new(logout_request.to_s)
|
271
|
+
assert signed_doc.validate_document(ruby_saml_cert_fingerprint, false)
|
272
|
+
|
273
|
+
logout_request2 = OneLogin::RubySaml::Logoutrequest.new.create_logout_request_xml_doc(settings)
|
274
|
+
logout_request2.sign_document(ruby_saml_key, ruby_saml_cert_text)
|
275
|
+
# verify our signature
|
276
|
+
signed_doc2 = XMLSecurity::SignedDocument.new(logout_request2.to_s)
|
277
|
+
signed_doc2.validate_document(ruby_saml_cert_fingerprint, false)
|
278
|
+
assert signed_doc2.validate_document(ruby_saml_cert_fingerprint, false)
|
279
|
+
end
|
280
|
+
|
281
|
+
it "sign a LogoutResponse" do
|
282
|
+
logout_response = OneLogin::RubySaml::SloLogoutresponse.new.create_logout_response_xml_doc(settings, 'request_id_example', "Custom Logout Message")
|
283
|
+
logout_response.sign_document(ruby_saml_key, ruby_saml_cert)
|
284
|
+
# verify our signature
|
285
|
+
signed_doc = XMLSecurity::SignedDocument.new(logout_response.to_s)
|
286
|
+
assert signed_doc.validate_document(ruby_saml_cert_fingerprint, false)
|
287
|
+
|
288
|
+
logout_response2 = OneLogin::RubySaml::SloLogoutresponse.new.create_logout_response_xml_doc(settings, 'request_id_example', "Custom Logout Message")
|
289
|
+
logout_response2.sign_document(ruby_saml_key, ruby_saml_cert_text)
|
290
|
+
# verify our signature
|
291
|
+
signed_doc2 = XMLSecurity::SignedDocument.new(logout_response2.to_s)
|
292
|
+
signed_doc2.validate_document(ruby_saml_cert_fingerprint, false)
|
293
|
+
assert signed_doc2.validate_document(ruby_saml_cert_fingerprint, false)
|
294
|
+
end
|
295
|
+
end
|
296
|
+
|
297
|
+
describe "StarfieldTMS" do
|
298
|
+
before do
|
131
299
|
@response = OneLogin::RubySaml::Response.new(fixture(:starfield_response))
|
132
|
-
@response.settings = OneLogin::RubySaml::Settings.new(
|
133
|
-
:idp_cert_fingerprint => "8D:BA:53:8E:A3:B6:F9:F1:69:6C:BB:D9:D8:BD:41:B3:AC:4F:9D:4D"
|
134
|
-
)
|
300
|
+
@response.settings = OneLogin::RubySaml::Settings.new( :idp_cert_fingerprint => "8D:BA:53:8E:A3:B6:F9:F1:69:6C:BB:D9:D8:BD:41:B3:AC:4F:9D:4D")
|
135
301
|
end
|
136
302
|
|
137
303
|
it "be able to validate a good response" do
|
@@ -153,6 +319,84 @@ class XmlSecurityTest < Minitest::Test
|
|
153
319
|
end
|
154
320
|
end
|
155
321
|
|
156
|
-
|
322
|
+
describe '#validate_document' do
|
323
|
+
describe 'with valid document' do
|
324
|
+
describe 'when response has signed message and assertion' do
|
325
|
+
let(:document_data) { read_response('response_with_signed_message_and_assertion.xml') }
|
326
|
+
let(:document) { OneLogin::RubySaml::Response.new(document_data).document }
|
327
|
+
let(:fingerprint) { '4b68c453c7d994aad9025c99d5efcf566287fe8d' }
|
328
|
+
|
329
|
+
it 'is valid' do
|
330
|
+
assert document.validate_document(fingerprint, true), 'Document should be valid'
|
331
|
+
end
|
332
|
+
end
|
333
|
+
|
334
|
+
describe 'when response has signed assertion' do
|
335
|
+
let(:document_data) { read_response('response_with_signed_assertion_3.xml') }
|
336
|
+
let(:document) { OneLogin::RubySaml::Response.new(document_data).document }
|
337
|
+
let(:fingerprint) { '4b68c453c7d994aad9025c99d5efcf566287fe8d' }
|
338
|
+
|
339
|
+
it 'is valid' do
|
340
|
+
assert document.validate_document(fingerprint, true), 'Document should be valid'
|
341
|
+
end
|
342
|
+
end
|
343
|
+
end
|
344
|
+
|
345
|
+
describe 'signature_wrapping_attack' do
|
346
|
+
let(:document_data) { read_invalid_response("signature_wrapping_attack.xml.base64") }
|
347
|
+
let(:document) { OneLogin::RubySaml::Response.new(document_data).document }
|
348
|
+
let(:fingerprint) { 'afe71c28ef740bc87425be13a2263d37971da1f9' }
|
349
|
+
|
350
|
+
it 'is invalid' do
|
351
|
+
assert !document.validate_document(fingerprint, true), 'Document should be invalid'
|
352
|
+
end
|
353
|
+
end
|
354
|
+
|
355
|
+
describe 'signature wrapping attack - doubled SAML response body' do
|
356
|
+
let(:document_data) { read_invalid_response("response_with_doubled_signed_assertion.xml") }
|
357
|
+
let(:document) { OneLogin::RubySaml::Response.new(document_data) }
|
358
|
+
let(:fingerprint) { '4b68c453c7d994aad9025c99d5efcf566287fe8d' }
|
359
|
+
|
360
|
+
it 'is valid, but the unsigned information is ignored in favour of the signed information' do
|
361
|
+
assert document.document.validate_document(fingerprint, true), 'Document should be valid'
|
362
|
+
assert_equal 'someone@example.org', document.name_id, 'Document should expose only signed, valid details'
|
363
|
+
end
|
364
|
+
end
|
365
|
+
|
366
|
+
describe 'signature wrapping attack - concealed SAML response body' do
|
367
|
+
let(:document_data) { read_invalid_response("response_with_concealed_signed_assertion.xml") }
|
368
|
+
let(:document) { OneLogin::RubySaml::Response.new(document_data) }
|
369
|
+
let(:fingerprint) { '4b68c453c7d994aad9025c99d5efcf566287fe8d' }
|
157
370
|
|
371
|
+
it 'is valid, but fails to retrieve information' do
|
372
|
+
assert document.document.validate_document(fingerprint, true), 'Document should be valid'
|
373
|
+
assert document.name_id.nil?, 'Document should expose only signed, valid details'
|
374
|
+
end
|
375
|
+
end
|
376
|
+
end
|
377
|
+
|
378
|
+
describe '#validate_document_with_cert' do
|
379
|
+
describe 'with valid document ' do
|
380
|
+
describe 'when response has cert' do
|
381
|
+
let(:document_data) { read_response('response_with_signed_message_and_assertion.xml') }
|
382
|
+
let(:document) { OneLogin::RubySaml::Response.new(document_data).document }
|
383
|
+
let(:idp_cert) { OpenSSL::X509::Certificate.new(ruby_saml_cert_text) }
|
384
|
+
let(:fingerprint) { '4b68c453c7d994aad9025c99d5efcf566287fe8d' }
|
385
|
+
|
386
|
+
it 'is valid' do
|
387
|
+
assert document.validate_document_with_cert(idp_cert), 'Document should be valid'
|
388
|
+
end
|
389
|
+
end
|
390
|
+
|
391
|
+
describe 'when response has no cert but you have local cert' do
|
392
|
+
let(:document) { OneLogin::RubySaml::Response.new(response_document_valid_signed_without_x509certificate).document }
|
393
|
+
let(:idp_cert) { OpenSSL::X509::Certificate.new(ruby_saml_cert_text) }
|
394
|
+
|
395
|
+
it 'is valid' do
|
396
|
+
assert document.validate_document_with_cert(idp_cert), 'Document should be valid'
|
397
|
+
end
|
398
|
+
end
|
399
|
+
end
|
400
|
+
end
|
401
|
+
end
|
158
402
|
end
|