Question

I'm trying to automate authentication with smart cards for a web app for which I'm required to use Selenium. When I create a new driver for Firefox, the browser doesn't have the PKCS#11 dll loaded for the smart card I'm using. Is there any way I can add this through a program/script of some sort? I've found a script for the same at http://support.gemalto.com/index.php?id=how_can_register_the_pkcs11, but it's for an older version of Firefox and is not supported anymore.

P.S: I'm using C# as well as PowerShell.
Was it helpful?

Solution

Have a look at modutil. Mozilla used to have a JS API, but its going to be removed on next releases.

OTHER TIPS

U can use modutil functions in your code and add to secmod.db database.

U can use function as NSS_Initialize(moduleSpec, "", "", NULL , 0); where modulespec is path to your secmod.db database. and then use SECMOD_AddNewModule function to add to database.

There's also https://github.com/open-eid/firefox-pkcs11-loader but this is also among endangered species, because of the removal of the used API-s.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top