I'm looking for a way that normal users can do remote changes on a linux box through a web interface. Say for example update the dns settings for their domain. The script needs to run under root. I have three questions.
Firstly, is the correct way to do this via SSH, with a user that you set to only have root access to the scripts. Using visudo?
Secondly, is there perhaps a better way to implement this? I'm thinking if the web interface server where i would store the auth key gets compromised. Though the attack surface would be rather limited due to the restrictions done in visudo?
Lastly, this would be run quite frequently, could that cause any issues?
Edited for clarify the purpose.