示例#1
0
        public OpenAndXResponse(byte[] buffer, int offset) : base(buffer, offset, false)
        {
            int parametersOffset = 4;

            FID           = LittleEndianReader.ReadUInt16(this.SMBParameters, ref parametersOffset);
            FileAttrs     = (SMBFileAttributes)LittleEndianReader.ReadUInt16(this.SMBParameters, ref parametersOffset);
            LastWriteTime = UTimeHelper.ReadNullableUTime(this.SMBParameters, ref parametersOffset);
            FileDataSize  = LittleEndianReader.ReadUInt32(this.SMBParameters, ref parametersOffset);
            AccessRights  = (AccessRights)LittleEndianReader.ReadUInt16(this.SMBParameters, ref parametersOffset);
            ResourceType  = (ResourceType)LittleEndianReader.ReadUInt16(this.SMBParameters, ref parametersOffset);
            NMPipeStatus  = NamedPipeStatus.Read(this.SMBParameters, ref parametersOffset);
            OpenResults   = OpenResults.Read(this.SMBParameters, ref parametersOffset);
            Reserved      = ByteReader.ReadBytes(this.SMBParameters, ref parametersOffset, 6);
        }
示例#2
0
        public NTCreateAndXResponse(byte[] buffer, int offset) : base(buffer, offset, false)
        {
            int parametersOffset = 4;

            OpLockLevel       = (OpLockLevel)ByteReader.ReadByte(this.SMBParameters, ref parametersOffset);
            FID               = LittleEndianReader.ReadUInt16(this.SMBParameters, ref parametersOffset);
            CreateDisposition = (CreateDisposition)LittleEndianReader.ReadUInt32(this.SMBParameters, ref parametersOffset);
            CreateTime        = SMB1Helper.ReadNullableFileTime(this.SMBParameters, ref parametersOffset);
            LastAccessTime    = SMB1Helper.ReadNullableFileTime(this.SMBParameters, ref parametersOffset);
            LastWriteTime     = SMB1Helper.ReadNullableFileTime(this.SMBParameters, ref parametersOffset);
            LastChangeTime    = SMB1Helper.ReadNullableFileTime(this.SMBParameters, ref parametersOffset);
            ExtFileAttributes = (ExtendedFileAttributes)LittleEndianReader.ReadUInt32(this.SMBParameters, ref parametersOffset);
            AllocationSize    = LittleEndianReader.ReadInt64(this.SMBParameters, ref parametersOffset);
            EndOfFile         = LittleEndianReader.ReadInt64(this.SMBParameters, ref parametersOffset);
            ResourceType      = (ResourceType)LittleEndianReader.ReadUInt16(this.SMBParameters, ref parametersOffset);
            NMPipeStatus      = NamedPipeStatus.Read(this.SMBParameters, ref parametersOffset);
            Directory         = (ByteReader.ReadByte(this.SMBParameters, ref parametersOffset) > 0);
        }