Click here to Skip to main content
16,005,120 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: A goto box Pin
Christian Graus6-Mar-03 15:20
protectorChristian Graus6-Mar-03 15:20 
GeneralRe: A goto box Pin
Moak6-Mar-03 15:23
Moak6-Mar-03 15:23 
GeneralRe: A goto box Pin
Chris Meech7-Mar-03 4:54
Chris Meech7-Mar-03 4:54 
GeneralRe: A goto box Pin
Stefan Pedersen6-Mar-03 10:34
Stefan Pedersen6-Mar-03 10:34 
GeneralThe EM_SETCUEBANNER message Pin
Cancer_6-Mar-03 10:06
Cancer_6-Mar-03 10:06 
GeneralRe: The EM_SETCUEBANNER message Pin
Blake Miller7-Mar-03 9:29
Blake Miller7-Mar-03 9:29 
GeneralListening on a socket, inside a network Pin
obe6-Mar-03 10:00
obe6-Mar-03 10:00 
GeneralRe: Listening on a socket, inside a network Pin
Moak6-Mar-03 14:59
Moak6-Mar-03 14:59 
obe wrote:
3. I send the port number to the client
4. The client attempts to connect to my machine using the port number I sent it - and it fails, if my machine is not the gateway. BTW - the IP that the client attempts to connect to is the IP of the gateway.


Usually all Peer-2-Peer applications do have problems with SNATed/filtered networks.

a) You need a static forwarding on your gateway (for each client inside LAN, yes not really handy and highly unsecure too)
b) Or your gateway is a Linux box which has an IRC module loaded. Then it translates intranet IP:port to external IP:port on-the-fly and back. This must be specific for each protocl, e.g. for DCC protocol (you also might need to adjust your IRC client settings to make use of it).

If somebody tries to connect to your PC your router/packetfilter/firewall receives an 'incoming connection' from internet. One you did NOT establish. Your router doesn't know to which internal host the data should be routed. How should your router know? The data could be assigned to any host/port combination in intranet or meant for nobody at all. If you make an explicit static forwarding for a port your router will be happy. Otherwise your router says "Don't know it, don't like it, good bye!" and the connection is rejected. So far what happens usually.
The IRC module (or iptable module) will AFAIK assign a few special highports and changes outgoing IP:port combinations inside a IRC DCC data stream to IP_external:port_special. Incoming traffic on a "special" highport is then detected and routed to the corresponding client inside the LAN. Please correct me if I'm wrong and this behaviour has changed meanwhile.

Btw, this problem is not IRC specific... that's why there are modules for known protocols, e.g. IRC and FTP.
Gnutella has a neat solution too, so called "pushs" which use already established connections instead of creating new ones (so avoiding the described 'incoming traffic' problem in handshake). However, if two filtered peers hit each other this "push" solution won't work in the end (and most peers are such refering to Gnutella host statistics).

Solutions... many are possible: e.g. IRC module, "pushs", special proxy or a friendly forwarding man in the middle, etc.
GeneralRe: Listening on a socket, inside a network Pin
obe6-Mar-03 23:58
obe6-Mar-03 23:58 
GeneralRe: Listening on a socket, inside a network Pin
Moak7-Mar-03 2:39
Moak7-Mar-03 2:39 
GeneralRe: Listening on a socket, inside a network Pin
obe7-Mar-03 2:57
obe7-Mar-03 2:57 
GeneralRe: Listening on a socket, inside a network Pin
Moak7-Mar-03 3:20
Moak7-Mar-03 3:20 
GeneralPrinting to non-default printer without showing dialog Pin
The Lady of Shallots6-Mar-03 9:59
The Lady of Shallots6-Mar-03 9:59 
GeneralRe: Printing to non-default printer without showing dialog Pin
CodeBrain6-Mar-03 21:52
CodeBrain6-Mar-03 21:52 
GeneralRe: Printing to non-default printer without showing dialog Pin
Roger Allen7-Mar-03 2:00
Roger Allen7-Mar-03 2:00 
Generalstatic global object initialization order Pin
Scott H. Settlemier6-Mar-03 9:56
Scott H. Settlemier6-Mar-03 9:56 
GeneralRe: static global object initialization order Pin
Stefan Pedersen6-Mar-03 10:22
Stefan Pedersen6-Mar-03 10:22 
GeneralRe: static global object initialization order Pin
Tim Smith6-Mar-03 10:30
Tim Smith6-Mar-03 10:30 
Generaldecoding a tcp stream Pin
Kuniva6-Mar-03 9:55
Kuniva6-Mar-03 9:55 
GeneralRe: decoding a tcp stream Pin
Stefan Pedersen6-Mar-03 10:19
Stefan Pedersen6-Mar-03 10:19 
GeneralRe: decoding a tcp stream Pin
Anonymous6-Mar-03 10:22
Anonymous6-Mar-03 10:22 
GeneralRe: decoding a tcp stream Pin
Kuniva6-Mar-03 10:32
Kuniva6-Mar-03 10:32 
GeneralRe: decoding a tcp stream Pin
Kuniva6-Mar-03 10:37
Kuniva6-Mar-03 10:37 
GeneralRe: decoding a tcp stream Pin
Abbas_Riazi7-Mar-03 20:21
professionalAbbas_Riazi7-Mar-03 20:21 
GeneralRe: decoding a tcp stream Pin
Kuniva8-Mar-03 4:26
Kuniva8-Mar-03 4:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.