in reply to How do i post the page in https

Access to SSL (https) connections either via LWP or WWW::Mechanize is, from the programmers view, not different to a "normal" http connection. That means you don't have to undertake something special. Just use the above modules and have Crypt::SSLeay installed.

What exactly is the problem you are facing?


holli, /regexed monk/

Replies are listed 'Best First'.
Re^2: How do i post the page in https
by chiragforever (Novice) on Aug 22, 2005 at 14:02 UTC
    Actually the problem is , i dont know the syntax for the post operation over https for perl.
    Below is the code for post operation over the http and this code is working fine for me.Could you please modify this code for the post operation over https.
    use HTTP::WebTest; my $webtest=new HTTP::WebTest; $url="http://mail.rediff.com/"; $proxy="http://192.168.1.60:3128"; @proxy=("proxies",[http=>$proxy]); $webtest->run_tests( [ { test_name=>"Posting the data for logging into site..", url => $url."cgi-bin/login.cgi/", method => POST, params=>[ FormName=>existing, login=>'username', passwd=>'********' ], } ], { @proxy, } ); $a=$webtest->current_response->content;

    holli fixed formatting

      First, read up about Writeup Formatting Tips to learn how to format your posts properly.

      To address your problem:
      From what I see from the docs of HTTP::WebTest it uses LWP under the hood. In the docs it says
      If you want to test https:// web sites you may have to install additional modules to enable SSL support in LWP. In short you may have to install Crypt::SSLeay module. For details see README.SSL file in LWP distro.
      So, as mentioned above, you don't have to take any measures, besides of installing Crypt::SSLeay. There is no special syntax. Simply use
      $url="https://my.site.com/";


      holli, /regexed monk/