I want to develop with the scapy network package for python using PyCharm. It requires root access to craft certain packets and go over certain ports. I am currently running PyCharm as root but am wondering if there is a more secure way to do this. I tried to set python with SUID which is probably worse but scapy still would not run. Any suggestions would be appreciated.
Asked
Active
Viewed 1,567 times
1 Answers
1
You're on the right track. Running PyCharm as root is messy. You want to get PyCharm to execute the python script that uses scapy with root permissions. Setting the setuid bit on the python program itself is close but not sufficient.
The best I've found is a set of instructions that say "whenever I run python, do it automatically using sudo".
The full details can be found here: rundebug-as-root-in-pycharm
Good luck!

Spiceisland
- 61
- 1
- 4