r35154 - in /trunk/libapache2-authcassimple-perl: Changes MANIFEST META.yml Makefile.PL README debian/changelog debian/control debian/libapache2-authcassimple-perl.examples examples/apache_conf/ examples/apache_www/ lib/Apache2/AuthCASSimple.pm
yvesago-guest at users.alioth.debian.org
yvesago-guest at users.alioth.debian.org
Mon May 11 07:09:47 UTC 2009
Author: yvesago-guest
Date: Mon May 11 07:09:42 2009
New Revision: 35154
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=35154
Log:
* New upstream release, real full fix for #525097 and #521059
* Add libcrypt-ssleay-perl, liburi-perl in Depends,
* Add liburi-perl in Build-Depends
* only examples/delete_session_data.pl in examples others are only test
cases for dev
Added:
trunk/libapache2-authcassimple-perl/examples/apache_conf/
- copied from r35152, branches/upstream/libapache2-authcassimple-perl/current/examples/apache_conf/
trunk/libapache2-authcassimple-perl/examples/apache_www/
- copied from r35152, branches/upstream/libapache2-authcassimple-perl/current/examples/apache_www/
Modified:
trunk/libapache2-authcassimple-perl/Changes
trunk/libapache2-authcassimple-perl/MANIFEST
trunk/libapache2-authcassimple-perl/META.yml
trunk/libapache2-authcassimple-perl/Makefile.PL
trunk/libapache2-authcassimple-perl/README
trunk/libapache2-authcassimple-perl/debian/changelog
trunk/libapache2-authcassimple-perl/debian/control
trunk/libapache2-authcassimple-perl/debian/libapache2-authcassimple-perl.examples
trunk/libapache2-authcassimple-perl/lib/Apache2/AuthCASSimple.pm
Modified: trunk/libapache2-authcassimple-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/Changes?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/Changes (original)
+++ trunk/libapache2-authcassimple-perl/Changes Mon May 11 07:09:42 2009
@@ -1,4 +1,10 @@
Revision history for Perl module Apache2::AuthCASSimple
+
+0.10 Thu, 10 May 2009 11:53:07 +0200
+ - add dep on Crypt::SSLeay
+ - swap clean login_url (0.07 was a bad idea) with uri_escape
+ - fix _post_to_get with $r->read closes https://rt.cpan.org/Ticket/Display.html?id=45923
+ - add test cases in examples
0.09 Wed, 22 Apr 2009 12:33:26 +0200
- revert use of CGI, better fix up for REMOTE_USER bug
Modified: trunk/libapache2-authcassimple-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/MANIFEST?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/MANIFEST (original)
+++ trunk/libapache2-authcassimple-perl/MANIFEST Mon May 11 07:09:42 2009
@@ -1,4 +1,6 @@
Changes
+examples/apache_conf/default
+examples/apache_www/index.html
examples/delete_session_data.pl
inc/Module/AutoInstall.pm
inc/Module/Install.pm
Modified: trunk/libapache2-authcassimple-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/META.yml?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/META.yml (original)
+++ trunk/libapache2-authcassimple-perl/META.yml Mon May 11 07:09:42 2009
@@ -1,15 +1,14 @@
---
-abstract: 'Apache2 module to authentificate trough a CAS server'
+abstract: 'Apache2 module to authentificate through a CAS server'
author:
- 'Yves Agostini'
build_requires:
- Apache2::Connection: 0
- Apache2::Log: 0
Apache::Session::Wrapper: 0
Authen::CAS::Client: 0
Pod::Coverage: 0
Test::More: 0
- mod_perl2: 1.99
+ URI::Escape: 0
+ mod_perl2: 0
distribution_type: module
generated_by: 'Module::Install version 0.76'
license: perl
@@ -24,12 +23,12 @@
- t
- examples
requires:
- Apache2::Connection: 0
- Apache2::Log: 0
Apache::Session::Wrapper: 0
Authen::CAS::Client: 0
- mod_perl: 1.99
+ Crypt::SSLeay: 0
+ URI::Escape: 0
+ mod_perl2: 0
perl: 5.8.0
resources:
license: http://dev.perl.org/licenses/
-version: 0.09
+version: 0.10
Modified: trunk/libapache2-authcassimple-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/Makefile.PL?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/Makefile.PL (original)
+++ trunk/libapache2-authcassimple-perl/Makefile.PL Mon May 11 07:09:42 2009
@@ -5,19 +5,18 @@
all_from 'lib/Apache2/AuthCASSimple.pm';
version_from 'lib/Apache2/AuthCASSimple.pm';
-requires 'mod_perl' => 1.99;
requires 'Apache::Session::Wrapper';
requires 'Authen::CAS::Client';
-requires 'Apache2::Log';
-requires 'Apache2::Connection';
+requires 'mod_perl2';
+requires 'Crypt::SSLeay';
+requires 'URI::Escape';
build_requires 'Pod::Coverage';
build_requires 'Test::More';
-build_requires 'mod_perl2' => 1.99;
build_requires 'Apache::Session::Wrapper';
build_requires 'Authen::CAS::Client';
-build_requires 'Apache2::Log';
-build_requires 'Apache2::Connection';
+build_requires 'URI::Escape';
+build_requires 'mod_perl2';
auto_install;
Modified: trunk/libapache2-authcassimple-perl/README
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/README?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/README (original)
+++ trunk/libapache2-authcassimple-perl/README Mon May 11 07:09:42 2009
@@ -1,10 +1,10 @@
NAME
- Apache2::AuthCASSimple - Apache2 module to authentificate trough a CAS
+ Apache2::AuthCASSimple - Apache2 module to authentificate through a CAS
server
DESCRIPTION
Apache2::AuthCASSimple is an authentication module for
- Apache2/mod_perl2. It allow you to authentificate users trough a Yale
+ Apache2/mod_perl2. It allow you to authentificate users through a Yale
CAS server. It means you don't need to give login/password if you've
already be authentificate by the CAS server, only tickets are exchanged
between Web client, Apache2 server and CAS server. If you not're
@@ -13,6 +13,8 @@
This module allow the use of simple text files for sessions.
SYNOPSIS
+ PerlOptions +GlobalRequest
+
<Location /protected>
AuthType Apache2::AuthCASSimple
PerlAuthenHandler Apache2::AuthCASSimple
@@ -21,10 +23,11 @@
PerlSetVar CASServerPath /
# PerlSetVar CASServerPort 443
# PerlSetVar CASServerNoSSL 1
- PerlSetVar CASSessionTimeout 60
+ PerlSetVar CASSessionTimeout 3660
PerlSetVar CASSessionDirectory /tmp
# PerlSetVar CASFixDirectory /
# PerlSetVar ModProxy 1
+ # PerlSetVar HTTPSServer 1
require valid-user
</Location>
@@ -77,24 +80,40 @@
ModProxy
Apache2 mod_perl2 don't be use with mod_proxy. Default is off.
+ HTTPSServer
+ If you want to keep a HTTPS server for all data. Default is 0.
+
+ OK AUTH_REQUIRED DECLINED REDIRECT SERVER_ERROR M_GET
+ Apache constants to make pod coverage happy
+
METHOD
handler
call by apache2
VERSION
- This documentation describes Apache2::AuthCASSimple version 0.0.1
+ This documentation describes Apache2::AuthCASSimple version 0.10
BUGS AND TROUBLESHOOTING
- * Old expired sessions files must be deleted with an example provided
- script : "delete_session_data.pl"
- * Apache::Session::Wrapper certainly need Apache2::Cookie
- * $r must be global for sessions with Apache::Session::Wrapper, add
+ * Old expired sessions files must be deleted with an example provided
+ script : "delete_session_data.pl"
+
+ * Apache::Session::Wrapper certainly need Apache2::Cookie
+
+ * $r must be global for sessions with Apache::Session::Wrapper, add
+
PerlOptions +GlobalRequest
in your virtualhost conf
- * Apreq module must be enable in debian
+ * Apreq module must be enable in debian
+
+ a2enmod apreq
+
+ or add
+
LoadModule apreq_module /usr/lib/apache2/modules/mod_apreq2.so
+
+ in your apache configuration file
Please submit any bug reports to agostini at univ-metz.fr.
@@ -110,7 +129,7 @@
http://www.crium.univ-metz.fr
COPYRIGHT
- Copyright 2008 Yves Agostini - <agostini at univ-metz.fr>
+ Copyright (c) 2009 by Yves Agostini
This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.
Modified: trunk/libapache2-authcassimple-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/debian/changelog?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/debian/changelog (original)
+++ trunk/libapache2-authcassimple-perl/debian/changelog Mon May 11 07:09:42 2009
@@ -1,3 +1,13 @@
+libapache2-authcassimple-perl (0.10-1) unstable; urgency=low
+
+ * New upstream release, real full fix for #525097 and #521059
+ * Add libcrypt-ssleay-perl, liburi-perl in Depends,
+ * Add liburi-perl in Build-Depends
+ * only examples/delete_session_data.pl in examples others are only test
+ cases for dev
+
+ -- AGOSTINI Yves <agostini at univ-metz.fr> Mon, 11 May 2009 08:54:54 +0200
+
libapache2-authcassimple-perl (0.09-1) unstable; urgency=low
* New upstream release
Modified: trunk/libapache2-authcassimple-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/debian/control?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/debian/control (original)
+++ trunk/libapache2-authcassimple-perl/debian/control Mon May 11 07:09:42 2009
@@ -4,7 +4,7 @@
Build-Depends: debhelper (>= 7)
Build-Depends-Indep: perl (>= 5.8.0), libauthen-cas-client-perl,
libapache-session-wrapper-perl, libapache2-mod-perl2,
- libtest-pod-coverage-perl, libtest-pod-perl
+ libtest-pod-coverage-perl, libtest-pod-perl, liburi-perl
Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
Uploaders: AGOSTINI Yves <agostini at univ-metz.fr>,
Damyan Ivanov <dmn at debian.org>
@@ -16,7 +16,8 @@
Package: libapache2-authcassimple-perl
Architecture: all
Depends: ${perl:Depends} , ${misc:Depends}, libapache-session-wrapper-perl,
- libapache2-mod-perl2, libauthen-cas-client-perl, libapache2-request-perl
+ libapache2-mod-perl2, libauthen-cas-client-perl, libapache2-request-perl,
+ libcrypt-ssleay-perl, liburi-perl
Description: Apache2 module to authentificate trough a CAS server
Apache2::AuthCASSimple is an authentication module for Apache2/mod_perl2.
.
Modified: trunk/libapache2-authcassimple-perl/debian/libapache2-authcassimple-perl.examples
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/debian/libapache2-authcassimple-perl.examples?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/debian/libapache2-authcassimple-perl.examples (original)
+++ trunk/libapache2-authcassimple-perl/debian/libapache2-authcassimple-perl.examples Mon May 11 07:09:42 2009
@@ -1,1 +1,1 @@
-examples/*
+examples/delete_session_data.pl
Modified: trunk/libapache2-authcassimple-perl/lib/Apache2/AuthCASSimple.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libapache2-authcassimple-perl/lib/Apache2/AuthCASSimple.pm?rev=35154&op=diff
==============================================================================
--- trunk/libapache2-authcassimple-perl/lib/Apache2/AuthCASSimple.pm (original)
+++ trunk/libapache2-authcassimple-perl/lib/Apache2/AuthCASSimple.pm Mon May 11 07:09:42 2009
@@ -9,9 +9,11 @@
use Apache::Session::Wrapper;
use Authen::CAS::Client;
use Apache2::Connection;
+use Apache2::RequestIO;
+use URI::Escape;
use vars qw($VERSION);
-$VERSION = '0.09';
+$VERSION = '0.10';
#
# handler()
@@ -66,9 +68,7 @@
}
my $requested_url = _get_requested_url($r,$mod_proxy);
- my $login_url = $requested_url;
- # TODO better clean url
- $login_url =~ s/\?/\&/;
+ my $login_url = uri_escape $requested_url;
$login_url = $cas->login_url().$login_url;
#$log->info( '==login_url==='.$login_url.'____');
@@ -100,7 +100,7 @@
unless ($user) {
$log->info(__PACKAGE__.": Unable to validate ticket ".$ticket." on CAS server.");
- $r->err_headers_out->add("Location" => $login_url);
+ $r->err_headers_out->add("Location" => $r->uri._str_args($r)); # remove ticket
return REDIRECT;
}
@@ -108,12 +108,11 @@
if ( $user ) {
$r->user($user);
- my $str_args = _str_args($r);
+ my $str_args = _str_args($r); # remove ticket
$log->info(__PACKAGE__.": New session ".$r->uri() ."--".$r->args());
# if we are there (and timeout is set), we can create session data and cookie
- _remove_ticket($r);
_create_user_session($r) if($cas_session_timeout >= 0);
$log->debug("Location => ".$r->uri . ($str_args ? '?' . $str_args : ''));
$r->err_headers_out->add("Location" => $r->uri . ($str_args ? '?' . $str_args : '') );
@@ -142,7 +141,6 @@
foreach (sort {$a cmp $b} keys(%args)) {
next if ($_ eq 'ticket' && !$keep_ticket);
my $str = $args{$_};
- $str =~ s/([^A-Za-z0-9])/sprintf("%%%02X", ord($1))/seg;
push(@qs, $_."=".$str);
}
@@ -193,7 +191,8 @@
sub _post_to_get ($) {
my $r = shift;
- my $content = _str_args($r,1);
+ my $content;
+ $r->read($content,$r->headers_in->{'Content-length'});
$r->log()->info('POST to GET: '.$content);
$r->method("GET");
@@ -320,11 +319,11 @@
=head1 NAME
-Apache2::AuthCASSimple - Apache2 module to authentificate trough a CAS server
+Apache2::AuthCASSimple - Apache2 module to authentificate through a CAS server
=head1 DESCRIPTION
-Apache2::AuthCASSimple is an authentication module for Apache2/mod_perl2. It allow you to authentificate users trough a Yale CAS server. It means you don't need to give login/password if you've already be authentificate by the CAS server, only tickets are exchanged between Web client, Apache2 server and CAS server. If you not're authentificate yet, you'll be redirect on the CAS server login form.
+Apache2::AuthCASSimple is an authentication module for Apache2/mod_perl2. It allow you to authentificate users through a Yale CAS server. It means you don't need to give login/password if you've already be authentificate by the CAS server, only tickets are exchanged between Web client, Apache2 server and CAS server. If you not're authentificate yet, you'll be redirect on the CAS server login form.
This module allow the use of simple text files for sessions.
@@ -425,7 +424,7 @@
=head1 VERSION
-This documentation describes Apache2::AuthCASSimple version 0.09
+This documentation describes Apache2::AuthCASSimple version 0.10
=head1 BUGS AND TROUBLESHOOTING
More information about the Pkg-perl-cvs-commits
mailing list