mirror of
https://github.com/TalAloni/SMBLibrary.git
synced 2025-08-01 21:41:49 +02:00
Return accept-completed at the final stage of a GSS authentication
This commit is contained in:
parent
8060b1df4d
commit
4ac83f6d97
2 changed files with 14 additions and 0 deletions
|
@ -58,5 +58,14 @@ namespace SMBLibrary.Authentication
|
|||
token.Tokens.Add(entry);
|
||||
return token.GetBytes();
|
||||
}
|
||||
|
||||
public static byte[] GetGSSTokenAcceptCompletedResponse()
|
||||
{
|
||||
SimpleProtectedNegotiationTokenResponse token = new SimpleProtectedNegotiationTokenResponse();
|
||||
TokenResponseEntry entry = new TokenResponseEntry();
|
||||
entry.NegState = NegState.AcceptCompleted;
|
||||
token.Tokens.Add(entry);
|
||||
return token.GetBytes();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -159,6 +159,11 @@ namespace SMBLibrary.Server.SMB1
|
|||
header.Status = NTStatus.STATUS_LOGON_FAILURE;
|
||||
return new ErrorResponse(CommandName.SMB_COM_SESSION_SETUP_ANDX);
|
||||
}
|
||||
|
||||
if (!isRawMessage)
|
||||
{
|
||||
response.SecurityBlob = GSSAPIHelper.GetGSSTokenAcceptCompletedResponse();
|
||||
}
|
||||
}
|
||||
response.NativeOS = String.Empty; // "Windows Server 2003 3790 Service Pack 2"
|
||||
response.NativeLanMan = String.Empty; // "Windows Server 2003 5.2"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue