[mod_python] Documentation error: request.user not read-only

Bud P. Bruegger bud at comune.grosseto.it
Thu Feb 16 09:49:55 EST 2006


Hi Grisha,

just looked at the latest doc 
http://www.modpython.org/live/mod_python-3.2.7/doc-html/pyapi-mprequest-mem.html 
and it seems that req.user is still stated to be read-only.  (See also your 
response below).

best cheers
-b

At 14.54 21/04/2005 -0400, Gregory (Grisha) Trubetskoy wrote:

>That's a documentation error. req.user has been writable for quite a while 
>now.
>
>Grisha
>
>On Thu, 21 Apr 2005, Bud P. Bruegger wrote:
>
>>Hello,
>>
>>I would like to write a simple handler that sets the REMOTE_USER 
>>cgi-variable.  The incentive of this is that no matter how the user 
>>authenticates (with HTTP BASIC or with SSL client-cert-auth and 
>>+fakeBasicAuth), I would like to present the same person ID to the (cgi) 
>>application.  In particular, I would like to set REMOTE_USER to the 
>>national unique person identifier (similar to a U.S. social security 
>>number).  For example, the handler should take the HTTP BASIC user name 
>>or Distinguished Name returned by mod_ssl, use it to look up the national 
>>person ID, and then assign it to REMOTE_USER.
>>
>>My problem is that the Request Member "user" documented to be read-only. 
>>Does this mean that I have to intervene some time after the 
>>authentication phase and before the request is passed off to the cgi 
>>application?  Should I maybe act on req.subprocess_env in the Fixup handler?
>>Maybe it is relevant that in a simple test with Apache 1.3, a SetEnv 
>>REMOTE_USER <someLiteral> worked and was visible from the CGI App.
>>
>>Many thanks in advance for any help
>>-b
>>
>>
>>-------------------------------------------------------------------------------------------------
>>Ing. Bud P. Bruegger, Ph.D.                 +39-0564-488577 
>>(voice),  -21139 (fax)
>>Servizio Elaborazione Dati                    e-mail:  bud at comune.grosseto.it
>>Comune di Grosseto http://www.comune.grosseto.it/cie/
>>Via Ginori, 43 http://OpenPortalGuard.sf.net
>>58100 Grosseto (Tuscany, Italy)           jabber:  bud at amessage.info
>>
>>Free Software in Public Administration:  not just a good idea, but a 
>>necessity
>>
>>Perfection is attained, not when there is nothing more to be added, but 
>>when there is nothing more to be taken away -- Antoine de Saint-Exupery 
>>_______________________________________________
>>Mod_python mailing list
>>Mod_python at modpython.org
>>http://mailman.modpython.org/mailman/listinfo/mod_python
>
>
>-------------------------------------------------------------------------------------------------
>Ing. Bud P. Bruegger, Ph.D.                 +39-0564-488577 
>(voice),  -21139 (fax)
>Servizio Elaborazione Dati                    e-mail:  bud at comune.grosseto.it
>Comune di Grosseto                            jabber:  bud at jabber.no
>Via Ginori, 
>43                                      http://www.comune.grosseto.it/cie/
>58100 Grosseto (Tuscany, 
>Italy)           http://www.comune.grosseto.it/interopEID/ 



More information about the Mod_python mailing list