Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
RSA lib called within XML::Sig fails to verify XML Signature genarated from windowsby sujathagkn (Initiate) |
on Jun 02, 2017 at 13:55 UTC ( [id://1191954]=perlquestion: print w/replies, xml ) | Need Help?? |
sujathagkn has asked for the wisdom of the Perl Monks concerning the following question: Hi I have a requirement to validate the SAML Assertion XML Signature generated in Windows Identity Foundation (WIF) from the Perl script. I tried to implement this by loading the Assertion XML generated from WIF and calling verify on XML::Sig Perl module as shown below
WIF from windows is adding the pem content of the X509 Pub Certificate content to the X509Certificate tag. But when the above xml is loaded for signature verification XML::Sig throws an error "OpenSSL error: bad base64 decode". After going through the XML::Sig and Crypt::OpenSSL::RSA modules found that the expected value in X509Certificate is "RSA Public key”, it does not support X500 pem content. So tried placing RSA public key within the X509 Certificate and called XML::Sig->verify , but the verify function never returned true. Can you please help me what am I missing here. Is the windows signed XML can be verified from Linux (Redhat 5.x)? Please share any hints/thoughts in getting the signature verification working in Perl. Thanks Sujatha
Back to
Seekers of Perl Wisdom
|
|