QueryFileExtendedAttributeInfo.cs 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /* Copyright (C) 2014 Tal Aloni <tal.aloni.il@gmail.com>. All rights reserved.
  2. *
  3. * You can redistribute this program and/or modify it under the terms of
  4. * the GNU Lesser Public License as published by the Free Software Foundation,
  5. * either version 3 of the License, or (at your option) any later version.
  6. */
  7. using System;
  8. using System.Collections.Generic;
  9. using System.Text;
  10. using Utilities;
  11. namespace SMBLibrary.SMB1
  12. {
  13. /// <summary>
  14. /// SMB_QUERY_FILE_EA_INFO
  15. /// </summary>
  16. public class QueryFileExtendedAttributeInfo : QueryInformation
  17. {
  18. public uint EASize;
  19. public QueryFileExtendedAttributeInfo()
  20. {
  21. }
  22. public QueryFileExtendedAttributeInfo(byte[] buffer, int offset)
  23. {
  24. EASize = LittleEndianConverter.ToUInt32(buffer, offset);
  25. }
  26. public override byte[] GetBytes()
  27. {
  28. return LittleEndianConverter.GetBytes(EASize);
  29. }
  30. public override QueryInformationLevel InformationLevel
  31. {
  32. get
  33. {
  34. return QueryInformationLevel.SMB_QUERY_FILE_EA_INFO;
  35. }
  36. }
  37. }
  38. }