Skip to content

Commit 05099aa

Browse files
committed
NTLMv2 fixes by Giulio Galante <[email protected]>
1 parent 0a9e683 commit 05099aa

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

CHANGES

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
Changes to proxytunnel after 1.9.0 -- Unreleased
1+
Changes to proxytunnel after 1.9.1 -- Tue Mar 22 16:02:40 CET 2011
22

33
- Switch to HTTP/1.1 commands, so we can tunnel over JoikuSpot's which
44
don't understand http/1.0 command (Mark Janssen)
5+
- NTLMv2 fixes by Giulio Galante <[email protected]>
56

67
Changes to proxytunnel version 1.9.0 -- Sat Feb 23 22:03:10 CET 2008
78

ntlm.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@ void build_ntlm2_response() {
405405
b = (blob *)pblob;
406406

407407
for (i = 0; i < 8; i++)
408-
b->challenge[i] = challenge[i];
408+
b->digest[8 + i] = challenge[i];
409409

410410
b->signature = 0x00000101;
411411

@@ -434,7 +434,7 @@ void build_ntlm2_response() {
434434

435435
memcpy(&b->data_start, t_info, t_info_len);
436436

437-
hmac_md5(&pblob[16], bloblen - 16, userdomdigest, 16, responsedigest);
437+
hmac_md5(&pblob[8], bloblen - 8, userdomdigest, 16, responsedigest);
438438

439439
for(i = 0; i < 16; i++)
440440
b->digest[i] = responsedigest[i];
@@ -449,7 +449,7 @@ void build_ntlm2_response() {
449449
// LM2 response generation
450450

451451
for (i = 0; i < 8; i++)
452-
lm2data[i] = b->challenge[i];
452+
lm2data[i] = challenge[i];
453453

454454
for (i = 0; i < 8; i++)
455455
lm2data[8 + i] = b->client_challenge[i];

ntlm.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ typedef struct {
9696

9797
typedef struct {
9898
unsigned char digest[16];
99-
unsigned char challenge[8];
10099
unsigned long signature;
101100
unsigned long reserved;
102101
unsigned long long timestamp;

0 commit comments

Comments
 (0)