Luigi Auriemma

aluigi.org (ARCHIVE-ONLY FORUM!)
It is currently 19 Jul 2012 11:41

All times are UTC [ DST ]





Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Round robin like option for stcpipe
PostPosted: 07 Dec 2010 10:43 

Joined: 07 Dec 2010 10:38
Posts: 5
Currently stcpipe allows you to specify a list of destination servers, and then walks through each one sequentially. Is there any chance the tool could support a round-robin like function where it send the first request to dest1, the second to dest2, etc... or at the very least a randomization method where the first request goes to dest3, the next to dest1, the next to dest2, etc...

Thanks.


Top
 Profile  
 
 
 Post subject: Re: Round robin like option for stcpipe
PostPosted: 07 Dec 2010 11:07 

Joined: 13 Aug 2007 21:44
Posts: 4068
Location: http://aluigi.org
stcppipe supports 2 ways:
- default: the one you know, the so called "fail-safe" way where if the first host is unreachable it goes with the second one
- option -M: when it receives a connection it replicate the same connection on all the hosts in the list so if a client sends "aaaa" it will be sent to all at the same time

so only -M can be enough closer to what you are looking for


Top
 Profile  
 
 Post subject: Re: Round robin like option for stcpipe
PostPosted: 07 Dec 2010 16:55 

Joined: 07 Dec 2010 10:38
Posts: 5
Thanks for the reply. I'm not clear how the second option works. The request is sent to all destination servers at the same time? From what I've seen in testing the client doesn't receive anything back from any of the destination servers.


Top
 Profile  
 
 Post subject: Re: Round robin like option for stcpipe
PostPosted: 08 Dec 2010 10:09 

Joined: 13 Aug 2007 21:44
Posts: 4068
Location: http://aluigi.org
with -M everything you send is sent to any server and you receive the reply from all the servers.

to see what I mean you can run 4 cmd.exe with the following commands:
nc -L -p 12345 -v -v -n
nc -L -p 1234 -v -v -n
stcppipe -M 127.0.0.1:1234,127.0.0.1:12345 0 123
nc 127.0.0.1 123 -v -v

so when with the last command you connect to port 123 you will automatically enter in communication with both the netcat servers


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for: