AuthenticationPrompt.cs 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. namespace Renci.SshNet.Common
  2. {
  3. /// <summary>
  4. /// Provides prompt information when <see cref="Renci.SshNet.KeyboardInteractiveConnectionInfo.AuthenticationPrompt"/> is raised
  5. /// </summary>
  6. public class AuthenticationPrompt
  7. {
  8. /// <summary>
  9. /// Gets the prompt sequence id.
  10. /// </summary>
  11. public int Id { get; private set; }
  12. /// <summary>
  13. /// Gets or sets a value indicating whether the user input should be echoed as characters are typed.
  14. /// </summary>
  15. /// <value>
  16. /// <c>true</c> if the user input should be echoed as characters are typed; otherwise, <c>false</c>.
  17. /// </value>
  18. public bool IsEchoed { get; private set; }
  19. /// <summary>
  20. /// Gets server information request.
  21. /// </summary>
  22. public string Request { get; private set; }
  23. /// <summary>
  24. /// Gets or sets server information response.
  25. /// </summary>
  26. /// <value>
  27. /// The response.
  28. /// </value>
  29. public string Response { get; set; }
  30. /// <summary>
  31. /// Initializes a new instance of the <see cref="AuthenticationPrompt"/> class.
  32. /// </summary>
  33. /// <param name="id">The sequence id.</param>
  34. /// <param name="isEchoed">if set to <c>true</c> the user input should be echoed.</param>
  35. /// <param name="request">The request.</param>
  36. public AuthenticationPrompt(int id, bool isEchoed, string request)
  37. {
  38. this.Id = id;
  39. this.IsEchoed = isEchoed;
  40. this.Request = request;
  41. }
  42. }
  43. }