Metasploit mailing list archives

sending UDP to broadcast address


From: dninja at gmail.com (Robin Wood)
Date: Mon, 13 Jul 2009 16:08:53 +0100

2009/7/13 HD Moore <hdm at metasploit.com>:
On Mon, 13 Jul 2009 07:37:57 -0500, Robin Wood <dninja at gmail.com> wrote:

2009/7/12 HD Moore <hdm at metasploit.com>:

On Sat, 11 Jul 2009 18:34:27 -0500, Robin Wood <dninja at gmail.com> wrote:

I've tried <broadcast> and still can't get anything. I've dug through
the socket and udp libraries and can't work out what I'm doing wrong.
If I put a unicast IP or a hostname as the sendto parameter the code
works.

The socket library is updated -- to make a broadcast-send capable socket,
pass 'Broadcast' => true in the creation parameters (with 'PeerHost', etc).

Two bugs, you missed an end at the end of

./lib/rex/socket/parameters.rb

And did you forget to commit something as I get

undefined method `peerhost=' for #<Rex::Socket::Parameters:0xb6594384>

followed by

undefined method `localhost=' for #<Rex::Socket::Parameters:0xb659c994>

if I comment out the peerhost stuff.

I haven't got time to debug it now but I'll have a look at it later,
see if I can see what is wrong rather than just saying it doesn't
work.

Robin


Current thread: