Let’s modify the 3-minute guide for creating Linux shared folder using Samba software, to allow users access public folders without prompting for password authentication.
This open source software, sshpass, only does one simple thing, i.e. tricks to SSH client to believe that the user is perform interactive password authentication.
For security’s sake, we should use public-key cryptography authentication method to automate SSH login without password. But, what can you do if the SSH server in router modem doesn’t allow you add or install public key?
How to automate SSH login using password, if the destination server (e.g. home router modem) doesn’t support public-key cryptography authentication method?
The purpose of using such inconvenient approach is not for fun, but it’s because a string literal can be easily exposed by the strings command output!
So, here is the guideline I used to build mailsend with statically-linked OpenSSL library.
Mailsend is an open-source, console-based SMTP client which is great for sending authenticated email (via Microsoft Exchange or Gmail, for example) at command-line interface (CLI), shell script, scheduler, etc.