| | | 1 | | using System; |
| | | 2 | | using Renci.SshNet.Common; |
| | | 3 | | |
| | | 4 | | namespace Renci.SshNet.Messages.Transport |
| | | 5 | | { |
| | | 6 | | /// <summary> |
| | | 7 | | /// Represents SSH_MSG_SERVICE_ACCEPT message. |
| | | 8 | | /// </summary> |
| | | 9 | | [Message("SSH_MSG_SERVICE_ACCEPT", MessageNumber)] |
| | | 10 | | public class ServiceAcceptMessage : Message |
| | | 11 | | { |
| | | 12 | | internal const byte MessageNumber = 6; |
| | | 13 | | |
| | | 14 | | /// <summary> |
| | | 15 | | /// Gets the name of the service. |
| | | 16 | | /// </summary> |
| | | 17 | | /// <value> |
| | | 18 | | /// The name of the service. |
| | | 19 | | /// </value> |
| | 1813 | 20 | | public ServiceName ServiceName { get; private set; } |
| | | 21 | | |
| | | 22 | | /// <summary> |
| | | 23 | | /// Called when type specific data need to be loaded. |
| | | 24 | | /// </summary> |
| | | 25 | | protected override void LoadData() |
| | 1813 | 26 | | { |
| | 1813 | 27 | | ServiceName = ReadBinary().ToServiceName(); |
| | 1813 | 28 | | } |
| | | 29 | | |
| | | 30 | | /// <summary> |
| | | 31 | | /// Called when type specific data need to be saved. |
| | | 32 | | /// </summary> |
| | | 33 | | protected override void SaveData() |
| | 0 | 34 | | { |
| | 0 | 35 | | throw new NotImplementedException(); |
| | | 36 | | } |
| | | 37 | | |
| | | 38 | | internal override void Process(Session session) |
| | 1813 | 39 | | { |
| | 1813 | 40 | | session.OnServiceAcceptReceived(this); |
| | 1813 | 41 | | } |
| | | 42 | | } |
| | | 43 | | } |