security/manager/ssl/src/nsPKCS11Slot.h

Wed, 31 Dec 2014 07:16:47 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:16:47 +0100
branch
TOR_BUG_9701
changeset 3
141e0f1194b1
permissions
-rw-r--r--

Revert simplistic fix pending revisit of Mozilla integration attempt.

michael@0 1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
michael@0 2 *
michael@0 3 * This Source Code Form is subject to the terms of the Mozilla Public
michael@0 4 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 6
michael@0 7 #ifndef __NS_PKCS11SLOT_H__
michael@0 8 #define __NS_PKCS11SLOT_H__
michael@0 9
michael@0 10 #include "nsISupports.h"
michael@0 11 #include "nsIPKCS11Slot.h"
michael@0 12 #include "nsIPKCS11Module.h"
michael@0 13 #include "nsIPKCS11ModuleDB.h"
michael@0 14 #include "nsICryptoFIPSInfo.h"
michael@0 15 #include "nsString.h"
michael@0 16 #include "pk11func.h"
michael@0 17 #include "nsNSSShutDown.h"
michael@0 18
michael@0 19 class nsPKCS11Slot : public nsIPKCS11Slot,
michael@0 20 public nsNSSShutDownObject
michael@0 21 {
michael@0 22 public:
michael@0 23 NS_DECL_ISUPPORTS
michael@0 24 NS_DECL_NSIPKCS11SLOT
michael@0 25
michael@0 26 nsPKCS11Slot(PK11SlotInfo *slot);
michael@0 27 virtual ~nsPKCS11Slot();
michael@0 28
michael@0 29 private:
michael@0 30
michael@0 31 PK11SlotInfo *mSlot;
michael@0 32 nsString mSlotDesc, mSlotManID, mSlotHWVersion, mSlotFWVersion;
michael@0 33 int mSeries;
michael@0 34
michael@0 35 virtual void virtualDestroyNSSReference();
michael@0 36 void destructorSafeDestroyNSSReference();
michael@0 37 void refreshSlotInfo();
michael@0 38 };
michael@0 39
michael@0 40 class nsPKCS11Module : public nsIPKCS11Module,
michael@0 41 public nsNSSShutDownObject
michael@0 42 {
michael@0 43 public:
michael@0 44 NS_DECL_ISUPPORTS
michael@0 45 NS_DECL_NSIPKCS11MODULE
michael@0 46
michael@0 47 nsPKCS11Module(SECMODModule *module);
michael@0 48 virtual ~nsPKCS11Module();
michael@0 49
michael@0 50 private:
michael@0 51 SECMODModule *mModule;
michael@0 52
michael@0 53 virtual void virtualDestroyNSSReference();
michael@0 54 void destructorSafeDestroyNSSReference();
michael@0 55 };
michael@0 56
michael@0 57 class nsPKCS11ModuleDB : public nsIPKCS11ModuleDB,
michael@0 58 public nsICryptoFIPSInfo
michael@0 59 {
michael@0 60 public:
michael@0 61 NS_DECL_ISUPPORTS
michael@0 62 NS_DECL_NSIPKCS11MODULEDB
michael@0 63 NS_DECL_NSICRYPTOFIPSINFO
michael@0 64
michael@0 65 nsPKCS11ModuleDB();
michael@0 66 virtual ~nsPKCS11ModuleDB();
michael@0 67 /* additional members */
michael@0 68 };
michael@0 69
michael@0 70 #define NS_PKCS11MODULEDB_CID \
michael@0 71 { 0xff9fbcd7, 0x9517, 0x4334, \
michael@0 72 { 0xb9, 0x7a, 0xce, 0xed, 0x78, 0x90, 0x99, 0x74 }}
michael@0 73
michael@0 74 #endif

mercurial