Catalyst::Plugin::Authentication::Credential::HTTP - DEPRECATED HTTP Basic authentication for Catlayst.
use Catalyst qw/ Authentication Authentication::Store::Moose Authentication::Store::Elk Authentication::Credential::HTTP::Proxy /; $c->config->{authentication}{http_proxy}= { url =>'http://elkland.no/auth', store => 'Authentication::Store::Moose' }; sub foo : Local { my ( $self, $c ) = @_; $c->authorization_required( realm => "foo" ); # named after the status code ;-) # either user gets authenticated or 401 is sent do_stuff(); } # with ACL plugin __PACKAGE__->deny_access_unless("/path", sub { $_[0]->authenticate_http }); sub end : Private { my ( $self, $c ) = @_; $c->authorization_required_response( realm => "foo" ); $c->error(0); }
This module is deprecated by Catalyst::Authentication::HTTP::proxy, please do not use this code in new applications.
This moduule lets you use HTTP Proxy authentication with Catalyst::Plugin::Authentication.
Currently this module only supports the Basic scheme, but upon request Digest will also be added. Patches welcome!
This module reads config from $c->config->{authentication}{http_proxy}. The following settings are supported:
Required. A url protected with basic authentication to authenticate against.
To specify what store to use. will use the default store if not set.
Tries to authenticate_http_proxy, and if that fails calls authorization_required_response and detaches the current action call stack.
authenticate_http_proxy
authorization_required_response
Looks inside $c->request->headers and processes the basic (badly named) authorization header. Then authenticates this against the provided url.
$c->request->headers
Sets $c->response to the correct status code, and adds the correct header to demand authentication data from the user agent.
$c->response
Marcus Ramberg mramberg@cpan.org
mramberg@cpan.org
Copyright (c) 2005 the aforementioned authors. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Catalyst::Plugin::Authentication::Credential::HTTP::Proxy, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Catalyst::Plugin::Authentication::Credential::HTTP::Proxy
CPAN shell
perl -MCPAN -e shell install Catalyst::Plugin::Authentication::Credential::HTTP::Proxy
For more information on module installation, please visit the detailed CPAN module installation guide.