NetShareAdd returns WERR_BADFILE if the path to be shared does not exist ...

Richard Sharpe realrichardsharpe at gmail.com
Thu Apr 11 10:45:54 MDT 2013


In case anyone is interested ...

I spent some time with Hyena a little while ago looking at what
happens when it tries to create shares using NetShareAdd.

It turns out that NetShareAdd returns WERR_BADFILE if the path does
not exist. This seems not to be documented. I am not sure what is
returned if the requester does not have the appropriate permissions. A
little more testing would probably reveal what is needed.

However, we have a fundamental problem in Samba that does not provide
a way for the share add command to return a status.

Some minor fixes in this area would allow Samba to work better with
tools like Hyena.

-- 
Regards,
Richard Sharpe
(何以解憂?唯有杜康。--曹操)


More information about the samba-technical mailing list