Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#15777 closed defect (not a bug)

arm doesn't connect to UNIX domain ControlPort with cookie authentication

Reported by: yurivict271 Owned by:
Priority: Medium Milestone:
Component: Archived/Nyx Version:
Severity: Keywords:
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

There is nothing in the man page about this. It seemed like ~/.arm/armrc should have helped but this armrc:

DataDirectory /var/tmp/tor/data
ControlSocket /var/tmp/tor/ctrl
CookieAuthentication 1
CookieAuthFile /var/tmp/tor/data/control_auth_cookie

doesn't make arm connect, and it still asks for the passwod.

Command line should support this. Natural syntax would be: -i /var/tmp/tor/ctrl:/var/tmp/tor/data/control_auth_cookie

Child Tickets

Change History (8)

comment:1 Changed 5 years ago by atagar

Component: - Select a componentnyx
Resolution: worksforme
Status: newclosed

Hi yurivict271. Iirc the 1.4.5 release had an issue where cookie authentication wouldn't work with a ControlSocket. This setup is pointless (cookie auth doesn't provide you anything a ControlSocket doesn't) but that aside this is already fixed in the git codebase.

I'd suggest dropping CookieAuthentication or switching to a ControlPort for now.

Cheers! -Damian

comment:2 Changed 5 years ago by yurivict271

I *am* using ControlPort - UNIX domain socket.
Cookie provides the ability to log into any of many tor instances with the command line w/out the password.

Last edited 5 years ago by yurivict271 (previous) (diff)

comment:3 Changed 5 years ago by yurivict271

Resolution: worksforme
Status: closedreopened

Git version doesn't have this either.

Tor supports UNIX domain ControlSocket, and this should be supported by arm with cookie auth for the ease of use from shell. Otherwise, how am I going to login? Type password every time? Cookie is for this.

Ideally it should be a command line for this, no need for ~/.arm/armrc, because in case of many instances armrc is a trouble.

Last edited 5 years ago by yurivict271 (previous) (diff)

comment:4 Changed 5 years ago by atagar

Git version doesn't have this either.

Ah, I see the issue. You mentioned using...

arm -i /var/tmp/tor/ctrl:/var/tmp/tor/data/control_auth_cookie

... but actually you want the -s or --socket argument. Also, there's no need to have the auth cookie location (that'll just cause an error, and I'm unsure why you think that would be valid syntax).

What happens when you run the following with the git checkout?

run_nyx -s /var/tmp/tor/ctrl

comment:5 Changed 5 years ago by yurivict271

arm from git doesn't have -s argument.
What's run_nyx?

comment:6 Changed 5 years ago by atagar

arm from git doesn't have -s argument.
What's run_nyx?

Arm was renamed to nyx. If you're using the git repository and executing something called 'arm' then you're running the wrong thing ('arm' no longer exists in the git codebase)...

moirai:/tmp% git clone https://git.torproject.org/nyx.git
Cloning into 'nyx'...
remote: Counting objects: 8425, done.
remote: Compressing objects: 100% (2217/2217), done.
remote: Total 8425 (delta 6504), reused 7977 (delta 6176)
Receiving objects: 100% (8425/8425), 2.16 MiB | 1.20 MiB/s, done.
Resolving deltas: 100% (6504/6504), done.

moirai:/tmp% cd nyx/
moirai:/tmp/nyx% ./run_nyx --help
...

Note that you'll also need stem to run the git codeabase.

comment:7 Changed 5 years ago by yurivict271

Resolution: not a bug
Status: reopenedclosed

Ah, Thanks!

I didn't know about the arm->nyx rename. I've let FreeBSD port maintainer know.

Yuri

comment:8 Changed 5 years ago by atagar

No problem, sorry about the confusion. The rename is presently moot for users since arm is the last release (1.4.5). I hope to have a new release at which point the name will take effect later this year.

Note: See TracTickets for help on using tickets.