From 9fe85d7ff4f6fedbaaf2a1311bc16f8b8879d7b1 Mon Sep 17 00:00:00 2001 From: John Shahid Date: Tue, 26 Feb 2013 17:37:27 -0500 Subject: [PATCH] add a TODO to the ntlm v2 test. --- src/ntlm/ntlmv2_test.go | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/src/ntlm/ntlmv2_test.go b/src/ntlm/ntlmv2_test.go index 5aa4ed3..faf5243 100644 --- a/src/ntlm/ntlmv2_test.go +++ b/src/ntlm/ntlmv2_test.go @@ -126,6 +126,34 @@ func TestNTLMv2(t *testing.T) { if err != nil { t.Errorf("Could not process server generated challenge message: %s", err) } + // TODO: we should be able to use the ntlm library end to end to make sure + // that Mac, VerifyMac + + // // the client should be able to verify the server's mac + // sig := "" + // mac, err := server.Mac([]byte(sig), 100) + // if err != nil { + // t.Errorf("Could not generate a mac for %s", sig) + // } + // matches, err := client.VerifyMac([]byte(sig), mac, 100) + // if err != nil { + // t.Errorf("Could not verify mac for %s (mac = %v)", sig, mac) + // } + // if !matches { + // t.Errorf("Server's Mac couldn't be verified by client") + // } + + // mac, err = client.Mac([]byte(sig), 100) + // if err != nil { + // t.Errorf("Could not generate a mac for %s", sig) + // } + // matches, err = server.VerifyMac([]byte(sig), mac, 100) + // if err != nil { + // t.Errorf("Could not verify mac for %s (mac = %v)", sig, mac) + // } + // if !matches { + // t.Errorf("Client's Mac couldn't be verified by server") + // } } func TestWindowsTimeConversion(t *testing.T) {