QueryFileEaInfo.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  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 Utilities;
  10. namespace SMBLibrary.SMB1
  11. {
  12. /// <summary>
  13. /// SMB_QUERY_FILE_EA_INFO
  14. /// </summary>
  15. public class QueryFileEaInfo : QueryInformation
  16. {
  17. public uint EaSize;
  18. public QueryFileEaInfo()
  19. {
  20. }
  21. public QueryFileEaInfo(byte[] buffer, int offset)
  22. {
  23. EaSize = LittleEndianConverter.ToUInt32(buffer, offset);
  24. }
  25. public override byte[] GetBytes()
  26. {
  27. return LittleEndianConverter.GetBytes(EaSize);
  28. }
  29. public override QueryInformationLevel InformationLevel
  30. {
  31. get
  32. {
  33. return QueryInformationLevel.SMB_QUERY_FILE_EA_INFO;
  34. }
  35. }
  36. }
  37. }