foospidy/HoneyPy

Line 83 Syntax error

Kojee opened this issue · 7 comments

Kojee commented

I've tried using HoneyPy on my RaspberryPi, with the following command:

python3 Honey.py (you can see the screenshot i took http://imgur.com/O19QdEY)

I don't know what's the problem, I'm not used with python but I checked the code and found nothing.

Thanks for giving HoneyPy a try. Something I should have mentioned in the documentation is that I've only be using Python 2.7 while developing/running HoneyPy. I noticed you are using python3, are you able to try it with python 2.7.9?

It's not obvious to me what the syntax error is, but I'll try running it with python3 and see if I can figure it out. As a side note, I was able to run HoneyPy on a Raspberry Pi with Raspbian - and I'm sure I was using Python 2.7

Kojee commented

Yeah I do tried the normal python command and it gave me some modules issues, this is what I got:
http://imgur.com/ecep30H

Edit : Also I'm using 2.7.3, could it be the problem? How can I update to 2.7.9?

It looks like you need to install the Twisted framework, run the following as root or with sudo:

apt-get install python-twisted

Also, make sure you review the Dependencies section of the readme file to make sure you have all dependencies. https://github.com/foospidy/HoneyPy/blob/master/README.md

Let me know if this works.

Kojee commented

Ty i'll try later when i get home

The syntax error you were getting when running with python3 is related to print statement syntax. I fixed that in Honey.py, but files in the lib or plugins directory may need to be updated as well. However it seems there may be more issues running with python3. I'll leave this issue open as a reminder to look into python3 support, but it may be a while as it is not high on my priority list :)

As for upgrading to 2.7.9 on Raspbian, first confirm you have all dependencies installed. I can actually run HoneyPy on a Debian system with 2.7.3 so it should work for you if you have twisted installed. If that doesn't work then you may need to upgrade Raspbian to the latest. As a reference this thread might be useful: https://www.reddit.com/r/raspberry_pi/comments/33ti0k/how_do_you_upgrade_python_273_to_279_on_raspbian/

But I would follow these steps:

  1. confirm you are on wheezy by checking the /etc/apt/sources.list file
  2. run (as root or with sudo): apt-get update; apt-get upgrade; apt-get dist-upgrade
  3. edit the /etc/apt/sources.list file, change all instances of "wheezy" to "jessie"
  4. run (as root or with sudo): apt-get update; apt-get dist-upgrade
  5. reboot
Kojee commented

Ty very much, I installed twisted and everything worked.

Great! Since your issue is resolved I'll close this and open a new issue for python3 support. Thanks!