You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Hadmut Danisch <ha...@danisch.de> on 2007/02/22 22:02:43 UTC

Accessing SSL environment variables?

Hi,

another problem with porting an older authentication script:

The script used to fetch the certificate details set from the SSL module 
under Apache1.3 with some code like

  $r->subprocess_env;   # initialize
  $envs   = $r->subprocess_env;
  $dn     = $r->subprocess_env('SSL_CLIENT_DN');
  $cn     = $r->subprocess_env('SSL_CLIENT_CN');


it worked. 

Now, under Apache2.2, I can access only a few variables like HTTP_... or
SERVER_... variables, but not the varialbes set from the SSL module. 

(The SSL option StdEnvVars is set, the variables can be seen from PHP
programs.)

regards
Hadmut

Re: Accessing SSL environment variables?

Posted by Hadmut Danisch <ha...@danisch.de>.
On Thu, Feb 22, 2007 at 04:26:44PM -0500, Geoffrey Young wrote:
> see
> 
>   http://search.cpan.org/dist/Apache-SSLLookup/
> 


Thanks for that hint. 

Shouldn't this be part of the mainstream apache perl module?


regards
Hadmut

Re: Accessing SSL environment variables?

Posted by Geoffrey Young <ge...@modperlcookbook.org>.
Hadmut Danisch wrote:
> Hi,
> 
> another problem with porting an older authentication script:
> 
> The script used to fetch the certificate details set from the SSL module 
> under Apache1.3 with some code like
> 
>   $r->subprocess_env;   # initialize
>   $envs   = $r->subprocess_env;
>   $dn     = $r->subprocess_env('SSL_CLIENT_DN');
>   $cn     = $r->subprocess_env('SSL_CLIENT_CN');
> 
> 
> it worked. 
> 
> Now, under Apache2.2, I can access only a few variables like HTTP_... or
> SERVER_... variables, but not the varialbes set from the SSL module. 
> 
> (The SSL option StdEnvVars is set, the variables can be seen from PHP
> programs.)

see

  http://search.cpan.org/dist/Apache-SSLLookup/

HTH

--Geoff