iagox86 / dnscat2

BSD 3-Clause "New" or "Revised" License
3.43k stars 601 forks source link

syntax error /dnscat2/server/dnscat2.rb #79

Closed johnjohnsp1 closed 8 years ago

johnjohnsp1 commented 8 years ago

Hello,

running a virtual machine kali linux 2.0 x64, downloaded dnscat2 from github, used your instructions about install but when i launch the command:

/dnscat2/Server/ruby dnscat2.rb i get this error:

/root/dnscat2/server/libs/swindow.rb:286:in activate': undefined methodclear' for Readline::History:Class (NoMethodError) from /root/dnscat2/server/libs/swindow.rb:155:in initialize' from dnscat2.rb:16:innew' from dnscat2.rb:16:in `

'

ruby 2.1.5p273 (2014-11-13) [x86_64-linux-gnu]

are you able to tell me about this ? thanks

iagox86 commented 8 years ago

Weird! I'll take a look in a couple hours, thanks for the report! On 18 Nov 2015 6:50 a.m., "johnjohnsp1" notifications@github.com wrote:

Hello,

running a virtual machine kali linux 2.0 x64, downloaded dnscat2 from github, used your instructions about install but when i launch the command:

/dnscat2/Server/ruby dnscat2.rb i get this error:

/root/dnscat2/server/libs/swindow.rb:286:in activate': undefined methodclear' for Readline::History:Class (NoMethodError) from /root/dnscat2/server/libs/swindow.rb:155:in initialize' from dnscat2.rb:16:innew' from dnscat2.rb:16:in ` '

ruby 2.1.5p273 (2014-11-13) [x86_64-linux-gnu]

are you able to tell me about this ? thanks

— Reply to this email directly or view it on GitHub https://github.com/iagox86/dnscat2/issues/79.

iagox86 commented 8 years ago

Hmm, that's really weird.. it looks like Readline might be implemented in a funny way. I tested on 1.9.

Can you try the current HEAD (revision c0fe72474)?

johnjohnsp1 commented 8 years ago

Hello Ron,

i can confirm it now works !

thanks for fix, awesome tool btw

as example:

root@kalivmfusion:~/dnscat2/server# ruby dnscat2.rb

New window created: 0 dnscat2> New window created: crypto-debug Welcome to dnscat2! Some documentation may be out of date.

auto_attach => false history_size (for new windows) => 1000 Security policy changed: All connections must be encrypted New window created: dns1 Starting Dnscat2 DNS server on 0.0.0.0:53 [domains = n/a]...

It looks like you didn't give me any domains to recognize! That's cool, though, you can still use direct queries, although those are less stealthy.

To talk directly to the server without a domain name, run:

./dnscat --dns server=x.x.x.x,port=53 --secret=8d06ba31dcff0e8422c5bb562bbc696c

Of course, you have to figure out yourself! Clients will connect directly on UDP port 53.

Luca Grembo Via Roma 35 20021-Bollate Milano (Italia) +39 3930413941 luca.grembo@gmail.com

Il giorno 18 nov 2015, alle ore 15:31, Ron notifications@github.com ha scritto:

Hmm, that's really weird.. it looks like Readline might be implemented in a funny way. I tested on 1.9.

Can you try the current HEAD (revision c0fe724 https://github.com/iagox86/dnscat2/commit/c0fe72474f4f8acca299d71be1b315e9006ba51d)?

— Reply to this email directly or view it on GitHub https://github.com/iagox86/dnscat2/issues/79#issuecomment-157729180.

iagox86 commented 8 years ago

Great, thanks for following up!

One comment: you won't have a per-session Readline history (so if you press you'll get commands from other windows). I'm not sure how to fix that, but it's not really a huge deal. :)