summaryrefslogtreecommitdiffstats
path: root/security/manager/ssl/nsIClientAuthRememberService.idl
blob: d59a8006202800cad8d73305e8a60955a70b83d7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 *
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#include "nsISupports.idl"

%{C++
#include "cert.h"
#define NS_CLIENTAUTHREMEMBERSERVICE_CONTRACTID "@mozilla.org/security/clientAuthRememberService;1"
%}

[ptr] native CERTCertificatePtr(CERTCertificate);
[ref] native const_OriginAttributesRef(const mozilla::OriginAttributes);

[scriptable, uuid(e92825af-7e81-4b5c-b412-8e1dd36d14fe)]
interface nsIClientAuthRememberRecord : nsISupports
{

  readonly attribute ACString asciiHost;

  readonly attribute ACString fingerprint;

  readonly attribute ACString dbKey;

  readonly attribute ACString entryKey;

};


[scriptable, uuid(1dbc6eb6-0972-4bdb-9dc4-acd0abf72369)]
interface nsIClientAuthRememberService : nsISupports
{

  [must_use]
  void forgetRememberedDecision(in ACString key);


  [must_use]
  Array<nsIClientAuthRememberRecord> getDecisions();

  [must_use, noscript]
  void rememberDecision(in ACString aHostName,
                        in const_OriginAttributesRef aOriginAttributes,
                        in CERTCertificatePtr aServerCert,
                        in CERTCertificatePtr aClientCert);

  [must_use, noscript]
  bool hasRememberedDecision(in ACString aHostName,
                             in const_OriginAttributesRef aOriginAttributes,
                             in CERTCertificatePtr aServerCert,
                             out ACString aCertDBKey);

  [must_use]
  void clearRememberedDecisions();

  [implicit_jscontext]
  void deleteDecisionsByHost(in ACString aHostName,
                             in jsval aOriginAttributes);

};