iagox86 / dnscat2

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

Syntax error when run `ruby ./dnscat2.rb` #101

Closed ourlord closed 8 years ago

ourlord commented 8 years ago

Follow the steps in the page. Run as root. Gem and install bundler doesn't have any issue. Issue happened when run ruby ./dnscat2.rb from the first time.

New window created: 0
./controller/controller.rb:11:in `require': ./controller/controller_commands.rb:29: syntax error, unexpected ')' (SyntaxError)
./controller/controller_commands.rb:50: syntax error, unexpected ')'
    from ./controller/controller.rb:11
    from ./dnscat2.rb:18:in `require'
    from ./dnscat2.rb:18

My ruby version: ruby 1.8.7 (2012-02-08 MBARI 8/0x6770 on patchlevel 358) [x86_64-linux], MBARI 0x6770, Ruby Enterprise Edition 2012.02. Gem is 2.6.6. Bundle version 1.13.1.

iagox86 commented 8 years ago

Can you try upgrading to Ruby 1.9 and see if that helps?

I try hard to maintain reverse compatibility, but right now I'm testing on 1.9 and later, not 1.8.

On Tue, Sep 20, 2016 at 2:44 PM, Loki Lawliet notifications@github.com wrote:

Follow the steps in the page. Run as root. Gem and install bundler doesn't have any issue. Issue happened when run ruby ./dnscat2.rb from the first time.

New window created: 0 ./controller/controller.rb:11:in require': ./controller/controller_commands.rb:29: syntax error, unexpected ')' (SyntaxError) ./controller/controller_commands.rb:50: syntax error, unexpected ')' from ./controller/controller.rb:11 from ./dnscat2.rb:18:inrequire' from ./dnscat2.rb:18

My ruby version: ruby 1.8.7 (2012-02-08 MBARI 8/0x6770 on patchlevel 358) [x86_64-linux], MBARI 0x6770, Ruby Enterprise Edition 2012.02

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/iagox86/dnscat2/issues/101, or mute the thread https://github.com/notifications/unsubscribe-auth/AAgITEv8dopjxjjSXWzZRIghQpOXiQNnks5qsFPRgaJpZM4KCLVI .

ourlord commented 8 years ago

Seems to work after migrate from ruby 1.8 to 1.9. Thanks a lot.