Bug 15364 - TreeConnect Response is abnormal
Summary: TreeConnect Response is abnormal
Status: NEW
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: File services (show other bugs)
Version: 4.18.0rc2
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Samba QA Contact
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-25 16:18 UTC by fouzhe
Modified: 2023-04-25 18:53 UTC (History)
0 users

See Also:


Attachments
Different TreeConnect responses for different malformed Tree fields (422.48 KB, image/png)
2023-04-25 16:18 UTC, fouzhe
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description fouzhe 2023-04-25 16:18:36 UTC
Created attachment 17872 [details]
Different TreeConnect responses for different malformed Tree fields

When I used TreeConnection request with different malformed Tree fields, the response is different. 
For the Tree field in the form "\\server\share", the server responds with STATUS_SUCCESS for a malformed "server" while STATUS_BAD_NETWORK_NAME for a malformed "share", as shown in the attached file. Is it normal?
Comment 1 Jeremy Allison 2023-04-25 17:01:18 UTC
Try the same request against Windows and report back on what is returned please.

I don't believe anything looks at the '\\server' field (it's really not relevant to anything in SMB3). The share of course has to match a real exported share.

My first inclination is that this is not a bug, but if you can show Windows behaving differently I'm willing to reconsider.
Comment 2 fouzhe 2023-04-25 17:10:57 UTC
(In reply to Jeremy Allison from comment #1)
Could you please give me an overview of the internal workflow of parsing the Tree field? Thanks for your time!
Comment 3 Jeremy Allison 2023-04-25 18:53:47 UTC
(In reply to fouzhe from comment #2)

No, sorry. That's why we give you the source code, so you can do these things yourself :-).