in reply to Networking in perl

You say that your client does not have an internet connection.

From the specification of the script you are trying to write, it sounds like they do, and you need to provide some sort of proxy to access it.

If that is the case, then I think you would be better served by looking at existing proxy software such as squid, and seeing how you can configure it to suit your needs.

In any case, you don't want to do network programming at the packet level if you don't have to. To operate a web proxy, even your rather strange one, you should be working at the TCP/IP stream level, but before you dive in, I think you need to step back and understand a bit better what your client needs.

Replies are listed 'Best First'.
Re^2: Networking in perl
by KVB (Novice) on Jan 17, 2011 at 05:09 UTC
    Hi, Thanks for replying. I am very much new to networking & perl. Here my client and server communicate through different protocol..for e.g GTP . So i need IP packet and wrap it into gtp header and send.And I am not bother about how my server acts on it.I just want to send that packet to the server.help me

      This is not realy a perl question.

      An internet search for GTP turns up GPRS_Tunnelling_Protocol Is that what you mean?

      If you are looking to tunnel internet packets through another networking protocol, then you need to setup a VPN. If you want to limit the traffic that can go through that VPN, then you need to put a firewall, and possibly a proxy in front of it. So to limit the websites that your users can access, you could setup the firewall so that it will only accept web connections from the proxy, and setup the proxy so that only a white list of sites are allowed.