---
title: "Mahesh Vaidya (@forvaidya) | Hashnode"
description: "Devops. Read the latest articles by Mahesh Vaidya on Hashnode."
url: "https://hashnode.com/@forvaidya"
---

@forvaidya

# Mahesh Vaidya

@forvaidya · Joined July 2016

Devops

## Comments

[A weakness of SSH is SSH private key never expire. We can use AuthorizedKeysCommand We can also alter ~/.authorized\_keys content based on some key store. In AMI we need to configure AuthorizedKeysCommand which will run every time before public key is compared in ~/.authorized\_keys and recreate ~/.authorized\_keys based on user uploaded keys or admin deleted keys. this github project have implementation https://github.com/widdix/aws-ec2-ssh](https://hashnode.com/posts/users-and-ssh-setup-on-aws-ec2-best-practices/594e7399dab431e2eda595dd/comment/594ea4e107008bbf7ffdd4a5)

Comment · Article · Jun 24, 2017 · 1 · [Users and SSH setup on AWS EC2 - Best Practices](https://hashnode.com/posts/users-and-ssh-setup-on-aws-ec2-best-practices/594e7399dab431e2eda595dd)
