I have a server with which I cannot use pre-shared keys and ssh
- all authentication is via interactive prompts.
That server also has cron
and at
disabled for non-root users.
I would like to be able to cron
a job on my local machine that will run a script against the remote server to do periodic maintenance/reporting.
I've dallied with expect
some, but have noticed that in order for it to automate putting the password to the prompt at the right time, it needs to be stored in cleartext.
Is there a way to secure the password in such a way that I enter it once, then it's scrambled/whatever locally (like passwd
does), and then I'm not storing the plaintext password in the script itself?