Solved

perl ssl

Posted on 2010-11-12
4
407 Views
Last Modified: 2012-05-10
Hi ,

I have a http site .

Many of my linux daemon using the perl.

I have all the ssl packages .I need a way to use ssl using perl.

Thanks
0
Comment
Question by:magento
  • 2
4 Comments
 
LVL 16

Expert Comment

by:jmatix
ID: 34120619
You can use LWP Perl module to do all http and https transfers. See example below. Check LWP documentation for details at:

http://search.cpan.org/~gaas/libwww-perl-5.837/lib/LWP.pm




use LWP;

my $browser = LWP::UserAgent->new;



my $response = $browser->get("https://www.yoururl.com/");



die "$url error: ", $response->status_line

   unless $response->is_success;



print $response->content;

Open in new window

0
 
LVL 3

Expert Comment

by:ggupta7
ID: 34120632
0
 
LVL 5

Author Comment

by:magento
ID: 34134830
jmatix,

I understand ,but when i am trying to use https ,i am getting error like (no ssl found in the IO ) please advice.
0
 
LVL 16

Accepted Solution

by:
jmatix earned 500 total points
ID: 34137868
SSL connection requires Perl module IO::Socket::SSL. Install that module from CPAN.

http://search.cpan.org/~sullr/IO-Socket-SSL/SSL.pm

0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Email validation in proper way is  very important validation required in any web pages. This code is self explainable except that Regular Expression which I used for pattern matching. I originally published as a thread on my website : http://www…
In the distant past (last year) I hacked together a little toy that would allow a couple of Manager types to query, preview, and extract data from a number of MongoDB instances, to their tool of choice: Excel (http://dilbert.com/strips/comic/2007-08…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now