DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Implementation

Mercurial (4b332005f925)

VCS Links

Line Code
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
/* 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/. */

#ifndef nsKeyModule_h
#define nsKeyModule_h

#include "ScopedNSSTypes.h"
#include "nsIKeyModule.h"
#include "pk11pub.h"

#define NS_KEYMODULEOBJECT_CID                       \
  {                                                  \
    0x9d383ddd, 0x6856, 0x4187, {                    \
      0x84, 0x85, 0xf3, 0x61, 0x95, 0xb2, 0x9a, 0x0e \
    }                                                \
  }
#define NS_KEYMODULEOBJECT_CONTRACTID "@mozilla.org/security/keyobject;1"

#define NS_KEYMODULEOBJECTFACTORY_CID                \
  {                                                  \
    0x2a35dd47, 0xb026, 0x4e8d, {                    \
      0xb6, 0xb7, 0x57, 0x40, 0xf6, 0x1a, 0xb9, 0x02 \
    }                                                \
  }
#define NS_KEYMODULEOBJECTFACTORY_CONTRACTID \
  "@mozilla.org/security/keyobjectfactory;1"

class nsKeyObject final : public nsIKeyObject {
 public:
  nsKeyObject();

  NS_DECL_ISUPPORTS
  NS_DECL_NSIKEYOBJECT

 private:
  ~nsKeyObject() {}

  // Disallow copy constructor
  nsKeyObject(nsKeyObject&);

  mozilla::UniquePK11SymKey mSymKey;
};

class nsKeyObjectFactory final : public nsIKeyObjectFactory {
 public:
  nsKeyObjectFactory() {}

  NS_DECL_THREADSAFE_ISUPPORTS
  NS_DECL_NSIKEYOBJECTFACTORY

 private:
  ~nsKeyObjectFactory() {}

  // Disallow copy constructor
  nsKeyObjectFactory(nsKeyObjectFactory&);
};

#endif  // nsKeyModule_h