Subject: kern/20991: smbfs mount against WinNT fails
To: None <gnats-bugs@gnats.netbsd.org>
From: None <robert@ifoer.tuwien.ac.at>
List: netbsd-bugs
Date: 04/03/2003 20:19:53
>Number:         20991
>Category:       kern
>Synopsis:       smbfs mount against WinNT fails
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Apr 03 10:20:00 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Robert Vargason
>Release:        NetBSD 1.6Q from Mar 31
>Organization:
	
>Environment:
	
	
System: NetBSD client 1.6Q NetBSD 1.6Q (STUD1) #0: Mon Mar 31 17:42:24 CEST 2003 robert@server:/home/robert/161/usr/src/sys/arch/i386/compile/STUD1 i386
Architecture: i386
Machine: i386
>Description:
mounting against a WinNT host fails.  Accessing the same share with
smbclient works, though.  The command used:
	mount_smbfs -I nt-server //robert@nt-server/robert /test

the kernel produced the following output (with NB_DEBUG enabled):
------------
Apr  3 19:59:05 client /netbsd: smb_nbst_bind(603):
Apr  3 19:59:05 client /netbsd: smb_nbst_connect(637):
Apr  3 19:59:05 client /netbsd: nb_put_name(248): [ DBDCDICODBDDDACODBDHDJCODCDAACCA]
Apr  3 19:59:05 client /netbsd: nb_put_name(248): [ FDFEFFEEEFEOFEACACACACACACACACAA]
Apr  3 19:59:05 client /netbsd: nbssn_recv(467): session closed by peer
Apr  3 19:59:05 client /netbsd: nbssn_rq_request(355): recv() error 54
------------
tcpdump produced the following output:
------------
19:59:05.048142 client.65476 > nt-server.netbios-ssn: S 2433452135:2433452135(0) win 65535 <mss 1460,nop,wscale 1,nop,nop,timestamp 0 0> (DF)
			 4500 003c 281f 4000 4006 b638 8082 a84b
			 8082 b314 ffc4 008b 910b 8867 0000 0000
			 a002 ffff d4df 0000 0204 05b4 0103 0301
			 0101 080a 0000 0000 0000 0000
19:59:05.048751 nt-server.netbios-ssn > client.65476: S 1099925:1099925(0) ack 2433452136 win 8760 <mss 1460> (DF)
			 4500 002c 2cd9 4000 7f06 728e 8082 b314
			 8082 a84b 008b ffc4 0010 c895 910b 8868
			 6012 2238 3710 0000 0204 05b4 05b4
19:59:05.048868 client.65476 > nt-server.netbios-ssn: . ack 1 win 65535 (DF)
			 4500 0028 2820 4000 4006 b64b 8082 a84b
			 8082 b314 ffc4 008b 910b 8868 0010 c896
			 5010 ffff 7105 0000
19:59:05.058204 client.65476 > nt-server.netbios-ssn: P 1:73(72) ack 1 win 65535 (DF)
			 4500 0070 2821 4000 4006 b602 8082 a84b
			 8082 b314 ffc4 008b 910b 8868 0010 c896
			 5018 ffff 01ff 0000 8100 0044 2044 4244
			 4344 4943 4f44 4244 4444 4143 4f44 4244
			 4844 4a43 4f44 4344 4141 4343 4100 2046
			 4446 4546 4645 4545 4645 4f46 4541 4341
			 4341 4341 4341 4341 4341 4341 4341 4100
19:59:05.058853 nt-server.netbios-ssn > client.65476: FP 1:6(5) ack 73 win 8688 (DF)
			 4500 002d 2dd9 4000 7f06 718d 8082 b314
			 8082 a84b 008b ffc4 0010 c896 910b 88b0
			 5019 21f0 49bd 0000 8300 0001 8200
19:59:05.058973 client.65476 > nt-server.netbios-ssn: . ack 7 win 65535 (DF)
			 4500 0028 2823 4000 4006 b648 8082 a84b
			 8082 b314 ffc4 008b 910b 88b0 0010 c89c
			 5010 ffff 70b7 0000
19:59:05.068161 client.65476 > nt-server.netbios-ssn: F 73:73(0) ack 7 win 65535 (DF)
			 4500 0028 2824 4000 4006 b647 8082 a84b
			 8082 b314 ffc4 008b 910b 88b0 0010 c89c
			 5011 ffff 70b6 0000
19:59:05.068667 nt-server.netbios-ssn > client.65476: . ack 74 win 8688 (DF)
			 4500 0028 2ed9 4000 7f06 7092 8082 b314
			 8082 a84b 008b ffc4 0010 c89c 910b 88b1
			 5010 21f0 4ec6 0000 0000 0000 0000
------------



mounting against a samba server (2.2.8 on NetBSD/i386 1.6) works
with the following command:
	mount_smbfs -I server //robert@server/test /test

the kernel produced the following output (with NB_DEBUG enabled):
------------
Apr  3 19:55:26 client /netbsd: smb_nbst_bind(603):
Apr  3 19:55:26 client /netbsd: smb_nbst_connect(637):
Apr  3 19:55:26 client /netbsd: nb_put_name(248): [ DBDCDICODBDDDACODBDHDJCODCDHACCA]
Apr  3 19:55:26 client /netbsd: nb_put_name(248): [ FDFEFFEEEFEOFEACACACACACACACACAA]
------------
tcpdump produced the following output:
------------
19:55:26.104007 client.65489 > server.netbios-ssn: S 3463537177:3463537177(0) win 65535 <mss 1460,nop,wscale 1,nop,nop,timestamp 0 0> (DF)
			 4500 003c 25c6 4000 4006 b88a 8082 a84b
			 8082 b31b ffd1 008b ce71 6219 0000 0000
			 a002 ffff bdb3 0000 0204 05b4 0103 0301
			 0101 080a 0000 0000 0000 0000
19:55:26.104599 server.netbios-ssn > client.65489: S 930274243:930274243(0) ack 3463537178 win 16384 <mss 1460,nop,wscale 0,nop,nop,timestamp 0 0>
			 4500 003c baa0 0000 3f06 64b0 8082 b31b
			 8082 a84b 008b ffd1 3772 dbc3 ce71 621a
			 a012 4000 6a6d 0000 0204 05b4 0103 0300
			 0101 080a 0000 0000 0000 0000
19:55:26.104712 client.65489 > server.netbios-ssn: . ack 1 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 0034 25c7 4000 4006 b891 8082 a84b
			 8082 b31b ffd1 008b ce71 621a 3772 dbc4
			 8010 8052 55df 0000 0101 080a 0000 0000
			 0000 0000
19:55:26.114039 client.65489 > server.netbios-ssn: P 1:73(72) ack 1 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 007c 25c8 4000 4006 b848 8082 a84b
			 8082 b31b ffd1 008b ce71 621a 3772 dbc4
			 8018 8052 dfd8 0000 0101 080a 0000 0000
			 0000 0000 8100 0044 2044 4244 4344 4943
			 4f44 4244 4444 4143 4f44 4244 4844 4a43
			 4f44 4344 4841 4343 4100 2046 4446 4546
			 4645 4545 4645 4f46 4541 4341 4341 4341
			 4341 4341 4341 4341 4341 4100
19:55:26.129409 server.netbios-ssn > client.65489: P 1:5(4) ack 73 win 17520
			 4500 002c baa3 0000 3f06 64bd 8082 b31b
			 8082 a84b 008b ffd1 3772 dbc4 ce71 6262
			 5018 4470 4884 0000 8200 0000 3136
19:55:26.129670 client.65489 > server.netbios-ssn: P 73:241(168) ack 5 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 00dc 25d2 4000 4006 b7de 8082 a84b
			 8082 b31b ffd1 008b ce71 6262 3772 dbc8
			 8018 8052 f6f7 0000 0101 080a 0000 0000
			 0000 0000 0000 00a4 ff53 4d42 7200 0000
			 0000 0000 0000 0000 0000 0000 0000 0000
			 ffff 0100 ffff 0000 0081 0002 5043 204e
			 4554 574f 524b 2050 524f 4752 414d 2031
			 2e30 0002 4d49 4352 4f53 4f46 5420 4e45
			 5457 4f52 4b53 2031 2e30 3300 024d 4943
			 524f 534f 4654 204e 4554 574f 524b 5320
			 332e 3000 024c 414e 4d41 4e31 2e30 0002
			 4c4d 312e 3258 3030 3200 0253 616d 6261
			 0002 4e54 204c 414e 4d41 4e20 312e 3000
			 024e 5420 4c4d 2030 2e31 3200
19:55:26.130908 server.netbios-ssn > client.65489: P 5:92(87) ack 241 win 17520
			 4500 007f baa4 0000 3f06 6469 8082 b31b
			 8082 a84b 008b ffd1 3772 dbc8 ce71 630a
			 5018 4470 12cc 0000 0000 0053 ff53 4d42
			 7200 0000 0080 0100 0000 0000 0000 0000
			 0000 0000 ffff 0100 ffff 0000 1106 0001
			 3200 0100 0441 0000 0000 0100 d847 0000
			 f9e3 0000 007b aa34 0afa c201 88ff 000e
			 0049 4649 5057 4f52 4b47 524f 5550 00
19:55:26.131135 client.65489 > server.netbios-ssn: P 241:340(99) ack 92 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 0097 25d3 4000 4006 b822 8082 a84b
			 8082 b31b ffd1 008b ce71 630a 3772 dc1f
			 8018 8052 d9b6 0000 0101 080a 0000 0000
			 0000 0000 0000 005f ff53 4d42 7300 0000
			 0000 0100 0000 0000 0000 0000 0000 0000
			 ffff 0100 ffff 0100 0dff 0000 0004 4132
			 0004 00d8 4700 0008 0000 0000 0000 0000
			 0000 0022 0074 6573 7474 6573 7452 4f42
			 4552 5400 5445 5354 004e 6574 4253 4400
			 4e45 5453 4d42 00
19:55:26.133642 server.netbios-ssn > client.65489: P 92:168(76) ack 340 win 17520
			 4500 0074 baa5 0000 3f06 6473 8082 b31b
			 8082 a84b 008b ffd1 3772 dc1f ce71 636d
			 5018 4470 d580 0000 0000 0048 ff53 4d42
			 7300 0000 0080 0100 0000 0000 0000 0000
			 0000 0000 ffff 0100 6400 0100 03ff 0000
			 0000 001f 0055 6e69 7800 5361 6d62 6120
			 322e 322e 3800 4946 4950 574f 524b 4752
			 4f55 5000
19:55:26.133872 client.65489 > server.netbios-ssn: P 340:413(73) ack 168 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 007d 25d4 4000 4006 b83b 8082 a84b
			 8082 b31b ffd1 008b ce71 636d 3772 dc6b
			 8018 8052 2a01 0000 0101 080a 0000 0000
			 0000 0000 0000 0045 ff53 4d42 7500 0000
			 0000 0100 0000 0000 0000 0000 0000 0000
			 ffff 0100 6400 0200 04ff 0000 0000 0001
			 001a 0000 5c5c 3132 382e 3133 302e 3137
			 392e 3237 5c54 4553 5400 413a 00
19:55:26.135788 server.netbios-ssn > client.65489: P 168:221(53) ack 413 win 17520
			 4500 005d baa6 0000 3f06 6489 8082 b31b
			 8082 a84b 008b ffd1 3772 dc6b ce71 63b6
			 5018 4470 ca1f 0000 0000 0031 ff53 4d42
			 7500 0000 0080 0100 0000 0000 0000 0000
			 0000 0000 0100 0100 6400 0200 03ff 0000
			 0001 0008 0041 3a00 4e54 4653 00
19:55:26.136677 client.65489 > server.netbios-ssn: P 413:487(74) ack 221 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 007e 25d5 4000 4006 b839 8082 a84b
			 8082 b31b ffd1 008b ce71 63b6 3772 dca0
			 8018 8052 59d1 0000 0101 080a 0000 0000
			 0000 0000 0000 0046 ff53 4d42 3200 0000
			 0000 0100 0000 0000 0000 0000 0000 0000
			 0100 0100 6400 0300 0f02 0000 0004 0012
			 0000 0000 0000 0000 0000 0002 0044 0000
			 0000 0001 0003 0005 0000 0000 0100
19:55:26.137599 server.netbios-ssn > client.65489: P 221:299(78) ack 487 win 17520
			 4500 0076 baa7 0000 3f06 646f 8082 b31b
			 8082 a84b 008b ffd1 3772 dca0 ce71 6400
			 5018 4470 8d5a 0000 0000 004a ff53 4d42
			 3200 0000 0080 4100 0000 0000 0000 0000
			 0000 0000 0100 0100 6400 0300 0a00 0012
			 0000 0000 0038 0000 0012 0038 0000 0000
			 0013 0000 0312 0000 0010 0000 aedd 0000
			 545c 0000 0002
19:55:26.328959 client.65489 > server.netbios-ssn: . ack 299 win 32850 <nop,nop,timestamp 0 0> (DF)
			 4500 0034 25d8 4000 4006 b880 8082 a84b
			 8082 b31b ffd1 008b ce71 6400 3772 dcee
			 8010 8052 52cf 0000 0101 080a 0000 0000
			 0000 0000
------------

If you need any other data, please let me know.
>How-To-Repeat:
	try mounting a WinNT share with the above command
>Fix:
	none known
>Release-Note:
>Audit-Trail:
>Unformatted: