git-cvsserver: do not try to descramble empty password
A message that is not in the archive (sent off-list or not yet received): -1644121413921817001@unknownmsgid
PATCH 3/4 git-cvsserver: do not try to descramble empty password
git-cvsserver.perl | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
git-cvsserver.perl +0 -0
@@ -235,11 +235,15 @@ if ($state->{method} eq 'pserver') {
exit 1;
}
+ if (length($password) > 0) {
+ $password = descramble($password);
+ }
+
my $auth_ok;
open my $passwd, "<", $authdb or die $!;
while (<$passwd>) {
if (m{^\Q$user\E:(.*)}) {
- if (crypt($user, descramble($password)) eq $1) {
+ if (crypt($user, $password) eq $1) { $auth_ok = 1;
}
};
--
1.7.2.rc1.dirty