Using TCP Wrapper in CentOS 7, the following statements were made in hosts.allow to allow domain-specific ssh connections:
sshd:.dion.ne.jp
I decided to use AlmaLinux 8, but I looked up how to set it up in the same way, but I didn't know.I know that if the IP address is determined, it can be set with the --add-rich-rule of firewall-cmd...
Please let me know if anyone is an intellectual.Thank you for your cooperation.
add
I found out that using pam works, but it doesn't work even if I specify the domain name.
I wrote the following in access.conf, but I couldn't connect.
+:testuser:.vmobile.jp
Do I need any configuration to specify by domain name?
linux
I think you can do it with PAM, but you can also limit it with AllowUsers
on the sshd side.
(/etc/ssh/sshd_config)
UseDNS yes
AllowUsers testuser@*.vmobile.jp
However, the following conditions may be used to prevent impersonation.
"FQDN (HOST.vmobile.jp) obtained by reverse lookup of source IP address" => source IP address
© 2024 OneMinuteCode. All rights reserved.