Wed, 31 Dec 2014 07:16:47 +0100
Revert simplistic fix pending revisit of Mozilla integration attempt.
michael@0 | 1 | /* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ |
michael@0 | 2 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 3 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 4 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
michael@0 | 5 | |
michael@0 | 6 | /* An interface for verifying signatures */ |
michael@0 | 7 | |
michael@0 | 8 | #include "nsISupports.idl" |
michael@0 | 9 | |
michael@0 | 10 | // NB: This isn't actually a principal at all. The naming is just historical. |
michael@0 | 11 | interface nsICertificatePrincipal; |
michael@0 | 12 | |
michael@0 | 13 | [uuid(22870b07-b5ef-481b-9f7f-d41787d4e617)] |
michael@0 | 14 | interface nsISignatureVerifier : nsISupports |
michael@0 | 15 | { |
michael@0 | 16 | /* Sig Verification Error Codes */ |
michael@0 | 17 | const long VERIFY_OK = 0; |
michael@0 | 18 | const long VERIFY_ERROR_UNKNOWN_CA = -8172; /* -8172 is the error code returned by PSM */ |
michael@0 | 19 | |
michael@0 | 20 | nsICertificatePrincipal verifySignature(in string aSignature, |
michael@0 | 21 | in unsigned long aSignatureLen, |
michael@0 | 22 | in string plaintext, |
michael@0 | 23 | in unsigned long plaintextLen, |
michael@0 | 24 | out long errorCode); |
michael@0 | 25 | }; |
michael@0 | 26 | |
michael@0 | 27 | |
michael@0 | 28 | %{C++ |
michael@0 | 29 | #define SIGNATURE_VERIFIER_CONTRACTID "@mozilla.org/psm;1" |
michael@0 | 30 | %} |