Yes CAS CAS authentication is done via a webform, it is working fine.

I already started coding what we discussed, but came up with this error, I
am using Apache 2.2 with mod_perl2.0

In the log it says that  Global $r object is not available. 

My perl auth handler looks as follows

sub authen_handler  {
        my $self= shift;
        my $r = shift;
        my $user = '123';// WILL BE REPLACED MY CAS VERFICATION, DUMMY ONLY

                # update connection record
                $r->connection->user($user);

        return Apache2::Const::OK;

   }

But if we define the handler as PerlHandler $r is available

my httpd.conf looks as follows

<Location /secure>
    AuthType CAS
    AuthName "AuthCAS"
    PerlAuthenHandler AuthCAS->authen_handler
    Require valid-user
 </Location>



Robert Landrum wrote:
> 
> Tracy12 wrote:
>> 1) As we dont use the apache basic authentication but our CAS
>> authentication. If the authentication is not successful how can we
>> redirect
>> to the CAS login page. 
>> 
> 
> Ah-ha...  So CAS authentication is done via a webform of some type, 
> which means that it uses cookies.  Am I correct in this?
> 
> I'm not positive about this, but I think you probably want a 
> PerlAuthzHandler instead.  In this handler you would confirm that the 
> user is logged into the CAS system, set the REMOTE_USER environment 
> variable, and return OK.  If the user wasn't logged in, then you'd 
> redirect to the CAS login page.
> 
> 
>> 2) As we dont use the basic authentication in apache in the above
>> httpd.conf
>> entry what the values should we give for AuthType , AuthName in the above
>> Location declaration.
>> 
> 
> I think, with PerlAuthzHandler you only need to specify a "Requires 
> valid-user" to make it work.
> 
> Rob
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Lost-ENV-variable-value-.........-tf2956856.html#a8290672
Sent from the mod_perl - General mailing list archive at Nabble.com.

Reply via email to