wook has asked for the wisdom of the Perl Monks concerning the following question:

I using a basic IO::Socket::INET script in an attempt to access my computer from work. Now, there is a router that the computer at home goes through.....all incomming traffic is forwarded to my computer mainly because I have a website hosted there. At first I thought the reason why I couldn't connect was because the website(apache based) was intercepting the call before it got to my socket program, but then I realized that this probably not the case bacause the connection is on different ports. My question is this, can someone explain to me how to get passed the router with a simple socket program?
  • Comment on IO::Socket::INET and getting past router

Replies are listed 'Best First'.
Re: IO::Socket::INET and getting past router
by ides (Deacon) on Oct 05, 2005 at 16:16 UTC

    By router I'm going to assume you mean a DSL/Cable "router" that also has a built in firewall. As a normal router wouldn't cause you any troubles.

    If all traffic to your computer at work just simply passes through the router/firewall then it most likely isn't the problem. However, if it only say passes port 80 traffic through to your computer ( as a good firewall would ), then you'll need to reconfigure your router/firewall to let through the port you are trying to use.

    Hope this helps...

    Frank Wiles <frank@wiles.org>
    http://www.wiles.org

Re: IO::Socket::INET and getting past router
by 5mi11er (Deacon) on Oct 05, 2005 at 21:21 UTC
    On top of the firewall at work likely to hinder you, is the fact that your DSL/Cable firewall also is going to need to be configured to allow your "socket" traffic through to the server behind it. The configuration should be quite similar to the configuration used to make the website accessable to the rest of the world.

    So, to answer your actual question, you can not get past a firewall using only socket programming. You must configure all the firewalls between you and the destination to allow the socket traffic.

    -Scott