SSH Socks5 Proxy

Secure Shell (SSH), sometimes known as Secure Socket Shell, is a UNIX-based command interface and protocol for securely getting access to a remote computer.

Socket Secure (SOCKS) is an Internet protocol that routes network packets between a client and server through a proxy server. SOCKS5 additionally provides authentication so only authorized users may access a server.

Secure Shell proxy for SOCKS5:

Synopsis:

/usr/lib/ssh/ssh-socks5-proxy-connect

[-h socks5_proxy_host]

[-p socks5_proxy_port] connect_host connect_port

Description:

A proxy command for ssh(1) that uses SOCKS5 (RFC 1928). Typical use is where connections external to a network are only allowed via a socks gateway server.

This proxy command does not provide any of the SOCKS5 authentication mechanisms defined in RFC 1928. Only anonymous connections are possible.

Options:

The following options are supported:

-h socks5_proxy_host

Specifies the proxy web server through which to connect. Overrides the SOCKS5_SERVER environment variable.

-p socks5_proxy_port

Specifies the port on which the proxy web server runs. If not specified, port 80 is assumed. Overrides the SOCKS5_PORT environment variable.

Operands:

The following operands are supported:

socks5_proxy_host

The host name or IP address (IPv4 or IPv6) of the proxy.

socks5_proxy_port

The numeric port number to connect to on socks5_proxy_host.

connect_host

The name of the remote host to which the socks gateway is to connect you.

connect_port

The numeric port number of the socks gateway to connect you to on connect_host.

Problem:

Currently setup a SSH session via a SOCKS5 proxy using the OpenSSH command:

ssh -o “connect -5 -S proxy.socks5.ip.name %h %p” target.ip.name

Now, I want to have my existing perl programs that use Net::SSH::Perl, to be able to use a SOCKS5 proxy, if needed. What is the best way to make this happen?

My current thought is to patch Net::SSH::Perl to use Net::SOCKS. Is there a better/easier/faster way?

We discussed this a bit in the chatterbox, and things that were said went along the lines of “use LD_PRELOAD to load a socksifier”. I have no clue on either of these things are.

I have existing perl programs that use Net::SSH::Perl, and I’d like to “just use them”, but have all the ssh stuff go through the SOCKS5 proxy.

Solution:

The dante debian package provides a program called socksify which:

Uses LD_PRELOAD environment variable to wrap all networking-related system calls so that programs can go thought a SOCKS server that was installed as part of a firewall.

I’d imagine something like socksify ./script.pl will do the trick.

If your program also needs to access some non-socksified subnet you’ll need to split your program into two parts which talk via a pipe (or similar).

The problem with this solution is that I need to have a socksify program built for all my platforms (MacOS, SunOS, Windows, linux), and I’m not sure that socksify will build for all of them. This is why I like Net::SSH::Perl so much. The native perl code provides the ssh protocol directly, so my perl code is easily plopped onto a platform, and will mostly, “just run”.

I think the better long-term way is to somehow have the Net::SSH::Perl module make use of the Net::SOCKS module to provide this functionality, when requested. Maybe I’ll just “dig-in” and see what happens.

Create a new class derived from Net::SSH::Perl and redefine the _connect method to do whatever you want. For instance, implementing the SOCKS5 protocol yourself (it’s a very simple one) or using an external SOCKS5 adapter connected by a pipe or a unix socket.

Get Access to Facebook using proxy

Now a day’s almost everybody use social media sites to stay connected with world. To see what’s going on in the world. The information of whole world is just click away from you. In social media sites Facebook is the most popular site among users. Facebook social media site where you can update your status, share your pictures videos and other information that you want to share with your friends and family.

Facebook also provide you the source of communication like video calling, chatting, now days almost every person have Facebook accounts and using Facebook. Peoples become addicted to use Facebook. Users stay online whole day and share their pictures and status of every moment.

Specially students are crazy to use Facebook. Students spends too much timing on surfing Facebook . Keeping in view this issue administration of institute make restriction on using Facebook in premises of institute. By making a filter on the ISP of institute. It is possible with the help of different software’s. In this way students are not able to get access on Facebook in schools.

As I said above students are addicted to use Facebook. They need Facebook at any cost. Students are so smart and intelligent they start finding alternate sources to get access on Facebook. Some of them succeeded in finding alternate sources and some of them remain unsuccessful.

I have good news for those who remain unsuccessful in finding alternative ways. There is Proxy Server which helps you to Unblock Facebook. This source to get access on Facebook is very simple and easy in use. An average user of internet can easily use proxy sites. These proxy servers are reliable and efficient.

User just needs to go to his browser and search for proxy server. browser shows a list of proxy sites. Then user has to select one of them. Homepage of selected proxy site appears on screen of computer. Homepage of proxy site contains address bar. Where you have to enter URL address of Facebook. in a seconds the homepage of site appears on your screen. Now you are free to surf Facebook.

Proxy sites play a role of middle man. It takes request of your required site from you and hides the IP of restricted site and sends it to the server of your required site in this way. You ISP don’t know which site you are requesting. And proxy sites bring a home page of your requested sites.

There is no need of any kind of software in your computer. And there is no difference in speed of working.

I hope you will get effective results by adopting this method to unblock Facebook.