apache의 CGI에서 ping 실행시 permitssion denied 해결 방법좀 알려주세요
글쓴이: yunsog / 작성시간: 월, 2011/04/04 - 12:31오전
apache에서 CGI로 perl을 사용하는데, ping이 수행되지 않습니다.
perl 소스엣 아래 라인이 들어가면... (cgi 스크립트)
system("ping -c 10 $ip");
아래와 같은 에러메시지가 /var/log/httpd/error_log 에 저장됩니다.
[Sun Apr 03 22:25:58 2011] [error] [client xxx.xxx.xxx.xxx] ping: icmp opPermission denied, ......
OS는 CentOS이고....
SeLinux가 활성화되어 있고
[root]# getsebool -a | grep network
fenced_can_network_connect --> off
httpd_can_network_connect --> on
httpd_can_network_connect_db --> off
httpd_can_network_relay --> off
qemu_full_network --> on
rgmanager_can_network_connect --> off
spamassassin_can_network --> off
apache가 아닌 일반 유저의 경우 command 상태에서 ping 사용 가능합니다.
몇 시간 동안 인터넷 서치로 방법을 찾지 못해 질문 올립니다.
Forums:
댓글 달기