bind to LHOST instead of 0.0.0.0, fixes #262
git-svn-id: file:///home/svn/framework3/trunk@5969 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
7d2f0c1bc0
commit
f1e71237e4
|
@ -59,7 +59,7 @@ module ReverseTcp
|
|||
|
||||
# Switch to IPv6 ANY address if the LHOST is also IPv6
|
||||
addr = Rex::Socket.resolv_nbo(datastore['LHOST'])
|
||||
lsnr = (addr.length == 4) ? "0.0.0.0" : "::0"
|
||||
lsnr = Rex::Socket.addr_ntoa(addr)
|
||||
|
||||
self.listener_sock = Rex::Socket::TcpServer.create(
|
||||
'LocalHost' => lsnr,
|
||||
|
@ -146,4 +146,4 @@ protected
|
|||
end
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue