PKCS11 Module Installation

  • Revision slug: PKCS11_Module_Installation
  • Revision title: PKCS11 Module Installation
  • Revision id: 134046
  • Created:
  • Creator: Benjamin Smedberg
  • Is current revision? Yes
  • Comment 204 words added, 3321 words removed; page display name changed to 'PKCS11 Module Installation'

Revision Content

PKCS11 modules are external modules which provide access to smart-card readers, biometric security devices, or external certificate stores. There are two methods for installing PKCS11 modules into Firefox. Users can use the preferences dialog to install or remove PKCS11 module. Extensions can programmatically manage PKCS11 modules using the nsIPKCS11 programming interface.

The information in this article is specific to Firefox 3.5 and newer. Older versions of Firefox may support the window.pkcs11 property for installing PKCS11 modules.

Using the Firefox Preferences Dialog to Install PKCS11 Modules

  1. Save the PKCS11 module to a permanent location on your local computer
  2. Open the Firefox preferences dialog. Choose "Advanced" > "Encryption" > "Security Devices"
  3. Choose "Load"
  4. Enter a name for the security module, such as "My Client Database". NOTE: there is currently a bug in Firefox where international characters may cause problems.
  5. Choose "Browse..." to find the location of the PKCS11 module on your local computer, and choose "OK" when done.

Installing PKCS11 Modules Using nsIPKCS11

 Extensions can use the nsIPKCS11 interface {{ source("security/manager/ssl/public/nsIPKCS11.idl") }} to install PKCS11 modules:

const nsIPKCS11 = Components.interfaces.nsIPKCS11;
const nsPKCS11ContractID = "@mozilla.org/security/pkcs11;1";


var PKCS11 = Components.classes[nsPKCS11ContractID].getService(nsIPKCS11);
PKCS11.addModule("Custom Module Name", "/path/to/module.dll");

 

Revision Source

<p><a class="internal" href="/en/PKCS11" title="en/PKCS11">PKCS11</a> modules are external modules which provide access to smart-card readers, biometric security devices, or external certificate stores. There are two methods for installing PKCS11 modules into Firefox. Users can use the preferences dialog to install or remove PKCS11 module. Extensions can programmatically manage PKCS11 modules using the nsIPKCS11 programming interface.</p>
<div class="note">The information in this article is specific to Firefox 3.5 and newer. Older versions of Firefox may support the <a class="internal" href="/en/DOM/window.pkcs11" title="en/DOM/window.pkcs11">window.pkcs11</a> property for installing PKCS11 modules.</div>
<h3 id="Using_the_Firefox_Preferences_Dialog_to_Install_PKCS11_Modules">Using the Firefox Preferences Dialog to Install PKCS11 Modules</h3>
<ol> <li>Save the PKCS11 module to a permanent location on your local computer</li> <li>Open the Firefox preferences dialog. Choose "Advanced" &gt; "Encryption" &gt; "Security Devices"</li> <li>Choose "Load"</li> <li>Enter a name for the security module, such as "My Client Database". NOTE: there is currently a bug in Firefox where international characters may cause problems.</li> <li>Choose "Browse..." to find the location of the PKCS11 module on your local computer, and choose "OK" when done.</li>
</ol>
<h3 id="Installing_PKCS11_Modules_Using_nsIPKCS11_">Installing PKCS11 Modules Using nsIPKCS11 </h3>
<p> Extensions can use the nsIPKCS11 interface {{ source("security/manager/ssl/public/nsIPKCS11.idl") }} to install PKCS11 modules:</p>
<pre>const nsIPKCS11 = Components.interfaces.nsIPKCS11;
const nsPKCS11ContractID = "@mozilla.org/security/pkcs11;1";


var PKCS11 = Components.classes[nsPKCS11ContractID].getService(nsIPKCS11);
PKCS11.addModule("Custom Module Name", "/path/to/module.dll");
</pre>
<p> </p>
Revert to this revision