在浏览有关使用 tor 更改身份时,我有以下脚本:
from TorCtl import TorCtl
conn = TorCtl.connect(controlAddr="127.0.0.1", controlPort=9051, passphrase="123")
TorCtl.Connection.send_signal(conn, "NEWNYM")
但我得到这个错误:
Connection refused. Is the ControlPort enabled?
Traceback (most recent call last):
File "python_tor.py", line 18, in <module>
TorCtl.Connection.send_signal(conn, "NEWNYM")
TypeError: unbound method send_signal() must be called with Connection instance as first argument (got NoneType instance instead)
密码应该是什么?我试过没有密码,同样的错误发生了。