nsIX509CertList.idl 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /* This Source Code Form is subject to the terms of the Mozilla Public
  2. * License, v. 2.0. If a copy of the MPL was not distributed with this
  3. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  4. #include "nsISupports.idl"
  5. interface nsISimpleEnumerator;
  6. interface nsIX509Cert;
  7. %{C++
  8. typedef struct CERTCertListStr CERTCertList;
  9. %}
  10. [ptr] native CERTCertListPtr(CERTCertList);
  11. [scriptable, uuid(ae74cda5-cd2f-473f-96f5-f0b7fff62c68)]
  12. interface nsIX509CertList : nsISupports {
  13. void addCert(in nsIX509Cert cert);
  14. void deleteCert(in nsIX509Cert cert);
  15. nsISimpleEnumerator getEnumerator();
  16. /**
  17. * Returns the raw, backing cert list.
  18. * Must be called only from functions where an nsNSSShutDownPreventionLock
  19. * has been acquired.
  20. */
  21. [notxpcom, noscript] CERTCertListPtr getRawCertList();
  22. /**
  23. * Test whether two certificate list instances represent the same
  24. * certificate list.
  25. *
  26. * @return Whether the certificate lists are equal
  27. */
  28. boolean equals(in nsIX509CertList other);
  29. };
  30. %{C++
  31. #define NS_X509CERTLIST_CID { /* 959fb165-6517-487f-ab9b-d8913be53197 */ \
  32. 0x959fb165, \
  33. 0x6517, \
  34. 0x487f, \
  35. {0xab, 0x9b, 0xd8, 0x91, 0x3b, 0xe5, 0x31, 0x97} \
  36. }
  37. #define NS_X509CERTLIST_CONTRACTID "@mozilla.org/security/x509certlist;1"
  38. %}