TlsSrpIdentityManager.cs 1.1 KB

12345678910111213141516171819202122
  1. #if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
  2. #pragma warning disable
  3. using System;
  4. namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Tls
  5. {
  6. /// <summary>Base interface for an object that can return login parameters from an SRP identity.</summary>
  7. public interface TlsSrpIdentityManager
  8. {
  9. /// <summary>Lookup the <see cref="TlsSrpLoginParameters"/> corresponding to the specified identity.</summary>
  10. /// <remarks>
  11. /// NOTE: To avoid "identity probing", unknown identities SHOULD be handled as recommended in RFC 5054 2.5.1.3.
  12. /// <see cref="SimulatedTlsSrpIdentityManager"/> is provided for this purpose.
  13. /// </remarks>
  14. /// <param name="identity">the SRP identity sent by the connecting client.</param>
  15. /// <returns>the <see cref="TlsSrpLoginParameters"/> for the specified identity, or else 'simulated' parameters
  16. /// if the identity is not recognized. A null value is also allowed, but not recommended.</returns>
  17. TlsSrpLoginParameters GetLoginParameters(byte[] identity);
  18. }
  19. }
  20. #pragma warning restore
  21. #endif