[Samba] NT_STATUS code list ?
David Morel
david.morel at amakuru.net
Thu Feb 13 14:27:14 GMT 2003
Hi,
I'm trying to automate a server connection to various shares on my network (so
as to back them up). I use smbmount which works fine, except on one machine
running winXp:
i shared a directory on that machine, using a locally created windows user
with read-only rights as the only one allowed to access this share. When i
tried to mount it (kernel 2.4.20) with smbfs, smbmount hanged, and there was
no way i could unmount the share, so i had to reboot.
In fact, the username and pass i used were wrong, i realized that when i used
smbclient on that share and double-checked my setup. The strange thing is i
could do a smbclient //machine/share -c ls even with the wrong username and
password, the answer being 'NT_STATUS_ACCESS_DENIED listing \*'. It gave me
an answer about smbfs sending all these (approx. from memory)
'smb_proc_readdir_long read=\* err=5'. So i know now where the trouble is.
The funny thing is that the xp machine even when denying access still prints
the disk free space :-)
What i want to do know is prior to mounting the shares, try to smbclient them,
and depending on the answer decide to mount the share or not. The range of
answers i got so far was NT_STATUS_UNSUCCESSFUL, NT_STATUS_LOGON_FAILURE and
NT_STATUS_WRONG_PASSWORD; all of which are reasons for me not to mount the
given share. I would like to know what other messages of the same kind are
sent back by smbclient, so i can really put that automation stuff together.
I tried to browse the source code of course but... It is huge and i have very
little clue about it all.
Thanks to all
D.Morel
More information about the samba
mailing list