diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 06:33:50 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 06:33:50 +0000 |
commit | fe39ffb8b90ae4e002ed73fe98617cd590abb467 (patch) | |
tree | b80e5956907d8aeaaffe4e4f0c068c0e6157ce8b /docs/manual/mod/mod_authnz_fcgi.html | |
parent | Initial commit. (diff) | |
download | apache2-upstream/2.4.56.tar.xz apache2-upstream/2.4.56.zip |
Adding upstream version 2.4.56.upstream/2.4.56upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | docs/manual/mod/mod_authnz_fcgi.html | 9 | ||||
-rw-r--r-- | docs/manual/mod/mod_authnz_fcgi.html.en | 566 | ||||
-rw-r--r-- | docs/manual/mod/mod_authnz_fcgi.html.fr.utf8 | 588 |
3 files changed, 1163 insertions, 0 deletions
diff --git a/docs/manual/mod/mod_authnz_fcgi.html b/docs/manual/mod/mod_authnz_fcgi.html new file mode 100644 index 0000000..a70ee70 --- /dev/null +++ b/docs/manual/mod/mod_authnz_fcgi.html @@ -0,0 +1,9 @@ +# GENERATED FROM XML -- DO NOT EDIT + +URI: mod_authnz_fcgi.html.en +Content-Language: en +Content-type: text/html; charset=UTF-8 + +URI: mod_authnz_fcgi.html.fr.utf8 +Content-Language: fr +Content-type: text/html; charset=UTF-8 diff --git a/docs/manual/mod/mod_authnz_fcgi.html.en b/docs/manual/mod/mod_authnz_fcgi.html.en new file mode 100644 index 0000000..de10c85 --- /dev/null +++ b/docs/manual/mod/mod_authnz_fcgi.html.en @@ -0,0 +1,566 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head> +<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /> +<!-- + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + This file is generated from xml source: DO NOT EDIT + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + --> +<title>mod_authnz_fcgi - Apache HTTP Server Version 2.4</title> +<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> +<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> +<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" /> +<script src="../style/scripts/prettify.min.js" type="text/javascript"> +</script> + +<link href="../images/favicon.ico" rel="shortcut icon" /></head> +<body> +<div id="page-header"> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p> +<p class="apache">Apache HTTP Server Version 2.4</p> +<img alt="" src="../images/feather.png" /></div> +<div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div> +<div id="path"> +<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP Server</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.4</a> > <a href="./">Modules</a></div> +<div id="page-content"> +<div id="preamble"><h1>Apache Module mod_authnz_fcgi</h1> +<div class="toplang"> +<p><span>Available Languages: </span><a href="../en/mod/mod_authnz_fcgi.html" title="English"> en </a> | +<a href="../fr/mod/mod_authnz_fcgi.html" hreflang="fr" rel="alternate" title="Français"> fr </a></p> +</div> +<table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Allows a FastCGI authorizer application to handle Apache +httpd authentication and authorization</td></tr> +<tr><th><a href="module-dict.html#Status">Status:</a></th><td>Extension</td></tr> +<tr><th><a href="module-dict.html#ModuleIdentifier">Module Identifier:</a></th><td>authnz_fcgi_module</td></tr> +<tr><th><a href="module-dict.html#SourceFile">Source File:</a></th><td>mod_authnz_fcgi.c</td></tr> +<tr><th><a href="module-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.4.10 and later</td></tr></table> +<h3>Summary</h3> + + <p>This module allows FastCGI authorizer applications to + authenticate users and authorize access to resources. It supports + generic FastCGI authorizers which participate in a single phase + for authentication and authorization as well as Apache httpd-specific + authenticators and authorizors which participate in one or both + phases.</p> + + <p>FastCGI authorizers can authenticate using user id and password, + such as for Basic authentication, or can authenticate using arbitrary + mechanisms.</p> +</div> +<div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><h3>Topics</h3> +<ul id="topics"> +<li><img alt="" src="../images/down.gif" /> <a href="#invocations">Invocation modes</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#examples">Additional examples</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#limitations">Limitations</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#logging">Logging</a></li> +</ul><h3 class="directives">Directives</h3> +<ul id="toc"> +<li><img alt="" src="../images/down.gif" /> <a href="#authnzfcgicheckauthnprovider">AuthnzFcgiCheckAuthnProvider</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#authnzfcgidefineprovider">AuthnzFcgiDefineProvider</a></li> +</ul> +<h3>Bugfix checklist</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">httpd changelog</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&list_id=144532&product=Apache%20httpd-2&query_format=specific&order=changeddate%20DESC%2Cpriority%2Cbug_severity&component=mod_authnz_fcgi">Known issues</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20httpd-2&component=mod_authnz_fcgi">Report a bug</a></li></ul><h3>See also</h3> +<ul class="seealso"> +<li><a href="../howto/auth.html">Authentication, Authorization, +and Access Control</a></li> +<li><code class="module"><a href="../mod/mod_auth_basic.html">mod_auth_basic</a></code></li> +<li><code class="program"><a href="../programs/fcgistarter.html">fcgistarter</a></code></li> +<li><code class="module"><a href="../mod/mod_proxy_fcgi.html">mod_proxy_fcgi</a></code></li> +<li><a href="#comments_section">Comments</a></li></ul></div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="invocations" id="invocations">Invocation modes</a></h2> + + <p>The invocation modes for FastCGI authorizers supported by this + module are distinguished by two characteristics, <em>type</em> and + auth <em>mechanism</em>.</p> + + <p><em>Type</em> is simply <code>authn</code> for authentication, + <code>authz</code> for authorization, or <code>authnz</code> for + combined authentication and authorization.</p> + + <p>Auth <em>mechanism</em> refers to the Apache httpd configuration + mechanisms and processing phases, and can be <code> + AuthBasicProvider</code>, <code>Require</code>, or <code> + check_user_id</code>. The first two of these + correspond to the directives used to enable participation in the + appropriate processing phase.</p> + + <p>Descriptions of each mode:</p> + + <dl> + <dt><em>Type</em> <code>authn</code>, <em>mechanism</em> + <code>AuthBasicProvider</code></dt> + + <dd>In this mode, + <code>FCGI_ROLE</code> is set to <code>AUTHORIZER</code> and + <code>FCGI_APACHE_ROLE</code> is set to <code>AUTHENTICATOR</code>. + The application must be defined as provider type <em>authn</em> + using <code class="directive"><a href="#authnzfcgidefineprovider"> + AuthnzFcgiDefineProvider</a></code> and enabled with + <code class="directive"><a href="../mod/mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></code>. + When invoked, the application is + expected to authenticate the client using the provided user id and + password. Example application: + +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'} ne "AUTHENTICATOR"; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + die if !$ENV{'REMOTE_PASSWD'}; + die if !$ENV{'REMOTE_USER'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ( ($ENV{'REMOTE_USER' } eq "foo" || $ENV{'REMOTE_USER'} eq "foo1") && + $ENV{'REMOTE_PASSWD'} eq "bar" ) { + print "Status: 200\n"; + print "Variable-AUTHN_1: authn_01\n"; + print "Variable-AUTHN_2: authn_02\n"; + print "\n"; + } + else { + print "Status: 401\n\n"; + } +}</pre> + + + Example configuration: +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authn FooAuthn fcgi://localhost:10102/ +<Location "/protected/"> + AuthType Basic + AuthName "Restricted" + AuthBasicProvider FooAuthn + Require ... +</Location></pre> + + </dd> + + <dt><em>Type</em> <code>authz</code>, <em>mechanism</em> + <code>Require</code></dt> + <dd>In this mode, <code>FCGI_ROLE</code> is set to <code> + AUTHORIZER</code> and <code>FCGI_APACHE_ROLE</code> is set to + <code>AUTHORIZER</code>. The application must be defined as + provider type <em>authz</em> using <code class="directive"><a href="#authnzfcgidefineprovider"> + AuthnzFcgiDefineProvider</a></code>. When invoked, the application + is expected to authorize the client using the provided user id and other + request data. Example application: +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'} ne "AUTHORIZER"; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + die if $ENV{'REMOTE_PASSWD'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ($ENV{'REMOTE_USER'} eq "foo1") { + print "Status: 200\n"; + print "Variable-AUTHZ_1: authz_01\n"; + print "Variable-AUTHZ_2: authz_02\n"; + print "\n"; + } + else { + print "Status: 403\n\n"; + } +}</pre> + + + Example configuration: +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authz FooAuthz fcgi://localhost:10103/ +<Location "/protected/"> + AuthType ... + AuthName ... + AuthBasicProvider ... + Require FooAuthz +</Location></pre> + + </dd> + + <dt><em>Type</em> <code>authnz</code>, <em>mechanism</em> + <code>AuthBasicProvider</code> <em>+</em> <code>Require</code></dt> + + <dd>In this mode, which supports the web server-agnostic FastCGI + <code>AUTHORIZER</code> protocol, <code>FCGI_ROLE</code> is set to + <code>AUTHORIZER</code> and <code>FCGI_APACHE_ROLE</code> is not set. + The application must be defined as provider type <em>authnz</em> + using <code class="directive"><a href="#authnzfcgidefineprovider"> + AuthnzFcgiDefineProvider</a></code>. The application is expected to + handle both authentication and authorization in the same invocation + using the user id, password, and other request data. The invocation + occurs during the Apache httpd API authentication phase. If the + application returns 200 and the same provider is invoked during the + authorization phase (via <code class="directive">Require</code>), mod_authnz_fcgi + will return success for the authorization phase without invoking the + application. Example application: +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'}; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + die if !$ENV{'REMOTE_PASSWD'}; + die if !$ENV{'REMOTE_USER'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ( ($ENV{'REMOTE_USER' } eq "foo" || $ENV{'REMOTE_USER'} eq "foo1") && + $ENV{'REMOTE_PASSWD'} eq "bar" && + $ENV{'REQUEST_URI'} =~ m%/bar/.*%) { + print "Status: 200\n"; + print "Variable-AUTHNZ_1: authnz_01\n"; + print "Variable-AUTHNZ_2: authnz_02\n"; + print "\n"; + } + else { + print "Status: 401\n\n"; + } +}</pre> + + + Example configuration: +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authnz FooAuthnz fcgi://localhost:10103/ +<Location "/protected/"> + AuthType Basic + AuthName "Restricted" + AuthBasicProvider FooAuthnz + Require FooAuthnz +</Location></pre> + + </dd> + + <dt><em>Type</em> <code>authn</code>, <em>mechanism</em> + <code>check_user_id</code></dt> + + <dd>In this mode, <code>FCGI_ROLE</code> is set to <code> + AUTHORIZER</code> and <code>FCGI_APACHE_ROLE</code> is set to + <code>AUTHENTICATOR</code>. The application must be defined as + provider type <em>authn</em> using <code class="directive"><a href="#authnzfcgidefineprovider"> + AuthnzFcgiDefineProvider</a></code>. <code class="directive"><a href="#authnzfcgicheckauthnprovider">AuthnzFcgiCheckAuthnProvider</a></code> + specifies when it is called. Example application: +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'} ne "AUTHENTICATOR"; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + + # This authorizer assumes that the RequireBasicAuth option of + # AuthnzFcgiCheckAuthnProvider is On: + die if !$ENV{'REMOTE_PASSWD'}; + die if !$ENV{'REMOTE_USER'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ( ($ENV{'REMOTE_USER' } eq "foo" || $ENV{'REMOTE_USER'} eq "foo1") && + $ENV{'REMOTE_PASSWD'} eq "bar" ) { + print "Status: 200\n"; + print "Variable-AUTHNZ_1: authnz_01\n"; + print "Variable-AUTHNZ_2: authnz_02\n"; + print "\n"; + } + else { + print "Status: 401\n\n"; + # If a response body is written here, it will be returned to + # the client. + } +}</pre> + + + Example configuration: +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authn FooAuthn fcgi://localhost:10103/ +<Location "/protected/"> + AuthType ... + AuthName ... + AuthnzFcgiCheckAuthnProvider FooAuthn \ + Authoritative On \ + RequireBasicAuth Off \ + UserExpr "%{reqenv:REMOTE_USER}" + Require ... +</Location></pre> + + </dd> + + </dl> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="examples" id="examples">Additional examples</a></h2> + + <ol> + <li>If your application supports the separate authentication and + authorization roles (<code>AUTHENTICATOR</code> and <code>AUTHORIZER</code>), define + separate providers as follows, even if they map to the same + application: + +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authn FooAuthn fcgi://localhost:10102/ +AuthnzFcgiDefineProvider authz FooAuthz fcgi://localhost:10102/</pre> + + + Specify the authn provider on + <code class="directive"><a href="../mod/mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></code> + and the authz provider on + <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>: + +<pre class="prettyprint lang-config">AuthType Basic +AuthName "Restricted" +AuthBasicProvider FooAuthn +Require FooAuthz</pre> + + </li> + + <li>If your application supports the generic <code>AUTHORIZER</code> role + (authentication and authorizer in one invocation), define a + single provider as follows: + +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authnz FooAuthnz fcgi://localhost:10103/</pre> + + + Specify the authnz provider on both <code class="directive">AuthBasicProvider</code> + and <code class="directive">Require</code>: + +<pre class="prettyprint lang-config">AuthType Basic +AuthName "Restricted" +AuthBasicProvider FooAuthnz +Require FooAuthnz</pre> + + </li> +</ol> +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="limitations" id="limitations">Limitations</a></h2> + + <p>The following are potential features which are not currently + implemented:</p> + + <dl> + <dt>Apache httpd access checker</dt> + <dd>The Apache httpd API <em>access check</em> phase is a separate + phase from authentication and authorization. Some other FastCGI + implementations implement this phase, which is denoted by the + setting of <code>FCGI_APACHE_ROLE</code> to <code>ACCESS_CHECKER</code>.</dd> + + <dt>Local (Unix) sockets or pipes</dt> + <dd>Only TCP sockets are currently supported.</dd> + + <dt>Support for mod_authn_socache</dt> + <dd>mod_authn_socache interaction should be implemented for + applications which participate in Apache httpd-style + authentication.</dd> + + <dt>Support for digest authentication using AuthDigestProvider</dt> + <dd>This is expected to be a permanent limitation as there is + no authorizer flow for retrieving a hash.</dd> + + <dt>Application process management</dt> + <dd>This is expected to be permanently out of scope for + this module. Application processes must be controlled by + other means. For example, <code class="program"><a href="../programs/fcgistarter.html">fcgistarter</a></code> can be used to + start them.</dd> + + <dt>AP_AUTH_INTERNAL_PER_URI</dt> + <dd>All providers are currently registered as + AP_AUTH_INTERNAL_PER_CONF, which means that checks are not + performed again for internal subrequests with the same + access control configuration as the initial request.</dd> + + <dt>Protocol data charset conversion</dt> + <dd>If mod_authnz_fcgi runs in an EBCDIC compilation + environment, all FastCGI protocol data is written in EBCDIC + and expected to be received in EBCDIC.</dd> + + <dt>Multiple requests per connection</dt> + <dd>Currently the connection to the FastCGI authorizer is + closed after every phase of processing. For example, if the + authorizer handles separate <em>authn</em> and <em>authz</em> + phases then two connections will be used.</dd> + + <dt>URI Mapping</dt> + <dd>URIs from clients can't be mapped, such as with the <code class="directive"> + ProxyPass</code> used with FastCGI responders.</dd> + + </dl> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="logging" id="logging">Logging</a></h2> + + <ol> + <li>Processing errors are logged at log level <code>error</code> + and higher.</li> + <li>Messages written by the application are logged at log + level <code>warn</code>.</li> + <li>General messages for debugging are logged at log level + <code>debug</code>.</li> + <li>Environment variables passed to the application are + logged at log level <code>trace2</code>. The value of the + <code>REMOTE_PASSWD</code> variable will be obscured, + but <strong>any other sensitive data will be visible in the + log</strong>.</li> + <li>All I/O between the module and the FastCGI application, + including all environment variables, will be logged in printable + and hex format at log level <code>trace5</code>. <strong>All + sensitive data will be visible in the log.</strong></li> + </ol> + + <p><code class="directive"><a href="../mod/core.html#loglevel">LogLevel</a></code> can be used + to configure a log level specific to mod_authnz_fcgi. For + example:</p> + +<pre class="prettyprint lang-config">LogLevel info authnz_fcgi:trace8</pre> + + +</div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="directive-section"><h2><a name="AuthnzFcgiCheckAuthnProvider" id="AuthnzFcgiCheckAuthnProvider">AuthnzFcgiCheckAuthnProvider</a> <a name="authnzfcgicheckauthnprovider" id="authnzfcgicheckauthnprovider">Directive</a></h2> +<table class="directive"> +<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables a FastCGI application to handle the check_authn +authentication hook.</td></tr> +<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AuthnzFcgiCheckAuthnProvider <em>provider-name</em>|<code>None</code> +<em>option</em> ...</code></td></tr> +<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>none</code></td></tr> +<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory</td></tr> +<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Extension</td></tr> +<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_authnz_fcgi</td></tr> +</table> + <p>This directive is used to enable a FastCGI authorizer to + handle a specific processing phase of authentication or + authorization.</p> + + <p>Some capabilities of FastCGI authorizers require enablement + using this directive instead of + <code class="directive">AuthBasicProvider</code>:</p> + + <ul> + <li>Non-Basic authentication; generally, determining the user + id of the client and returning it from the authorizer; see the + <code>UserExpr</code> option below</li> + <li>Selecting a custom response code; for a non-200 response + from the authorizer, the code from the authorizer will be the + status of the response</li> + <li>Setting the body of a non-200 response; if the authorizer + provides a response body with a non-200 response, that body + will be returned to the client; up to 8192 bytes of text are + supported</li> + </ul> + + <dl> + <dt><em>provider-name</em></dt> + <dd>This is the name of a provider defined with <code class="directive"> + AuthnzFcgiDefineProvider</code>.</dd> + + <dt><code>None</code></dt> + <dd>Specify <code>None</code> to disable a provider enabled + with this directive in an outer scope, such as in a parent + directory.</dd> + + <dt><em>option</em></dt> + <dd>The following options are supported: + + <dl> + <dt>Authoritative On|Off (default On)</dt> + <dd>This controls whether or not other modules are allowed + to run when this module has a FastCGI authorizer configured + and it fails the request.</dd> + + <dt>DefaultUser <em>userid</em></dt> + <dd>When the authorizer returns success and <code>UserExpr</code> + is configured and evaluates to an empty string (e.g., authorizer + didn't return a variable), this value will be used as the user + id. This is typically used when the authorizer has a concept of + guest, or unauthenticated, users and guest users are mapped to + some specific user id for logging and other purposes.</dd> + + <dt>RequireBasicAuth On|Off (default Off)</dt> + <dd>This controls whether or not Basic auth is required + before passing the request to the authorizer. If required, + the authorizer won't be invoked without a user id and + password; 401 will be returned for a request without that.</dd> + + <dt>UserExpr <em>expr</em> (no default)</dt> + <dd>When Basic authentication isn't provided by the client + and the authorizer determines the user, this expression, + evaluated after calling the authorizer, determines the + user. The expression follows <a href="../expr.html"> + ap_expr syntax</a> and must resolve to a string. A typical + use is to reference a <code>Variable-<em>XXX</em></code> + setting returned by the authorizer using an option like + <code>UserExpr "%{reqenv:<em>XXX</em>}"</code>. If + this option is specified and the user id can't be retrieved + using the expression after a successful authentication, the + request will be rejected with a 500 error.</dd> + + </dl> + </dd> + </dl> + +</div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="directive-section"><h2><a name="AuthnzFcgiDefineProvider" id="AuthnzFcgiDefineProvider">AuthnzFcgiDefineProvider</a> <a name="authnzfcgidefineprovider" id="authnzfcgidefineprovider">Directive</a></h2> +<table class="directive"> +<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Defines a FastCGI application as a provider for +authentication and/or authorization</td></tr> +<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AuthnzFcgiDefineProvider <em>type</em> <em>provider-name</em> +<em>backend-address</em></code></td></tr> +<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>none</code></td></tr> +<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr> +<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Extension</td></tr> +<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_authnz_fcgi</td></tr> +</table> + <p>This directive is used to define a FastCGI application as + a provider for a particular phase of authentication or + authorization.</p> + + <dl> + <dt><em>type</em></dt> + <dd>This must be set to <em>authn</em> for authentication, + <em>authz</em> for authorization, or <em>authnz</em> for + a generic FastCGI authorizer which performs both checks.</dd> + + <dt><em>provider-name</em></dt> + <dd>This is used to assign a name to the provider which is + used in other directives such as + <code class="directive"><a href="../mod/mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></code> + and + <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>.</dd> + + <dt><em>backend-address</em></dt> + <dd>This specifies the address of the application, in the form + <em>fcgi://hostname:port/</em>. The application process(es) + must be managed independently, such as with + <code class="program"><a href="../programs/fcgistarter.html">fcgistarter</a></code>.</dd> + </dl> + +</div> +</div> +<div class="bottomlang"> +<p><span>Available Languages: </span><a href="../en/mod/mod_authnz_fcgi.html" title="English"> en </a> | +<a href="../fr/mod/mod_authnz_fcgi.html" hreflang="fr" rel="alternate" title="Français"> fr </a></p> +</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Comments</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Libera.chat, or sent to our <a href="https://httpd.apache.org/lists.html">mailing lists</a>.</div> +<script type="text/javascript"><!--//--><![CDATA[//><!-- +var comments_shortname = 'httpd'; +var comments_identifier = 'http://httpd.apache.org/docs/2.4/mod/mod_authnz_fcgi.html'; +(function(w, d) { + if (w.location.hostname.toLowerCase() == "httpd.apache.org") { + d.write('<div id="comments_thread"><\/div>'); + var s = d.createElement('script'); + s.type = 'text/javascript'; + s.async = true; + s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; + (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); + } + else { + d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); + } +})(window, document); +//--><!]]></script></div><div id="footer"> +<p class="apache">Copyright 2023 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- +if (typeof(prettyPrint) !== 'undefined') { + prettyPrint(); +} +//--><!]]></script> +</body></html>
\ No newline at end of file diff --git a/docs/manual/mod/mod_authnz_fcgi.html.fr.utf8 b/docs/manual/mod/mod_authnz_fcgi.html.fr.utf8 new file mode 100644 index 0000000..640da43 --- /dev/null +++ b/docs/manual/mod/mod_authnz_fcgi.html.fr.utf8 @@ -0,0 +1,588 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" lang="fr" xml:lang="fr"><head> +<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /> +<!-- + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + This file is generated from xml source: DO NOT EDIT + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + --> +<title>mod_authnz_fcgi - Serveur HTTP Apache Version 2.4</title> +<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> +<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> +<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" /> +<script src="../style/scripts/prettify.min.js" type="text/javascript"> +</script> + +<link href="../images/favicon.ico" rel="shortcut icon" /></head> +<body> +<div id="page-header"> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossaire</a> | <a href="../sitemap.html">Plan du site</a></p> +<p class="apache">Serveur HTTP Apache Version 2.4</p> +<img alt="" src="../images/feather.png" /></div> +<div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div> +<div id="path"> +<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">Serveur HTTP</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.4</a> > <a href="./">Modules</a></div> +<div id="page-content"> +<div id="preamble"><h1>Module Apache mod_authnz_fcgi</h1> +<div class="toplang"> +<p><span>Langues Disponibles: </span><a href="../en/mod/mod_authnz_fcgi.html" hreflang="en" rel="alternate" title="English"> en </a> | +<a href="../fr/mod/mod_authnz_fcgi.html" title="Français"> fr </a></p> +</div> +<table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Permet à une application d'autorisation FastCGI de gérer +l'authentification et l'autorisation httpd.</td></tr> +<tr><th><a href="module-dict.html#Status">Statut:</a></th><td>Extension</td></tr> +<tr><th><a href="module-dict.html#ModuleIdentifier">Identificateur de Module:</a></th><td>authnz_fcgi_module</td></tr> +<tr><th><a href="module-dict.html#SourceFile">Fichier Source:</a></th><td>mod_authnz_fcgi.c</td></tr> +<tr><th><a href="module-dict.html#Compatibility">Compatibilité:</a></th><td>Disponible à partir de la version 2.4.10 du serveur HTTP +Apache</td></tr></table> +<h3>Sommaire</h3> + + <p>Ce module permet aux applications d'autorisation FastCGI + d'authentifier les utilisateurs et de contrôler leur accès aux + ressources. Il supporte les systèmes d'autorisation FastCGI + génériques qui participent en une seule phase à l'authentification + et à l'autorisation, ainsi que les processus d'authentification et + d'autorisation spécifiques à Apache httpd qui interviennent en une + ou plusieurs phases.</p> + + <p>Les processus d'autorisation FastCGI peuvent authentifier un + utilisateur via son identificateur et son mot de passe comme dans le + processus d'authentification basique, ou via un mécanisme + arbitraire.</p> +</div> +<div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><h3>Sujets</h3> +<ul id="topics"> +<li><img alt="" src="../images/down.gif" /> <a href="#invocations">Modes d'invocation</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#examples">Exemples supplémentaires</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#limitations">Limitations</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#logging">Journalisation</a></li> +</ul><h3 class="directives">Directives</h3> +<ul id="toc"> +<li><img alt="" src="../images/down.gif" /> <a href="#authnzfcgicheckauthnprovider">AuthnzFcgiCheckAuthnProvider</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#authnzfcgidefineprovider">AuthnzFcgiDefineProvider</a></li> +</ul> +<h3>Traitement des bugs</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">Journal des modifications de httpd</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&list_id=144532&product=Apache%20httpd-2&query_format=specific&order=changeddate%20DESC%2Cpriority%2Cbug_severity&component=mod_authnz_fcgi">Problèmes connus</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20httpd-2&component=mod_authnz_fcgi">Signaler un bug</a></li></ul><h3>Voir aussi</h3> +<ul class="seealso"> +<li><a href="../howto/auth.html">Authentification, autorisation et +contrôle d'accès</a></li> +<li><code class="module"><a href="../mod/mod_auth_basic.html">mod_auth_basic</a></code></li> +<li><code class="program"><a href="../programs/fcgistarter.html">fcgistarter</a></code></li> +<li><code class="module"><a href="../mod/mod_proxy_fcgi.html">mod_proxy_fcgi</a></code></li> +<li><a href="#comments_section">Commentaires</a></li></ul></div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="invocations" id="invocations">Modes d'invocation</a></h2> + + <p>Les modes d'invocation des processus d'autorisation FastCGI que + ce module supporte se distinguent par deux caractéristiques : le + <em>type</em> et le <em>mécanisme</em> d'authentification.</p> + + <p>Le <em>Type</em> est simplement <code>authn</code> pour + l'authentification, <code>authz</code> pour l'autorisation et + <code>authnz</code> l'authentification et l'autorisation.</p> + + <p>Le <em>mécanisme</em> d'authentification fait référence aux + mécanismes d'authentification et aux phases de traitement de la + configuration de Apache httpd, et peut être + <code>AuthBasicProvider</code>, <code>Require</code>, ou + <code>check_user_id</code>. Les deux premiers mécanismes + correspondent aux directives utilisées pour participer aux phases de + traitement appropriées.</p> + + <p>Description de chaque mode:</p> + + <dl> + <dt><em>Type</em> <code>authn</code>, <em>mechanism</em> + <code>AuthBasicProvider</code></dt> + + <dd>Dans ce mode, la variable <code>FCGI_ROLE</code> est définie à + <code>AUTHORIZER</code>, et la variable + <code>FCGI_APACHE_ROLE</code> à <code>AUTHENTICATOR</code>. + L'application doit être spécifiée en tant que fournisseur de type + <em>authn</em> via la directive <code class="directive"><a href="#authnzfcgidefineprovider">AuthnzFcgiDefineProvider</a></code>, et + activée via la directive <code class="directive"><a href="../mod/mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></code>. Lorsqu'elle + est invoquée, l'application est censée authentifier le client à + l'aide de l'identifiant et du mot de passe de l'utilisateur. + Exemple d'application : + +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'} ne "AUTHENTICATOR"; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + die if !$ENV{'REMOTE_PASSWD'}; + die if !$ENV{'REMOTE_USER'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ( ($ENV{'REMOTE_USER' } eq "foo" || $ENV{'REMOTE_USER'} eq "foo1") && + $ENV{'REMOTE_PASSWD'} eq "bar" ) { + print "Status: 200\n"; + print "Variable-AUTHN_1: authn_01\n"; + print "Variable-AUTHN_2: authn_02\n"; + print "\n"; + } + else { + print "Status: 401\n\n"; + } +}</pre> + + + Exemple de configuration httpd : +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authn FooAuthn fcgi://localhost:10102/ +<Location "/protected/"> + AuthType Basic + AuthName "Restricted" + AuthBasicProvider FooAuthn + Require ... +</Location></pre> + + </dd> + + <dt><em>Type</em> <code>authz</code>, <em>mechanism</em> + <code>Require</code></dt> + <dd>Dans ce mode, la variable <code>FCGI_ROLE</code> est définie à + <code>AUTHORIZER</code> et <code>FCGI_APACHE_ROLE</code> à + <code>AUTHORIZER</code>. L'application doit être spécifiée en tant + que fournisseur de type <em>authz</em> via la directive <code class="directive"><a href="#authnzfcgidefineprovider">AuthnzFcgiDefineProvider</a></code>. + Lorsqu'elle est invoquée, l'application est censée contrôler les + accès du client à l'aide de l'identifiant utilisateur et d'autres + données contenues dans la requête. Exemple d'application : +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'} ne "AUTHORIZER"; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + die if $ENV{'REMOTE_PASSWD'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ($ENV{'REMOTE_USER'} eq "foo1") { + print "Status: 200\n"; + print "Variable-AUTHZ_1: authz_01\n"; + print "Variable-AUTHZ_2: authz_02\n"; + print "\n"; + } + else { + print "Status: 403\n\n"; + } +}</pre> + + + Exemple de configuration httpd : +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authz FooAuthz fcgi://localhost:10103/ +<Location "/protected/"> + AuthType ... + AuthName ... + AuthBasicProvider ... + Require FooAuthz +</Location></pre> + + </dd> + + <dt><em>Type</em> <code>authnz</code>, <em>mechanism</em> + <code>AuthBasicProvider</code> <em>+</em> <code>Require</code></dt> + + <dd>Dans ce mode qui supporte le protocole d'autorisation web + server-agnostic FastCGI, la variable <code>FCGI_ROLE</code> est + définie à <code>AUTHORIZER</code> et <code>FCGI_APACHE_ROLE</code> + n'est pas définie. L'application doit être spécifiée en tant que + fournisseur de type <em>authnz</em> via la directive <code class="directive"><a href="#authnzfcgidefineprovider">AuthnzFcgiDefineProvider</a></code>. + L'application est censée assurer l'authentification et + l'autorisation au cours d'une même invocation à l'aide de + l'identifiant et du mot de passe de l'utilisateur et d'autres + données contenues dans la requête. L'invocation de l'application + intervient au cours de la phase d'authentification de l'API Apache + httpd. Si l'application renvoie le code 200, et si le même + fournisseur est invoqué au cours de la phase d'autorisation (via + une directive <code class="directive">Require</code>), mod_authnz_fcgi + renverra un code de type success pour la phase d'autorisation sans + invoquer l'application. Exemple d'application : +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'}; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + die if !$ENV{'REMOTE_PASSWD'}; + die if !$ENV{'REMOTE_USER'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ( ($ENV{'REMOTE_USER' } eq "foo" || $ENV{'REMOTE_USER'} eq "foo1") && + $ENV{'REMOTE_PASSWD'} eq "bar" && + $ENV{'REQUEST_URI'} =~ m%/bar/.*%) { + print "Status: 200\n"; + print "Variable-AUTHNZ_1: authnz_01\n"; + print "Variable-AUTHNZ_2: authnz_02\n"; + print "\n"; + } + else { + print "Status: 401\n\n"; + } +}</pre> + + + Exemple de configuration httpd : +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authnz FooAuthnz fcgi://localhost:10103/ +<Location "/protected/"> + AuthType Basic + AuthName "Restricted" + AuthBasicProvider FooAuthnz + Require FooAuthnz +</Location></pre> + + </dd> + + <dt><em>Type</em> <code>authn</code>, <em>mechanism</em> + <code>check_user_id</code></dt> + + <dd>Dans ce mode, la variable <code>FCGI_ROLE</code> est définie à + <code>AUTHORIZER</code> et <code>FCGI_APACHE_ROLE</code> à + <code>AUTHENTICATOR</code>. L'application doit être spécifiée en + tant que fournisseur de type <em>authn</em> via une directive + <code class="directive"><a href="#authnzfcgidefineprovider">AuthnzFcgiDefineProvider</a></code>. La + directive <code class="directive"><a href="#authnzfcgicheckauthnprovider">AuthnzFcgiCheckAuthnProvider</a></code> + permet de l'invoquer. Exemple d'application : +<pre class="prettyprint lang-perl">#!/usr/bin/perl +use FCGI; +my $request = FCGI::Request(); +while ($request->Accept() >= 0) { + die if $ENV{'FCGI_APACHE_ROLE'} ne "AUTHENTICATOR"; + die if $ENV{'FCGI_ROLE'} ne "AUTHORIZER"; + + # This authorizer assumes that the RequireBasicAuth option of + # AuthnzFcgiCheckAuthnProvider is On: + die if !$ENV{'REMOTE_PASSWD'}; + die if !$ENV{'REMOTE_USER'}; + + print STDERR "This text is written to the web server error log.\n"; + + if ( ($ENV{'REMOTE_USER' } eq "foo" || $ENV{'REMOTE_USER'} eq "foo1") && + $ENV{'REMOTE_PASSWD'} eq "bar" ) { + print "Status: 200\n"; + print "Variable-AUTHNZ_1: authnz_01\n"; + print "Variable-AUTHNZ_2: authnz_02\n"; + print "\n"; + } + else { + print "Status: 401\n\n"; + # If a response body is written here, it will be returned to + # the client. + } +}</pre> + + + Exemple de configuration httpd : +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authn FooAuthn fcgi://localhost:10103/ +<Location "/protected/"> + AuthType ... + AuthName ... + AuthnzFcgiCheckAuthnProvider FooAuthn \ + Authoritative On \ + RequireBasicAuth Off \ + UserExpr "%{reqenv:REMOTE_USER}" + Require ... +</Location></pre> + + </dd> + + </dl> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="examples" id="examples">Exemples supplémentaires</a></h2> + + <ol> + <li>Si votre application supporte séparément les rôles + d'authentification et d'autorisation (<code>AUTHENTICATOR</code> et + <code>AUTHORIZER</code>), vous pouvez définir des fournisseurs + séparés comme suit, même s'ils correspondent à la même application : + +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authn FooAuthn fcgi://localhost:10102/ +AuthnzFcgiDefineProvider authz FooAuthz fcgi://localhost:10102/</pre> + + + Spécifie le fournisseur authn via la directive + <code class="directive"><a href="../mod/mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></code> + et le fournisseur authz via la directive + <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>: + +<pre class="prettyprint lang-config">AuthType Basic +AuthName "Restricted" +AuthBasicProvider FooAuthn +Require FooAuthz</pre> + + </li> + + <li>Si votre application supporte le rôle générique + <code>AUTHORIZER</code> (authentification et autorisation en une + seule invocation), vous pouvez définir un fournisseur unique comme + suit : + +<pre class="prettyprint lang-config">AuthnzFcgiDefineProvider authnz FooAuthnz fcgi://localhost:10103/</pre> + + + Spécifie le fournisseur authnz via les directives + <code class="directive">AuthBasicProvider</code> et + <code class="directive">Require</code> : + +<pre class="prettyprint lang-config">AuthType Basic +AuthName "Restricted" +AuthBasicProvider FooAuthnz +Require FooAuthnz</pre> + + </li> +</ol> +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="limitations" id="limitations">Limitations</a></h2> + + <p>Les fonctionnalités suivantes ne sont pas encore implémentées :</p> + + <dl> + <dt>Vérificateur d'accès d'Apache httpd</dt> + <dd>La phase <em>access check</em> de l'API Apache httpd est + distincte des phases d'authentification et d'autorisation. + Certaines autres implémentations de FastCGI supportent cette phase + et lorsque c'est le cas, la variable <code>FCGI_APACHE_ROLE</code> + est définie à <code>ACCESS_CHECKER</code>.</dd> + + <dt>Redirections (pipes) ou sockets locaux (Unix)</dt> + <dd>Seuls les sockets TCP sont actuellement supportés.</dd> + + <dt>Support de mod_authn_socache</dt> + <dd>Le support de l'interaction avec mod_authn_socache pour les + applications qui interviennent dans le processus + d'authentification d'Apache httpd serait souhaitable.</dd> + + <dt>Support de l'authentification de type digest à l'aide de AuthDigestProvider</dt> + <dd>Cette limitation ne sera probablement jamais franchie car il + n'existe aucun flux de données d'autorisation capable de lire dans + un condensé de type hash.</dd> + + <dt>Gestion des processus applicatifs</dt> + <dd>Cette fonctionnalité restera probablement hors de portée de ce + module. Il faudra donc gérer les processus applicatifs d'une autre + manière ; par exemple, <code class="program"><a href="../programs/fcgistarter.html">fcgistarter</a></code> permet de + les démarrer.</dd> + + <dt>AP_AUTH_INTERNAL_PER_URI</dt> + <dd>Tous les fournisseurs sont actuellement enregistrés en tant + que AP_AUTH_INTERNAL_PER_CONF, ce qui signifie que les + vérifications ne sont pas effectuées pour les + sous-requêtes internes avec la même configuration de contrôle + d'accès que la requête initiale.</dd> + + <dt>Conversion du jeu de caractères des données de protocole</dt> + <dd>Si mod_authnz_fcgi s'exécute dans un environnement de + compilation EBCDIC, toutes les données de protocole FastCGI sont + écrites en EBCDIC et doivent être disponibles en EBCDIC.</dd> + + <dt>Plusieurs requêtes pour une connexion</dt> + <dd>Actuellement, la connexion au fournisseur d'autorisation + FastCGI est fermée après chaque phase de traitement. Par exemple, + si le fournisseur d'autorisation gère séparément les phases + <em>authn</em> et <em>authz</em>, deux connexions seront + nécessaires.</dd> + + <dt>Redirection de certains URIs</dt> + <dd>Les URIs en provenance des clients ne peuvent pas être + redirigés selon une table de redirection, comme avec la directive + <code class="directive">ProxyPass</code> utilisée avec les répondeurs + FastCGI.</dd> + + </dl> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="logging" id="logging">Journalisation</a></h2> + + <ol> + <li>Les erreurs de traitement sont journalisées à un niveau + <code>error</code> ou supérieur.</li> + <li>Les messages envoyés par l'application sont journalisés au + niveau <code>warn</code>.</li> + <li>Les messages de deboguage à caractère général sont + journalisés au niveau <code>debug</code>.</li> + <li>Les variables d'environnement transmises à l'application + sont journalisées au niveau <code>trace2</code>. La valeur de la + variable <code>REMOTE_PASSWD</code> sera occultée, mais + <strong>toute autre donnée sensible sera visible dans le + journal</strong>.</li> + <li>Toutes les entrées/sorties entre le module et l'application + FastCGI, y compris les variables d'environnement, seront + journalisées au format imprimable et hexadécimal au niveau + <code>trace5</code>. <strong>Toutes les données sensibles seront + visibles dans le journal.</strong></li> + </ol> + + <p>La directive <code class="directive"><a href="../mod/core.html#loglevel">LogLevel</a></code> permet + de configurer un niveau de journalisation spécifique à + mod_authnz_fcgi. Par exemple :</p> + +<pre class="prettyprint lang-config">LogLevel info authnz_fcgi:trace8</pre> + + +</div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="directive-section"><h2><a name="authnzfcgicheckauthnprovider" id="authnzfcgicheckauthnprovider">Directive</a> <a name="AuthnzFcgiCheckAuthnProvider" id="AuthnzFcgiCheckAuthnProvider">AuthnzFcgiCheckAuthnProvider</a></h2> +<table class="directive"> +<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Permet à une application FastCGI de gérer l'accroche +d'authentification check_authn.</td></tr> +<tr><th><a href="directive-dict.html#Syntax">Syntaxe:</a></th><td><code>AuthnzFcgiCheckAuthnProvider <em>provider-name</em>|<code>None</code> +<em>option</em> ...</code></td></tr> +<tr><th><a href="directive-dict.html#Default">Défaut:</a></th><td><code>none</code></td></tr> +<tr><th><a href="directive-dict.html#Context">Contexte:</a></th><td>répertoire</td></tr> +<tr><th><a href="directive-dict.html#Status">Statut:</a></th><td>Extension</td></tr> +<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_authnz_fcgi</td></tr> +</table> + <p>Cette directive permet de confier à une application FastCGI la + gestion d'une phase spécifique du processus d'authentification ou + d'autorisation.</p> + + <p>Certaines fonctionnalités des fournisseurs d'autorisation FastCGI + nécessitent cette directive en lieu et place de + <code class="directive">AuthBasicProvider</code> pour pouvoir être activées :</p> + + <ul> + <li>L'authentification de type autre que basique ; en général, + détermination de l'identifiant utilisateur et renvoi de sa valeur + depuis le fournisseur d'autorisation ; voir l'option + <code>UserExpr</code> ci-dessous</li> + <li>Sélection d'un code de réponse personnalisé ; en cas de + code de réponse autre que 200 en provenance du fournisseur + d'autorisation, c'est ce code qui sera utilisé comme code d'état + de la réponse</li> + <li>Définition du corps d'une réponse autre que 200 ; si le + fournisseur d'autorisation renvoie un corps de réponse avec un + code autre que 200, c'est ce corps de réponse qui sera renvoyé au + client ; la longueur du texte est limitée à 8192 octets</li> + </ul> + + <dl> + <dt><em>provider-name</em></dt> + <dd>C'est le nom du fournisseur défini au préalable via la + directive <code class="directive">AuthnzFcgiDefineProvider</code>.</dd> + + <dt><code>None</code></dt> + <dd>Spécifiez <code>None</code> pour désactiver un fournisseur + activé avec cette même directive dans une autre portée, par + exemple dans un répertoire parent.</dd> + + <dt><em>option</em></dt> + <dd>Les options suivantes sont supportées : + + <dl> + <dt>Authoritative On|Off (par défaut On)</dt> + <dd>Cette option permet de définir si l'appel à d'autres + modules est autorisé lorsqu'un fournisseur d'autorisation FastCGI a + été configuré et si la requête échoue.</dd> + + <dt>DefaultUser <em>id utilisateur</em></dt> + <dd>Lorsque le fournisseur d'autorisation donne son accord, et + si <code>UserExpr</code> est défini et correspond à une chaîne + vide, (par exemple, si le fournisseur d'autorisation ne renvoie + aucune variable), c'est cette valeur qui sera utilisée comme id + utilisateur par défaut. Cela se produit souvent lorsqu'on se trouve dans + un contexte d'invité, ou d'utilisateur non authentifié ; + les utilisateurs et invités se voient alors attribué un id + utilisateur spécifique qui permettra de se connecter et + d'accéder à certaines ressources.</dd> + + <dt>RequireBasicAuth On|Off (par défaut Off)</dt> + <dd>Cette option permet de définir si l'authentification + basique est requise avant de transmettre la requête au + fournisseur d'autorisation. Dans l'affirmative, le fournisseur + d'autorisation ne sera invoqué qu'en présence d'un id + utilisateur et d'un mot de passe ; si ces deux éléments ne sont + pas présents, un code d'erreur 401 sera renvoyé</dd> + + <dt>UserExpr <em>expr</em> (pas de valeur par défaut)</dt> + <dd>Lorsque le client ne fournit pas l'authentification basique + et si le fournisseur d'autorisation détermine l'id utilisateur, + cette expression, évaluée après l'appel au fournisseur + d'autorisation, permet de déterminer l'id utilisateur. Cette + expression se conforme à la <a href="../expr.html">syntaxe + ap_expr</a> et doit correspondre à une chaîne de caractères. + Une utilisation courante consiste à référencer la définition + d'une <code>Variable-<em>XXX</em></code> renvoyée par le + fournisseur d'autorisation via une option du style + <code>UserExpr "%{reqenv:<em>XXX</em>}"</code>. Si cette option + est spécifiée, et si l'id utilisateur ne peut pas être définie + via l'expression après une authentification réussie, la requête + sera rejetée avec un code d'erreur 500.</dd> + + </dl> + </dd> + </dl> + +</div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="directive-section"><h2><a name="authnzfcgidefineprovider" id="authnzfcgidefineprovider">Directive</a> <a name="AuthnzFcgiDefineProvider" id="AuthnzFcgiDefineProvider">AuthnzFcgiDefineProvider</a></h2> +<table class="directive"> +<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Définit une application FastCGI en tant que fournisseur +d'authentification et/ou autorisation</td></tr> +<tr><th><a href="directive-dict.html#Syntax">Syntaxe:</a></th><td><code>AuthnzFcgiDefineProvider <em>type</em> <em>provider-name</em> +<em>backend-address</em></code></td></tr> +<tr><th><a href="directive-dict.html#Default">Défaut:</a></th><td><code>none</code></td></tr> +<tr><th><a href="directive-dict.html#Context">Contexte:</a></th><td>configuration globale</td></tr> +<tr><th><a href="directive-dict.html#Status">Statut:</a></th><td>Extension</td></tr> +<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_authnz_fcgi</td></tr> +</table> + <p>Cette directive permet de définir une application FastCGI en tant + que fournisseur pour une phase particulière d'authentification ou + d'autorisation.</p> + + <dl> + <dt><em>type</em></dt> + <dd>Les valeurs de ce paramètre sont <em>authn</em> pour + l'authentification, <em>authz</em> pour l'autorisation, ou + <em>authnz</em> pour un fournisseur d'autorisation générique + FastCGI qui effectue les deux vérifications.</dd> + + <dt><em>provider-name</em></dt> + <dd>Ce paramètre permet d'associer un nom au fournisseur ; ce nom + pourra être utilisé dans des directives comme <code class="directive"><a href="../mod/mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></code> et + <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>.</dd> + + <dt><em>backend-address</em></dt> + <dd>Ce paramètre permet de spécifier l'adresse de l'application + sous la forme <em>fcgi://hostname:port/</em>. Le ou les processus + de l'application doivent être gérés indépendamment comme avec + <code class="program"><a href="../programs/fcgistarter.html">fcgistarter</a></code>.</dd> + </dl> + +</div> +</div> +<div class="bottomlang"> +<p><span>Langues Disponibles: </span><a href="../en/mod/mod_authnz_fcgi.html" hreflang="en" rel="alternate" title="English"> en </a> | +<a href="../fr/mod/mod_authnz_fcgi.html" title="Français"> fr </a></p> +</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Commentaires</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Libera.chat, or sent to our <a href="https://httpd.apache.org/lists.html">mailing lists</a>.</div> +<script type="text/javascript"><!--//--><![CDATA[//><!-- +var comments_shortname = 'httpd'; +var comments_identifier = 'http://httpd.apache.org/docs/2.4/mod/mod_authnz_fcgi.html'; +(function(w, d) { + if (w.location.hostname.toLowerCase() == "httpd.apache.org") { + d.write('<div id="comments_thread"><\/div>'); + var s = d.createElement('script'); + s.type = 'text/javascript'; + s.async = true; + s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; + (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); + } + else { + d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); + } +})(window, document); +//--><!]]></script></div><div id="footer"> +<p class="apache">Copyright 2023 The Apache Software Foundation.<br />Autorisé sous <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossaire</a> | <a href="../sitemap.html">Plan du site</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- +if (typeof(prettyPrint) !== 'undefined') { + prettyPrint(); +} +//--><!]]></script> +</body></html>
\ No newline at end of file |