CentOS/RHEL 7 allows nested configuration in " /etc/ssh/sshd_config ". The following is an example :
sudo nano /etc/ssh/sshd_config
Add the following line :
The following example demonstrates that the user “testuser” can be logged in from 10.0.0.1 only, and the rest of the listed users can login from any host. Note that you need to list all the users who can be allowed to login, which is the downside of not supporting nested configuration.
AllowUsers firstname.lastname@example.org root user1 user2