I'm working on a server access project and I want to implement Time-Based One-Time Passwords (TOTP) in my bash script for user authentication. Currently, I'm using a Telegram bot to share SSH keys, but I want to enhance security by replacing this method with TOTP. Is there an API provided by Google for this, or are there any other tools I can use? Specifically, I need to know how to generate an OTP and incorporate it into my bash script so that I can send it via Telegram for user access. Any advice would be greatly appreciated!
2 Answers
While TOTP can add a layer of security, you should remember that sharing only the public half of SSH keys is the usual practice for server access. Relying solely on Telegram might introduce risks due to the lack of end-to-end encryption. But if you're looking to enhance security with TOTP for users, this could be a valuable addition!
It sounds like a good idea to use TOTP for enhanced security! Google Authenticator can be integrated with SSH, and there are many tutorials available for that. You might want to check out some guides on setting up Google Authenticator with SSHD. This approach will help you manage time-sensitive OTPs securely when users try to log in.

Related Questions
How To: Running Codex CLI on Windows with Azure OpenAI
Set Wordpress Featured Image Using Javascript
How To Fix PHP Random Being The Same
Why no WebP Support with Wordpress
Replace Wordpress Cron With Linux Cron
Customize Yoast Canonical URL Programmatically