82 lines
3.1 KiB
HTML
82 lines
3.1 KiB
HTML
![]() |
|
||
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
||
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
|
||
|
lang="en" dir="ltr">
|
||
|
|
||
|
<head>
|
||
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||
|
<title></title>
|
||
|
<!-- metadata -->
|
||
|
<meta name="generator" content="Offline" />
|
||
|
<meta name="version" content="Offline 0.1" />
|
||
|
<!-- style sheet links -->
|
||
|
<link rel="stylesheet" media="all" type="text/css" href="../../../css/all.css" />
|
||
|
<link rel="stylesheet" media="screen" type="text/css" href="../../../css/screen.css" />
|
||
|
<link rel="stylesheet" media="print" type="text/css" href="../../../css/print.css" />
|
||
|
|
||
|
</head>
|
||
|
<body>
|
||
|
<div class="dokuwiki export">
|
||
|
|
||
|
|
||
|
<h1 class="sectionedit1" id="internal_proxy">Internal Proxy</h1>
|
||
|
<div class="level1">
|
||
|
|
||
|
</div>
|
||
|
<!-- EDIT1 SECTION "Internal Proxy" [1-30] -->
|
||
|
<h2 class="sectionedit2" id="presentation">Presentation</h2>
|
||
|
<div class="level2">
|
||
|
|
||
|
<p>
|
||
|
LemonLDAP::NG provides a proxy that can replace the use of Apache mod_proxy. This proxy use LWP Perl module to relay HTTP request. It can inspect HTTP headers to replace on the fly the Location and Set-Cookie headers.
|
||
|
</p>
|
||
|
|
||
|
<p>
|
||
|
Main differences with mod_proxy:
|
||
|
</p>
|
||
|
<ul>
|
||
|
<li class="level1"><div class="li"> The whole Location value is replaced, including the scheme (http or https), which can help to manage redirections below SSL hardware equipments</div>
|
||
|
</li>
|
||
|
<li class="level1"><div class="li"> It is compliant with the <a href="../../documentation/2.0/formreplay.html" class="wikilink1" title="documentation:2.0:formreplay">form replay</a> feature</div>
|
||
|
</li>
|
||
|
</ul>
|
||
|
|
||
|
</div>
|
||
|
<!-- EDIT2 SECTION "Presentation" [31-521] -->
|
||
|
<h2 class="sectionedit3" id="configuration">Configuration</h2>
|
||
|
<div class="level2">
|
||
|
|
||
|
<p>
|
||
|
The configuration is done in Apache, in a virtual host.
|
||
|
</p>
|
||
|
|
||
|
<p>
|
||
|
For example, to proxy <a href="https://www.public.com" class="urlextern" title="https://www.public.com" rel="nofollow">https://www.public.com</a> to <a href="http://www.private.com" class="urlextern" title="http://www.private.com" rel="nofollow">http://www.private.com</a>:
|
||
|
</p>
|
||
|
<pre class="code file apache"><<span class="kw3">VirtualHost</span>>
|
||
|
<span class="kw1">ServerName</span> www.public.com
|
||
|
|
||
|
PerlModule Lemonldap::NG::Handler::Proxy
|
||
|
<span class="kw1">SetHandler</span> perl-<span class="kw1">script</span>
|
||
|
PerlHandler Lemonldap::NG::Handler::Proxy
|
||
|
|
||
|
PerlSetVar LmProxyPass http://www.private.com/
|
||
|
PerlSetVar LmLocationToReplace http://www.private.com/,https://www.public.com
|
||
|
PerlSetVar LmCookieDomainToReplace private.com,public.com
|
||
|
</<span class="kw3">VirtualHost</span>></pre>
|
||
|
|
||
|
<p>
|
||
|
Parameters:
|
||
|
</p>
|
||
|
<ul>
|
||
|
<li class="level1"><div class="li"> <strong>LmProxyPass</strong>: <abbr title="Uniform Resource Locator">URL</abbr> to relay HTTP requests</div>
|
||
|
</li>
|
||
|
<li class="level1"><div class="li"> <strong>LmLocationToReplace</strong>: string to replace in <code>Location</code> header</div>
|
||
|
</li>
|
||
|
<li class="level1"><div class="li"> <strong>LmCookieDomainToReplace</strong>: string to replace in <code>Set-Cookie</code> header</div>
|
||
|
</li>
|
||
|
</ul>
|
||
|
|
||
|
</div>
|
||
|
</div><!-- closes <div class="dokuwiki export">-->
|