Problem with ReadAndX

Christopher R. Hertel crh at
Wed Jan 21 15:06:03 GMT 2009

I don't see much reason to implement LM1.2X002 unless you are planning on
supporting very old OSes.  Windows 95, Windows NT 3.51, and all later OS
Windows version support the NT LM 0.12 dialect, which is still in use today.
 The only newer dialect is SMB2 which appeared in Vista.

...and as Volker asked, what version of Samba are you "enhancing"?  Samba
has supported long file names for a long time.

Are you actually enhancing Samba, or are you enhancing your own product that
implements the same protocols supported by Samba?

Chris -)-----

MaheNabble wrote:
> Hi,
> I am enhancing the Samba Server on our product to support Long Name. So I
> started implementing the dialect "LM1.2X002" (first dialect that supports
> Long Name, the current dialect that we support is PC_Network_Program). I
> have implemented Negotiation, TreeConnectAndX, OpenAndX and Transaction2
> Commands (FIND_FIRST2, NEXT2, FS_INFO) etc.
> The problem that I have is, when I try to read a file (which is of 4 bytes,
> just a txt file), the client sends READ_ANDX command about 40 times and
> after a long time (about 45 seconds), it opens the file. After some
> investigation, I noticed that there is a request (packet no 370) in which it
> expects only 4 bytes of data from the offset 0x0000, there the ReadAndX
> ends.
> I am not sure why there are so many request for just to read 4 bytes of
> data. Why is it not succeeded in the first ReadAndX itself? Why is it
> expecting 256 bytes of data (in the packet 121) instead of 4 bytes?
> I have attached the capture (in zip format, for your
> reference. Your help will be highly appreciated.
> Best Regards,
> Mahendran

"Implementing CIFS - the Common Internet FileSystem" ISBN: 013047116X
Samba Team --     -)-----   Christopher R. Hertel
jCIFS Team --   -)-----   ubiqx development, uninq.
ubiqx Team --     -)-----   crh at
OnLineBook --    -)-----   crh at

More information about the samba-technical mailing list