selective-php / xmldsig

Sign XML Documents with Digital Signatures
MIT License
73 stars 34 forks source link

sign with the .p12 file #6

Closed EDcasa closed 3 years ago

EDcasa commented 3 years ago

How to sign with the .p12 file?

odan commented 3 years ago

The filename extension for PKCS #12 files is .p12 or .pfx So it should work like this:

$xmlSigner->loadPfxFile('filename.p12', 'password');

or load a p12 from a string:

$xmlSigner->loadPfx('p12 content', 'password');