LoginSignup
1
1

More than 3 years have passed since last update.

Linux環境でhosts.allow , host.denyの設定

簡単にLinux環境でローカルで試験するために設定したので、メモのために残しておきます。

/etc/hosts.allow設定

私の環境はCent OS 8でリモートアクセスの許可を/etc/hosts.allowで設定します。
IPアドレスは192.168.3.〇〇/24で、一応私だけでなく他の同じネットワーク上の方も触れるように、しました。
設定は下記です。

sshd : 192.168.3.

/etc/hosts.deny設定

hosts.allowで設定した以外の全てのIPアドレスからのSSH接続を禁止します。

sshd : all

まとめ

少なくてすいません。
最近はLinuxも勉強中です。

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1