1234567891011121314151617181920212223242526272829303132333435363738394041 |
- using System;
- using System.Collections.Generic;
- using System.Text;
- using Utilities;
- namespace SMBLibrary
- {
-
-
-
- public class RequestGetDfsReferral
- {
- public ushort MaxReferralLevel;
- public string RequestFileName;
- public RequestGetDfsReferral()
- {
- }
- public RequestGetDfsReferral(byte[] buffer)
- {
- MaxReferralLevel = LittleEndianConverter.ToUInt16(buffer, 0);
- RequestFileName = ByteReader.ReadNullTerminatedUTF16String(buffer, 2);
- }
- public byte[] GetBytes()
- {
- int length = 2 + RequestFileName.Length * 2 + 2;
- byte[] buffer = new byte[length];
- LittleEndianWriter.WriteUInt16(buffer, 0, MaxReferralLevel);
- ByteWriter.WriteUTF16String(buffer, 2, RequestFileName);
- return buffer;
- }
- }
- }
|