Pkcs12Entry.cs 898 B

12345678910111213141516171819202122232425262728293031
  1. #if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
  2. #pragma warning disable
  3. using System.Collections.Generic;
  4. using Best.HTTP.SecureProtocol.Org.BouncyCastle.Asn1;
  5. using Best.HTTP.SecureProtocol.Org.BouncyCastle.Utilities.Collections;
  6. namespace Best.HTTP.SecureProtocol.Org.BouncyCastle.Pkcs
  7. {
  8. public abstract class Pkcs12Entry
  9. {
  10. private readonly IDictionary<DerObjectIdentifier, Asn1Encodable> m_attributes;
  11. protected internal Pkcs12Entry(IDictionary<DerObjectIdentifier, Asn1Encodable> attributes)
  12. {
  13. m_attributes = attributes;
  14. }
  15. public Asn1Encodable this[DerObjectIdentifier oid]
  16. {
  17. get { return CollectionUtilities.GetValueOrNull(m_attributes, oid); }
  18. }
  19. public IEnumerable<DerObjectIdentifier> BagAttributeKeys
  20. {
  21. get { return CollectionUtilities.Proxy(m_attributes.Keys); }
  22. }
  23. }
  24. }
  25. #pragma warning restore
  26. #endif