]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Author: Dmitry Kurochkin
authorAmos Jeffries <squid3@treenet.co.nz>
Sun, 10 Aug 2008 12:45:41 +0000 (00:45 +1200)
committerAmos Jeffries <squid3@treenet.co.nz>
Sun, 10 Aug 2008 12:45:41 +0000 (00:45 +1200)
Bug: 23512: no_check.pl ntlm helper never sends challenge

helpers/ntlm_auth/no_check/no_check.pl

index 891d0ddb671d4c984dd724e0a053eda3d08092ad..414df0b47028afb1111671062d225997581c6e54 100644 (file)
@@ -15,7 +15,7 @@ die ("Edit $0 to configure a domain!") unless (defined($authdomain));
 
 while(<STDIN>) {
        chop;
-       if (substr($_, 2) eq "YR") {
+       if (substr($_, 0, 2) eq "YR") {
                print "TT ".encode_base64(&make_ntlm_static_challenge);
                next;
        }
@@ -32,11 +32,11 @@ while(<STDIN>) {
        }
        if ($res{type} eq "challenge") { # Huh? WE are the challengers.
                print "BH Squid-helper protocol error: unexpected challenge-request\n";
-               next;           
+               next;
        }
        if ($res{type} eq "authentication") {
                print "AF $res{domain}\\$res{user}\n";
-               next;           
+               next;
        }
        print "BH internal error\n";    # internal error
 }