Questions about PKCS11
843811Jul 6 2007 — edited Nov 17 2008Hi,Everybody,
when I try to access smartcard by pkcs11 ,I got a problem
the exception is :
--Exception in thread "main" java.security.ProviderException: SunPKCS11 requires configuration file argument
and my code :
public class Test {
public static void main(String[] args) {
String strPth = "C:/pkcs11.cfg";
Provider pkcs11Provider =
new sun.security.pkcs11.SunPKCS11(strPth);
Security.addProvider(pkcs11Provider);
System.out.println("success");
}
}
the pkcs11.cfg file :
name = SmartCard
library = C:/windows/system32/drivers/wdpkc.dll
Can anybody help me?
Thanks