Contents

System/OS
2003.04.23 10:27

[linux] 아파치설치/설정(CGI부분)

조회 수 14572 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
# 아파치 환경 설정 파일의 편집
$ vi $APACHE_HOME/conf/http.conf


1. 펄의 실행(추가 작성)
   AddType application/x-httpd-cgi .pl 

2. 특정 디렉토리에서 gif화일을 사용하려면
   ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/" ->
   Alias /cgi-bin/ "/usr/local/apache/cgi-bin/"

3. 모든 디렉토리에서나 cgi의 실행
   AddHandler cgi-script .cgi .pl
   Options FollowSymLinks ExecCGI                                 # ExecCGI 의 추가
   ScriptAlias /* "/*" 
   <Directory /*>
      Options FollowSymLinks ExecCGI Includes                         # 또는 Options All 
      AllowOverride None                                         # 또는 AllowOverride All
      Order allow,deny                                                 
      Allow from all
   </Directory>

4. 특정 디렉토리에서만 cgi 실행(보안문제)1
   AddHandler cgi-script .cgi .pl
   <Directory "/usr/local/apache/htdocs">                        # 특정 디렉토리의 풀경로
      Options Indexes FollowSymLinks ExecCGI  
      AllowOverride None
      Order allow,deny
      Allow from all
   </Directory>

   특정 디렉토리에서만 cgi 실행(안정적)2                        # ScriptAlias를 이용
   ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/"
   <Directory "/usr/local/apache/cgi-bin">
       AllowOverride None
       Options None
       Order allow,deny
       Allow from all
   </Directory>
   사용법 http://toconet.co.kr/cgi-bin/test.cgi 


5. 사용자 홈페이지에서의 cgi 실행
   Addtype CGI 하면 되고요.. 
   /home/*/public_html 
   <Directory /home/*/public_html>
        Options Indexes FollowSymLinks Includes Exec<B><U>CGI</U></B> 
        AllowOverride All
        order allow,deny
        allow from all
   </Directory>


?

List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
82 System/OS [linux] 패킷의 소스 주소 바꾸기 hooni 2003.04.23 18799
81 System/OS [linux] 프로그램 설치방법 (내공쌓기) hooni 2003.04.23 13434
80 System/OS [linux] 프로세스 상태확인(ps) hooni 2003.04.23 12719
79 System/OS [linux] 프로세스의 stat 상태에 대한 설명 hooni 2013.04.23 10766
78 System/OS [linux] 한글 URL 인식할 수 있게 아파치(Apache) 설정 (mod_url.c 설치) hooni 2013.04.23 13072
77 System/OS [macos] How to Fix ‘You Shut Down Your Computer Because of a Problem’ file hooni 2022.06.01 809
76 System/OS [mac] Charlesproxy 간단한 설정 내용~ hooni 2013.11.12 12341
75 System/OS [mac] Homebrew/rvm/cocoapod setting hooni 2017.07.29 1016
74 System/OS [mac] How to uninstall MySQL on Mac OS. hooni 2017.11.08 902
73 System/OS [mac] Mac OS 패키지 매니저, HomeBrew file hooni 2015.01.03 1340
72 System/OS [mac] Mac OS에서 재생되는 사운드를 녹음하는 방법 file hooni 2016.10.03 1474
71 System/OS [mac] Mac에서 Mac으로 원격제어하기 (맥에서 맥으로) file hooni 2013.10.08 37020
Board Pagination Prev 1 ... 6 7 8 9 10 11 12 13 14 15 ... 17 Next
/ 17