version 1.19, 2001/06/02 16:10:04
|
version 1.26, 2001/10/08 22:37:50
|
Line 5
|
Line 5
|
# 1/14,2/24,2/28,2/29,3/7,5/29,5/30,5/31,6/1,6/5,6/29, |
# 1/14,2/24,2/28,2/29,3/7,5/29,5/30,5/31,6/1,6/5,6/29, |
# 7/1,7/10,10/2,10/5,10/9,10/26,10/30,11/10, |
# 7/1,7/10,10/2,10/5,10/9,10/26,10/30,11/10, |
# 05/28,05/29 Gerd Kortemeyer |
# 05/28,05/29 Gerd Kortemeyer |
|
# 07/24 Scott Harrison |
|
# 07/28,08/03 Gerd Kortemeyer |
|
# 8/15 Scott Harrison |
|
# 8/20 Gerd Kortemeyer |
|
|
package Apache::lonauth; |
package Apache::lonauth; |
|
|
Line 13 use Apache::Constants qw(:common);
|
Line 17 use Apache::Constants qw(:common);
|
use Apache::File; |
use Apache::File; |
use CGI qw(:standard); |
use CGI qw(:standard); |
use CGI::Cookie(); |
use CGI::Cookie(); |
|
use DynaLoader; # for Crypt::DES version |
use Crypt::DES; |
use Crypt::DES; |
use Apache::lonnet(); |
use Apache::lonnet(); |
use Apache::lonmenu(); |
use Apache::lonmenu(); |
Line 120 sub success {
|
Line 125 sub success {
|
|
|
# ------------------------------------------------- Check for critical messages |
# ------------------------------------------------- Check for critical messages |
|
|
my @what=&Apache::lonnet::dump('critical'); |
my @what=&Apache::lonnet::dump('critical',$domain,$username); |
if ($what[0]) { |
if ($what[0]) { |
if ($what[0] ne 'con_lost') { |
if (($what[0] ne 'con_lost') && ($what[0]!~/^error\:/)) { |
$lowerurl='/adm/email/critical/'.$what[0]; |
$lowerurl='/adm/email?critical=display'; |
} |
} |
} |
} |
|
|
Line 170 function wait() {
|
Line 175 function wait() {
|
} |
} |
|
|
function main() { |
function main() { |
canceltim=setTimeout('tim=1;',20000); |
canceltim=setTimeout('tim=1;',80000); |
checkdef(); |
checkdef(); |
wait(); |
wait(); |
} |
} |
|
|
</script> |
</script> |
</head> |
</head> |
<body bgcolor="#FFFFFF" onLoad="main();"> |
<body bgcolor="#FFFFFF"> |
<script> |
<script> |
menuloaded=0; |
menuloaded=0; |
tim=0; |
tim=0; |
</script> |
</script> |
$windowinfo |
$windowinfo |
<h1>Welcome!</h1> |
<h1>Welcome!</h1> |
|
<script> |
|
main(); |
|
</script> |
</body> |
</body> |
</html> |
</html> |
ENDSUCCESS |
ENDSUCCESS |
Line 252 sub handler {
|
Line 260 sub handler {
|
|
|
my $keybin=pack("H16",$key); |
my $keybin=pack("H16",$key); |
|
|
my $cipher=new DES $keybin; |
my $cipher; |
|
if ($Crypt::DES::VERSION>=2.03) { |
|
$cipher=new Crypt::DES $keybin; |
|
} |
|
else { |
|
$cipher=new DES $keybin; |
|
} |
|
|
my $upass=$cipher->decrypt( |
my $upass=$cipher->decrypt( |
unpack("a8",pack("H16",substr($FORM{'upass'},0,16)))); |
unpack("a8",pack("H16",substr($FORM{'upass'},0,16)))); |
Line 275 sub handler {
|
Line 289 sub handler {
|
} |
} |
|
|
if (($firsturl eq '') || ($firsturl eq '/adm/logout')) { |
if (($firsturl eq '') || ($firsturl eq '/adm/logout')) { |
$firsturl='/res/adm/pages/index.html'; |
$firsturl='/adm/roles'; |
} |
} |
|
|
success($r,$FORM{'uname'},$FORM{'udom'},$authhost,$firsturl); |
success($r,$FORM{'uname'},$FORM{'udom'},$authhost,$firsturl); |