mirror of
https://github.com/TalAloni/SMBLibrary.git
synced 2025-05-29 16:59:50 +02:00
RPCPipeStream: Treat the bytes written to the pipe as a single message unit
This commit is contained in:
parent
86d0089a30
commit
e22423c8c1
1 changed files with 3 additions and 8 deletions
|
@ -42,14 +42,9 @@ namespace SMBLibrary.Services
|
||||||
|
|
||||||
public override void Write(byte[] buffer, int offset, int count)
|
public override void Write(byte[] buffer, int offset, int count)
|
||||||
{
|
{
|
||||||
int lengthOfPDUs = 0;
|
// [MC-CIFS] In message mode, the system treats the bytes read or written in each I/O operation to the pipe as a message unit.
|
||||||
do
|
RPCPDU rpcRequest = RPCPDU.GetPDU(buffer, offset);
|
||||||
{
|
ProcessRPCRequest(rpcRequest);
|
||||||
RPCPDU rpcRequest = RPCPDU.GetPDU(buffer, offset);
|
|
||||||
ProcessRPCRequest(rpcRequest);
|
|
||||||
lengthOfPDUs += rpcRequest.FragmentLength;
|
|
||||||
}
|
|
||||||
while (lengthOfPDUs < count);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ProcessRPCRequest(RPCPDU rpcRequest)
|
private void ProcessRPCRequest(RPCPDU rpcRequest)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue