본문 바로가기
Apache

Apache Rerverse Proxy를 통한 Request 포워딩

by 꽃도련 2022. 9. 20.

Apache reverse proxy 모듈을 통하여 web request를 특정 ip 또는 url로 포워딩할 수 있다.

 

SSLProxyEngine on
SSLProxyVerify none
SSLProxyCheckPeerName off
ProxyPreserveHost off
ProxyRequests off


ProxyPass /test https://testapi.co.kr/test  
ReverseProxyPass /test https://testapi.co.kr/test

 

ProxyPreserveHost  Host 헤더를 현재 사용자가 요청한 서버 Host로 설정(on/off)
ProxyRequests  프록시 요청 포워드 설정(on:정방향 프록시 / off:역방향 프록시)
SSLProxyCheckPeerName
(Apache 2.4.4 이하 버전은 SSLProxyCheckCN)
원격 서버 인증서의 CN필드 확인 여부(on/off)

 

내부망에서 외부URL로 접근하기 위한 Relay 서버 구성시 유용하게 사용 가능

 

 

 

* mod_proxy

  - https://httpd.apache.org/docs/2.4/mod/mod_proxy.html

 

mod_proxy - Apache HTTP Server Version 2.4

Apache Module mod_proxy Summary Warning Do not enable proxying with ProxyRequests until you have secured your server. Open proxy servers are dangerous both to your network and to the Internet at large. mod_proxy and related modules implement a proxy/gatewa

httpd.apache.org

 

* mod_ssl

  - https://httpd.apache.org/docs/2.4/mod/mod_ssl.html

 

mod_ssl - Apache HTTP Server Version 2.4

Apache Module mod_ssl Summary This module provides SSL v3 and TLS v1.x support for the Apache HTTP Server. SSL v2 is no longer supported. This module relies on OpenSSL to provide the cryptography engine. Further details, discussion, and examples are provid

httpd.apache.org

 

* 정방향 프록시와 역방향 프록시가 잘 설명된 사이트

  - https://sujinhope.github.io/2021/06/13/Network-%ED%94%84%EB%A1%9D%EC%8B%9C(Proxy)%EB%9E%80,-Forward-Proxy%EC%99%80-Reverse-Proxy.html 

 

[network] 프록시(proxy)란, forward proxy와 reverse proxy - Break Out of Your Comfort Zone

목차 프록시(Proxy)란? 포워드 프록시(Forward Proxy) 리버스 프록시(Reverse Proxy) 면접은 시원하게 망했지만…. ​(​눈물나네 ) 면접 준비를 하면서 정리했던 내용들을 차례차례 정리해서 올려보려고

sujinhope.github.io

 

'Apache' 카테고리의 다른 글

Apache Location 설정 시 주의점  (0) 2022.11.09