I would like to allow a remote script to access my Mac (Catalina 10.15.2) at the root level.

I know that I can enable keyboard-less access at the user level, by using publickey authentication, via ssh. This is handy, because it allows me to remotely execute scripts on my Mac, over ssh, from a script running on another host.

Is there a way to execute root commands, via ssh, without typing a password, without enabling login for the root account?

Are there other authentication methods for sudo, aside from password?

  • 1
    Did you see this question? proper way to sudo over ssh – lx07 Dec 31 '19 at 14:52
  • Yes. The solutions don't work for me on Catalina 10.15.2. There must be some differences between sudo on linux and mac os. Seems like the Mac sudo will not accept a password piped to it. – Matt Jan 8 '20 at 0:51

You must log in to answer this question.

Browse other questions tagged .