Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^3: "certificate verify failed" error while trying to connect to https:// site using use WWW::Mechanize

by rkrieger (Friar)
on Jul 18, 2011 at 09:58 UTC ( #915124=note: print w/ replies, xml ) Need Help??


in reply to Re^2: "certificate verify failed" error while trying to connect to https:// site using use WWW::Mechanize
in thread "certificate verify failed" error while trying to connect to https:// site using use WWW::Mechanize

First off: check whart sort of format you exported from your browser. You'll want PEM (plain base64 text with a -----BEGIN CERTIFICATE----- line at start). Try opening your file in a text editor and check if that's what you have. Export in different formats or convert your current file to PEM format (see the OpenSSL manual for that or the openssl) man page on a Unix system.

In short: when using HTTPS_CA_DIR you need a directory with PEM certificates in files named according to the hash of their (certificate) subject name. Perhaps HTTPS_CA_FILE is more useful for you (if you only have a single CA certificate to handle).

Why? The CA file directory should hold files in so-called PEM format and follow the instructions as listed in Crypt::SSLeay under Client Certificate Support. In fact, that points to the OpenSSL docs again with more instructions.


Comment on Re^3: "certificate verify failed" error while trying to connect to https:// site using use WWW::Mechanize
Select or Download Code
Re^4: "certificate verify failed" error while trying to connect to https:// site using use WWW::Mechanize
by sam_bakki (Monk) on Jul 19, 2011 at 08:46 UTC

    Hi rkrieger

    I ran the same script , which uses WWW::Mechanize to download https:// content. Which works like a charm :) any way thanks again for your advise and information about certificates.

    Another good reason to hate MS Windows :)

    Thanks
    Bakkiaraj M

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://915124]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (7)
As of 2014-07-25 09:08 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (170 votes), past polls