Hi Jiang. First, TorCtl is being deprecated by two newer (more
actively developed) controller libraries...
Stem (https://stem.readthedocs.org/en/latest/) - Threaded library with
a similar design to TorCtl.
Txtorcon (https://txtorcon.readthedocs.org/en/latest/) - Twisted based
controller library.
I just start to use tor controller, I notice the mannual says:
pass Tor the "--CookieAuthentication 1" option when you start it.
Tor will create a file in its data directory
called "control_auth_cookie". All your controller needs to do is to
pass the contents of this file to authenticate()
wh