[xmlsec] Problem when using the xmlSecOpenSSLAppKeyLoadMemory() API.
Aleksey Sanin
aleksey at aleksey.com
Tue Apr 2 11:08:54 PDT 2013
You will need to debug what's going on at the openssl level. If I would
guess then I would think you didn't load the key into memory correctly.
Aleksey
On 4/2/13 8:00 AM, Venkataragavan Vijayakumar wrote:
> Hi All,
>
> Previously I have used the xmlSecCryptoAppKeyLoad() API to load the Key
> file in the PEM format , it worked fine, but when i start to use
> xmlSecCryptoAppKeyLoadMemory() with the same content in the key file is
> given as input as buffer, it given error as
>
>
> func=xmlSecOpenSSLAppKeyLoadBIO:file=app.c:line=263:obj=unknown:subj=PEM_read_bio_PrivateKey
> and PEM_read_bio_PUBKEY:error=4:crypto library function
> failed:
>
> func=xmlSecOpenSSLAppKeyLoadMemory:file=app.c:line=205:obj=unknown:subj=xmlSecOpenSSLAppKeyLoadBIO:error=1:xmlsec
> library function failed:
>
>
> *
>
> code used like this*:
>
> dsigCtx->signKey =
> xmlSecCryptoAppKeyLoadMemory(keybuf,keysize,xmlSecKeyDataFormatPem,
> NULL, NULL, NULL);
> if(dsigCtx->signKey == NULL) {
> fprintf(stderr,"Error: failed to load private pem key from
> \"%s\"\n", key_file);
> goto done;
> }
>
> Please help me to resolve this issue.
>
> Thanks,
> Venkat.
>
>
>
> _______________________________________________
> xmlsec mailing list
> xmlsec at aleksey.com
> http://www.aleksey.com/mailman/listinfo/xmlsec
>
More information about the xmlsec
mailing list