File tree Expand file tree Collapse file tree 6 files changed +61
-26
lines changed Expand file tree Collapse file tree 6 files changed +61
-26
lines changed Original file line number Diff line number Diff line change 11#!/usr/bin/env php
22<?php
33
4+ declare (strict_types=1 );
5+
46require_once (dirname (__FILE__ , 3 ) . '/vendor/autoload.php ' );
57
68use SimpleSAML \XML \DOMDocumentFactory ;
9+ use SimpleSAML \XMLSchema \Type \Base64BinaryValue ;
710use SimpleSAML \XMLSecurity \Alg \Signature \SignatureAlgorithmFactory ;
811use SimpleSAML \XMLSecurity \Constants as C ;
12+ use SimpleSAML \XMLSecurity \Test \XML \CustomSignable ;
13+ use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
914use SimpleSAML \XMLSecurity \XML \ds \KeyInfo ;
1015use SimpleSAML \XMLSecurity \XML \ds \X509Certificate ;
1116use SimpleSAML \XMLSecurity \XML \ds \X509Data ;
12- use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
13- use SimpleSAML \XMLSecurity \Test \XML \CustomSignable ;
1417
1518$ document = DOMDocumentFactory::fromFile (dirname (__FILE__ , 2 ) . '/resources/xml/custom_CustomSignable.xml ' );
1619
2124
2225$ keyInfo = new KeyInfo ([
2326 new X509Data ([
24- new X509Certificate (PEMCertificatesMock::getPlainCertificateContents (
25- PEMCertificatesMock::SELFSIGNED_CERTIFICATE
26- ))
27- ])
27+ new X509Certificate (
28+ Base64BinaryValue::fromString (
29+ PEMCertificatesMock::getPlainCertificateContents (
30+ PEMCertificatesMock::SELFSIGNED_CERTIFICATE ,
31+ ),
32+ ),
33+ ),
34+ ]),
2835]);
2936
3037$ unsignedElement = CustomSignable::fromXML ($ document ->documentElement );
Original file line number Diff line number Diff line change 11#!/usr/bin/env php
22<?php
33
4+ declare (strict_types=1 );
5+
46require_once (dirname (__FILE__ , 3 ) . '/vendor/autoload.php ' );
57
68use SimpleSAML \XML \DOMDocumentFactory ;
9+ use SimpleSAML \XMLSchema \Type \Base64BinaryValue ;
710use SimpleSAML \XMLSecurity \Alg \Signature \SignatureAlgorithmFactory ;
811use SimpleSAML \XMLSecurity \Constants as C ;
9- use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1012use SimpleSAML \XMLSecurity \Test \XML \CustomSignable ;
13+ use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1114use SimpleSAML \XMLSecurity \XML \ds \KeyInfo ;
1215use SimpleSAML \XMLSecurity \XML \ds \X509Certificate ;
1316use SimpleSAML \XMLSecurity \XML \ds \X509Data ;
2124
2225$ keyInfo = new KeyInfo ([
2326 new X509Data ([
24- new X509Certificate (PEMCertificatesMock::getPlainCertificateContents (
25- PEMCertificatesMock::SELFSIGNED_CERTIFICATE
26- ))
27- ])
27+ new X509Certificate (
28+ Base64BinaryValue::fromString (
29+ PEMCertificatesMock::getPlainCertificateContents (
30+ PEMCertificatesMock::SELFSIGNED_CERTIFICATE ,
31+ ),
32+ ),
33+ ),
34+ ]),
2835]);
2936
3037$ unsignedElement = CustomSignable::fromXML ($ document ->documentElement );
Original file line number Diff line number Diff line change 11#!/usr/bin/env php
22<?php
33
4+ declare (strict_types=1 );
5+
46require_once (dirname (__FILE__ , 3 ) . '/vendor/autoload.php ' );
57
68use SimpleSAML \XML \DOMDocumentFactory ;
9+ use SimpleSAML \XMLSchema \Type \Base64BinaryValue ;
710use SimpleSAML \XMLSecurity \Alg \Signature \SignatureAlgorithmFactory ;
811use SimpleSAML \XMLSecurity \Constants as C ;
9- use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1012use SimpleSAML \XMLSecurity \Test \XML \CustomSignable ;
13+ use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1114use SimpleSAML \XMLSecurity \XML \ds \KeyInfo ;
1215use SimpleSAML \XMLSecurity \XML \ds \X509Certificate ;
1316use SimpleSAML \XMLSecurity \XML \ds \X509Data ;
2730
2831$ keyInfo = new KeyInfo ([
2932 new X509Data ([
30- new X509Certificate (PEMCertificatesMock::getPlainCertificateContents (
31- PEMCertificatesMock::SELFSIGNED_CERTIFICATE
32- ))
33- ])
33+ new X509Certificate (
34+ Base64BinaryValue::fromString (
35+ PEMCertificatesMock::getPlainCertificateContents (
36+ PEMCertificatesMock::SELFSIGNED_CERTIFICATE ,
37+ ),
38+ ),
39+ ),
40+ ]),
3441]);
3542
3643$ unsignedElement = CustomSignable::fromXML ($ document ->documentElement );
Original file line number Diff line number Diff line change 11#!/usr/bin/env php
22<?php
33
4+ declare (strict_types=1 );
5+
46require_once (dirname (__FILE__ , 3 ) . '/vendor/autoload.php ' );
57
68use SimpleSAML \XML \DOMDocumentFactory ;
9+ use SimpleSAML \XMLSchema \Type \Base64BinaryValue ;
710use SimpleSAML \XMLSecurity \Alg \Signature \SignatureAlgorithmFactory ;
811use SimpleSAML \XMLSecurity \Constants as C ;
9- use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1012use SimpleSAML \XMLSecurity \Test \XML \CustomSignable ;
13+ use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1114use SimpleSAML \XMLSecurity \XML \ds \KeyInfo ;
1215use SimpleSAML \XMLSecurity \XML \ds \X509Certificate ;
1316use SimpleSAML \XMLSecurity \XML \ds \X509Data ;
2831
2932$ keyInfo = new KeyInfo ([
3033 new X509Data ([
31- new X509Certificate (PEMCertificatesMock::getPlainCertificateContents (
32- PEMCertificatesMock::SELFSIGNED_CERTIFICATE
33- ))
34- ])
34+ new X509Certificate (
35+ Base64BinaryValue::fromString (
36+ PEMCertificatesMock::getPlainCertificateContents (
37+ PEMCertificatesMock::SELFSIGNED_CERTIFICATE ,
38+ ),
39+ ),
40+ ),
41+ ]),
3542]);
3643
3744$ unsignedElement = CustomSignable::fromXML ($ document ->documentElement );
Original file line number Diff line number Diff line change 11#!/usr/bin/env php
22<?php
33
4+ declare (strict_types=1 );
5+
46require_once (dirname (__FILE__ , 3 ) . '/vendor/autoload.php ' );
57
68use SimpleSAML \XML \DOMDocumentFactory ;
9+ use SimpleSAML \XMLSchema \Type \Base64BinaryValue ;
710use SimpleSAML \XMLSecurity \Alg \Signature \SignatureAlgorithmFactory ;
811use SimpleSAML \XMLSecurity \Constants as C ;
9- use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1012use SimpleSAML \XMLSecurity \Test \XML \CustomSignable ;
13+ use SimpleSAML \XMLSecurity \TestUtils \PEMCertificatesMock ;
1114use SimpleSAML \XMLSecurity \XML \ds \KeyInfo ;
1215use SimpleSAML \XMLSecurity \XML \ds \X509Certificate ;
1316use SimpleSAML \XMLSecurity \XML \ds \X509Data ;
2124
2225$ keyInfo = new KeyInfo ([
2326 new X509Data ([
24- new X509Certificate (PEMCertificatesMock::getPlainCertificateContents (
25- PEMCertificatesMock::SELFSIGNED_CERTIFICATE
26- ))
27- ])
27+ new X509Certificate (
28+ Base64BinaryValue::fromString (
29+ PEMCertificatesMock::getPlainCertificateContents (
30+ PEMCertificatesMock::SELFSIGNED_CERTIFICATE ,
31+ ),
32+ ),
33+ ),
34+ ]),
2835]);
2936
3037$ unsignedElement = CustomSignable::fromXML ($ document ->documentElement );
File renamed without changes.
You can’t perform that action at this time.
0 commit comments