PositiveSessionResponsePacket.cs 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /* Copyright (C) 2014-2017 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.NetBios
  11. {
  12. /// <summary>
  13. /// [RFC 1002] 4.3.3. POSITIVE SESSION RESPONSE PACKET
  14. /// </summary>
  15. public class PositiveSessionResponsePacket : SessionPacket
  16. {
  17. public PositiveSessionResponsePacket() : base()
  18. {
  19. this.Type = SessionPacketTypeName.PositiveSessionResponse;
  20. }
  21. public PositiveSessionResponsePacket(byte[] buffer, int offset) : base(buffer, offset)
  22. {
  23. }
  24. public override byte[] GetBytes()
  25. {
  26. this.Trailer = new byte[0];
  27. return base.GetBytes();
  28. }
  29. public override int Length
  30. {
  31. get
  32. {
  33. return HeaderLength;
  34. }
  35. }
  36. }
  37. }