[freeside-commits] freeside/FS/FS svc_acct.pm,1.205,1.206
Ivan,,,
ivan at wavetail.420.am
Sun Nov 26 17:08:49 PST 2006
Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail:/tmp/cvs-serv18121
Modified Files:
svc_acct.pm
Log Message:
some svc_acct.pm fixes for s1
Index: svc_acct.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/svc_acct.pm,v
retrieving revision 1.205
retrieving revision 1.206
diff -u -d -r1.205 -r1.206
--- svc_acct.pm 28 Sep 2006 17:45:38 -0000 1.205
+++ svc_acct.pm 27 Nov 2006 01:08:47 -0000 1.206
@@ -870,7 +870,7 @@
unless ( $recref->{_password} );
#if ( $recref->{_password} =~ /^((\*SUSPENDED\* )?)([^\t\n]{4,16})$/ ) {
- if ( $recref->{_password} =~ /^((\*SUSPENDED\* )?)([^\t\n]{$passwordmin,$passwordmax})$/ ) {
+ if ( $recref->{_password} =~ /^((\*SUSPENDED\* |!!?)?)([^\t\n]{$passwordmin,$passwordmax})$/ ) {
$recref->{_password} = $1.$3;
#uncomment this to encrypt password immediately upon entry, or run
#bin/crypt_pw in cron to give new users a window during which their
@@ -879,7 +879,7 @@
#$recref->{password} = $1.
# crypt($3,$saltset[int(rand(64))].$saltset[int(rand(64))]
#;
- } elsif ( $recref->{_password} =~ /^((\*SUSPENDED\* )?)([\w\.\/\$\;\+]{13,60})$/ ) {
+ } elsif ( $recref->{_password} =~ /^((\*SUSPENDED\* |!!?)?)([\w\.\/\$\;\+]{13,64})$/ ) {
$recref->{_password} = $1.$3;
} elsif ( $recref->{_password} eq '*' ) {
$recref->{_password} = '*';
@@ -1579,6 +1579,10 @@
} elsif ( $self->_password =~ /^\$2a?\$(.*)$/ ) { #Blowfish
die "Blowfish encryption not supported in this context, svcnum ".
$self->svcnum. "\n";
+ } elsif ( $self->_password =~ /^(\w{48})$/ ) { #LDAP SSHA
+ return '{SSHA}'. $1;
+ } elsif ( $self->_password =~ /^(\w{64})$/ ) { #LDAP NS-MTA-MD5
+ return '{NS-MTA-MD5}'. $1;
} else { #plaintext
return '{PLAIN}'. $self->_password;
#my $encryption = ( scalar(@_) && $_[0] ) ? shift : 'crypt';
More information about the freeside-commits
mailing list