맛집 여행 캠핑 일상 생활

보안설정 hosts 및 sshd_config 본문

LAMP

보안설정 hosts 및 sshd_config

영은파더♥ 2016. 1. 25. 10:19

● hosts.deny 와 hosts.allow 설정


/etc/hosts.deny 파일에 아래를 추가

ALL:ALL


/etc/hosts.allow 파일에 접근을 허용할 IP를 추가

ALL:127.0.0.1

ALL:접근허용IP1 접근허용IP2 ...


chmod 640 /etc/hosts.deny

chmod 640 /etc/hosts.allow



● root 계정 ssh 접근 막기


/etc/ssh/sshd_config 파일에서 아래 부분을 찾아서 수정


#PermitRootLogin yes

PermitRootLogin no



'LAMP' 카테고리의 다른 글

Too many open files 에러메시지 대응방법  (0) 2016.01.25
vsftpd 설치 및 설정  (0) 2016.01.25
아파치 초기 설정  (0) 2016.01.25
CentOS 6.x 설치 후 기본적인 rpm 설치  (0) 2016.01.25
MySQL 데이터 압축 백업 및 복구  (0) 2016.01.22
Trackback : | Comments :