Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

lwp::protocol::socks(3pm) [debian man page]

LWP::Protocol::socks(3pm)				User Contributed Perl Documentation				 LWP::Protocol::socks(3pm)

NAME
LWP::Protocol::socks - adds support for the socks protocol and proxy facility SYNOPSIS
use LWP::Protocol::socks; DESCRIPTION
Use this package when you wish to use a socks proxy for your connections. It provides some essential hooks into the LWP system to implement a socks "scheme" similar to http for describing your socks connection, and can be used to proxy either http or https connections. The use case is to use LWP::UserAgent's proxy method to register your socks proxy like so: $ua->proxy([qw(http https)] => 'socks://socks.yahoo.com:1080'); Then just use your $ua object as usual! EXAMPLES
#!/usr/local/bin/perl use strict; use LWP::UserAgent; my $ua = new LWP::UserAgent(agent => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.5) Gecko/20060719 Firefox/1.5.0.5'); # for socks5, use socks like so: $ua->proxy([qw(http https)] => 'socks://socks.yahoo.com:1080'); # for socks4, use socks4 like so: $ua->proxy([qw(http https)] => 'socks4://socks.yahoo.com:1080'); my $response = $ua->get("http://www.freebsd.org"); print $response->code,' ', $response->message," "; my $response = $ua->get("https://www.microsoft.com"); print $response->code,' ', $response->message," "; NOTES
I don't have much time to contribute to this. If you'd like to contribute, please fork https://github.com/scr/cpan and send me a pull request. AUTHORS
Sheridan C Rawlins <sheridan.rawlins@yahoo.com> Oleg G <oleg@cpan.org> perl v5.14.2 2012-02-12 LWP::Protocol::socks(3pm)

Check Out this Related Man Page

LWP::Protocol::https(3pm)				User Contributed Perl Documentation				 LWP::Protocol::https(3pm)

NAME
LWP::Protocol::https - Provide https support for LWP::UserAgent SYNOPSIS
use LWP::UserAgent; $ua = LWP::UserAgent->new(ssl_opts => { verify_hostname => 1 }); $res = $ua->get("https://www.example.com"); DESCRIPTION
The LWP::Protocol::https module provides support for using https schemed URLs with LWP. This module is a plug-in to the LWP protocol handling, so you don't use it directly. Once the module is installed LWP is able to access sites using HTTP over SSL/TLS. If hostname verification is requested by LWP::UserAgent's "ssl_opts", and neither "SSL_ca_file" nor "SSL_ca_path" is set, then "SSL_ca_file" is implied to be the one provided by Mozilla::CA. If the Mozilla::CA module isn't available SSL requests will fail. Either install this module, set up an alternative "SSL_ca_file" or disable hostname verification. This module used to be bundled with the libwww-perl, but it was unbundled in v6.02 in order to be able to declare its dependencies properly for the CPAN tool-chain. Applications that need https support can just declare their dependency on LWP::Protocol::https and will no longer need to know what underlying modules to install. SEE ALSO
IO::Socket::SSL, Crypt::SSLeay, Mozilla::CA COPYRIGHT
Copyright 1997-2011 Gisle Aas. This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.14.2 2012-02-20 LWP::Protocol::https(3pm)
Man Page

15 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Shell script to return all the ID's from file based on the distribution ID search

Hi, Please help me out on this I have to store some distribution lists(dl) in a file say mail.txt Say the file format be d1 = alok@yahoo.co.in;alvin@rediffmail.com;vijay@yahoo.com; & so on... d2 = abhinav@gmail.com;dalpit@hotmail.com;garima@yahoo.com;& so on... d3 = .... & so on Now what... (1 Reply)
Discussion started by: kumbhatalok
1 Replies

2. Shell Programming and Scripting

file sorting

i have a data in afile like this ************************************** sree sree@yahoo.com 98662323432 ************************************* phani phani@yahoo.com 98662323344 ************************************* i want to sort the file with respect to name. how can i do this. thank... (5 Replies)
Discussion started by: phani_sree
5 Replies

3. UNIX for Advanced & Expert Users

Mailx Command

Hi, mailx -s "hi" -r "abc@yahoo.com" aaa@yahoo.com<<EOF Hi, ~<!uuencode a.txt a.txt EOF the above code is sending mails, but attachment is not going instead i just get like below ~<!uuencode a.txt a.txt Thanks. (3 Replies)
Discussion started by: shahnazurs
3 Replies

4. Shell Programming and Scripting

Backup The Files In Unix

hi punters, i have a small requirement,i would need to code some script in AIX. please join me on yahoo anytime hrsuprith@yahoo.co.in hrsuprith@gmail.com (2 Replies)
Discussion started by: suprithhr
2 Replies

5. What is on Your Mind?

1st Post, and it's a moan :(

Wow! Took me 30 minutes to register here using FF 3 on Windows XP. But MS IE working like a dream. I suspect adblock was not happy. Or FF and our MS proxy settings here at work. Anyway, greetings, and I'll get on and post my first technical question in another forum. (4 Replies)
Discussion started by: Beast Of Bodmin
4 Replies

6. Shell Programming and Scripting

remove : lines from file

A small question I have a test.txt file I have contents as: a:google b:yahoo : c:facebook : d:hotmail How do I remove the line with : my output should be a:google b:yahoo c:facebook d:hotmail (5 Replies)
Discussion started by: aronmelon
5 Replies

7. Shell Programming and Scripting

Grep a string in a range and delete the line

Hi, i need to delete a lines after searching a particular string but this searching should only happen after the 4th line.. basically imagine a file like this From: abcd.yahoo.com To: cdeb.yahoo.com Subject: hi all sdfsd sadasd asdasd dfsdf From: abcd.yahoo.com To:... (3 Replies)
Discussion started by: depakjan
3 Replies

8. Shell Programming and Scripting

Filtering a file for unique entries

Hi All, I am trying to filter out a txt file containing 2 columns. Which has got website name and response time as below. Website_name response_time yahoo 22 google 21 yahoo 34 rediff 45 google 43 rediff 31 I want filter the above file with unique website names which has got highest... (5 Replies)
Discussion started by: anilreddy103
5 Replies

9. Shell Programming and Scripting

[Solved] Split file using awk

hlow all, need your advice i have sample.txt 1252468812,yahoo,3.5 1252468812,hotmail,2.4 1252468819,yahoo,1.2 1252468812,msn,8.9 1252468923,gmail,12 1232468819,live,3.4 1252368929,yahoo,9.0 1252468929,msn,1.2now i want filtering with awk so output will like this 12524_log.txt... (2 Replies)
Discussion started by: zvtral
2 Replies

10. Shell Programming and Scripting

Remove multiple blanks

Hi, I have data as below And I want output as Thanks (5 Replies)
Discussion started by: Anjan1
5 Replies

11. Shell Programming and Scripting

Compare two files and print using awk

I have 2 files: email_1.out 1 abc@yahoo.com 2 abc_1@yahoo.com 3 abc_2@yahoo.com data_1.out <tr> 1 MAIL # 1 TO src_1 </tr> <tr><td class="hcol">col_id</td> <td class="hcol">test_dt</td> <td class="hcol">user_type</td> <td class="hcol">ct</td></tr> <tr><td... (1 Reply)
Discussion started by: sol_nov
1 Replies

12. UNIX for Dummies Questions & Answers

Can't connect through ssh socks proxy to certain sites

Hello, i setup an open socks proxy on my remote vps: ssh -f -N -D 0.0.0.0:1080 localhost and then allowed only connections from IP of my home computer iptables -A INPUT --src myhomeip -p tcp --dport 1080 -j ACCEPT iptables -A INPUT -p tcp --dport 1080 -j REJECT but it appears that im... (3 Replies)
Discussion started by: postcd
3 Replies

13. Shell Programming and Scripting

Perl: How to run an POST/GET command via proxy?

Please what is the most simple way to run some perl command via proxy? i have perl script an in it: POST **something** GET **something** what should i do before it so its proxified via proxy without authentiffication, like 1.2.3.4:1080? any way to run whole .pl script via proxy? (3 Replies)
Discussion started by: postcd
3 Replies

14. Shell Programming and Scripting

Proxy socks tester issue

I have a list of ip socks / port(eg: 192.168.0.1 80). I would like to write a bash to test automatically these addresses in a loop with firefox. The problem is that firefox process stays alive even when firefox does not work because of wrong network settings. So I want to kill the process when the... (3 Replies)
Discussion started by: arpagon
3 Replies

15. UNIX for Dummies Questions & Answers

sed

i have a file (test.txt) which contains: jan@yahoo.com john@yahoo.com i' like to replace jan@yahoo.com and john@yahoo.com with test@gmail.com normally, i can do: sed -e 's/jan@yahoo.com/test.gmail.com/g' test.txt > test.txt1 and then sed -e... (5 Replies)
Discussion started by: lawsongeek
5 Replies