Use the final SessionSetup UID in SMB1 NTLMSSP authentication (fixes Tree Connect against Samba)#302
Open
Isleynorth wants to merge 1 commit into
Open
Conversation
Signed-off-by: Isleynorth <23055322+Isleynorth@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #301.
SMB1 NTLMSSP
smb1_authenticatestored theUIDfrom the challenge response and reused it as the session UID. Servers that assign a new UID in the finalSTATUS_SUCCESSresponse, such as Samba, then reject every following request, so theTree Connectfails withACCESS_DENIED. Windows keeps the same UID throughout, so this was invisible there.This stores the UID from the final response instead.
Verification
3.0.20-Debian(packet capture in SMB1 NTLMSSP authentication reuses the challenge UID instead of the final SessionSetup UID (breaks Tree Connect against Samba) #301): before, theTree Connectis sent with the challenge UID and rejected; after, it uses the final UID and succeeds.bundle exec rspec: 12334 examples, 0 failures. The updated#smb1_authenticatespec fails without this change and passes with it.