vitor - safely edit the Tor configuration file

Excellent!

1 Like
test -L filename

…checks symlinks.

1 Like

I was thinking of just checking if the file is a regular, because that would block all others types of files.

pure-bash-bible - file conditionals

  • -b block special file
  • -c character special file
  • -d directory
  • -h, -L symbolic link
  • -p named pipe
  • -t open file descriptor
  • -S socket

From all of the file alternatives, I don’t think vitor should edit anything that is not a a -f regular file. What do you think?

That is OK.

Pointing out “it’s a symlink” would be good for usability. If you like implementing this. Small usability gain.

if test -L /path/to/filename ; then
   echo something
fi
1 Like

More answers to come soon, probably.

Yes, edit regular file only.

1 Like

Well, a lot of this is for quite advanced threat models. The problem is, while many geeks assume that threat model, I haven’t seen it fully spelled out.

It’s for very nuanced, advanced threat models. See:

There are good arguments between “all sudo is security theater”, “malware running under user account is as good as root compromise” as well as

So in case of editing a torrc file on the gateway (maybe even any Debian) it’s hard to come up with a realistic threat where this would prevent security compromise.

1 Like

Pointing out “it’s a symlink” would be good for usability. If you like implementing this. Small usability gain.

Done with info messages.

So in case of editing a torrc file on the gateway (maybe even any Debian) it’s hard to come up with a realistic threat where this would prevent security compromise.

Yeah, no way to cover all possible security ground. What could be done was done.

1 Like

Vitor is not gonna be included by TPO because now they are focusing on Rust for Arti, so unless someone contributes, it is not gonna happen upstream.

1 Like