restrict sudoers by envirnmoent
Can someone think of a way to do this with sudoers?
I want sudo to not ask for a password (easy), but only if I'm connected via ssh (not so easy).
Is there someway to check for an environment variable? I could use the existence of SSH_CONNECTION to verify it, and even better, restrict this behavior to when I'm connecting from a specified subnet.