web service hardening 웹 서버(Web Server) 보안 Current: 관리자 서비스등 중요 URI 접근 제한 관리자 서비스등 중요 URI 접근 제한 웹 애플리케이션에서 설정할수도 있지만 웹 서버에서도 관리자 영역등 특정 패턴의 url 을 차단할 수 있습니다.다음은 아파치 웹서버에서 톰캣의 관리자 context 인 /manager 에 127.0.0.1과 192.168.0.0 대역을 제외하고는 접근을 차단하는 예제입니다.http 2.4 <Location /manager> Require host 127.0.0.1 192.168.0.0/24 </Location> CODE 또는 SetEnv 를 사용해서 다음과 같이 설정할 수 있습니다. SetEnvIF X-Forwarded-For "127.0.0.1" AllowIP SetEnvIF X-Forwarded-For "^192\.168\.10" AllowIP <Location /manager> Require env AllowIP </Location> CODE apache httpd 2.2 설정 <Location /manager> Order deny,allow Deny from all Allow from 127.0.0.1 192.168.0.0/24 </Location> CODE nginxnginx 는 allow 와 deny 키워드로 설정할 수 있으며 여러 개를 allow 할 경우 줄을 바꿔서 써주면 됩니다. location /manager { satisfy any; allow 127.0.0.1; allow 192.168.0.0/24; deny all; } CODE Refapache ServerTokens Directivenginx RESTRICTING ACCESSNginx Server Configs - nginx 설정 모음Apache Server Configs - apache httpd 설정 모음htaccess - apache .htaccess Snippets « 중요 파일 접근 차단 UTF-8 charset 사용 » ×