Pheox - Forums
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Top Downloads] Top Downloads   [Groups] Back to home page 
[Register] Register /  [Login] Login 

Problems with evaluation JCAPI and JAX-WS RSS feed
Forum Index » General Issues
Author Message
Trober

Visitor

Joined: Jul 27, 2007
Messages: 4
Offline
Hi,

We've been trying to set up JCAPI to use with JAX-WS.

However, when we try add the provider on the server side it crashes the virtual machine.

package testjcapi.service;

import javax.jws.WebService;
import com.pheox.jcapi.JCAPIProvider;
import testjcapi.TestJCAPIServiceSoap;

@WebService( endpointInterface="testjcapi.TestJCAPIServiceSoap")
public class TutorialService implements TestJCAPIServiceSoap {

public TutorialService() {
java.security.Security.insertProviderAt(new JCAPIProvider(), 2);
}

public String helloWorld() {
return "Hello World";
}
}


And we get this error back from Tomcat.

#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# EXCEPTION_FLT_STACK_CHECK (0xc0000092) at pc=0x00a77a19, pid=3784, tid=3144
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_06-b05 mixed mode)
# Problematic frame:
# j java.lang.ClassLoader$NativeLibrary.load(Ljava/lang/StringV+0
#
# An error report file with more information is saved as hs_err_pid3784.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#

We do have some issues on the client side too, but the server side error is simpler to explain.

Any ideas?
Trober

Visitor

Joined: Jul 27, 2007
Messages: 4
Offline
I also have that hs_err log file. Here's an excerpt from one of our client side crashes:

j java.lang.ClassLoader$NativeLibrary.load(Ljava/lang/StringV+0
j java.lang.ClassLoader.loadLibrary0(Ljava/lang/Class;Ljava/io/FileZ+300
j java.lang.ClassLoader.loadLibrary(Ljava/lang/Class;Ljava/lang/String;Z)V+48
j java.lang.Runtime.load0(Ljava/lang/Class;Ljava/lang/StringV+57
j java.lang.System.load(Ljava/lang/StringV+7
j com.pheox.jcapi.g.g()V+170
j com.pheox.jcapi.JCAPIProvider.init()V+16
j com.pheox.jcapi.JCAPIProvider.<clinit>()V+0
v ~StubRoutines::call_stub
V [jvm.dll+0x845a9]
V [jvm.dll+0xd9317]
V [jvm.dll+0x8447a]
V [jvm.dll+0x76f5d]
V [jvm.dll+0x75e58]
V [jvm.dll+0x7ef8b]
j testjcapi.envirohandler.ClientEnvironmentHandler$AutoPrivKeyFinder.findAutoPrivKey(Lcom/sun/xml/wss/impl/callback/SignatureKeyCallback$AliasPrivKeyCertRequestV+4
j testjcapi.envirohandler.ClientEnvironmentHandler.handle([Ljavax/security/auth/callback/CallbackV+176
j com.sun.xml.wss.impl.misc.DefaultSecurityEnvironmentImpl.getAliasPrivKeyCertRequest(Ljava/lang/StringLcom/sun/xml/wss/impl/callback/SignatureKeyCallback$AliasPrivKeyCertRequest;+34
j com.sun.xml.wss.impl.filter.SignatureFilter.process(Lcom/sun/xml/wss/impl/FilterProcessingContextV+349
j com.sun.xml.wss.impl.HarnessUtil.processWSSPolicy(Lcom/sun/xml/wss/impl/FilterProcessingContextV+16
j com.sun.xml.wss.impl.HarnessUtil.processDeep(Lcom/sun/xml/wss/impl/FilterProcessingContextV+11
j com.sun.xml.wss.impl.SecurityAnnotator.processMessagePolicy(Lcom/sun/xml/wss/impl/FilterProcessingContextV+70
j com.sun.xml.wss.impl.SecurityAnnotator.secureMessage(Lcom/sun/xml/wss/ProcessingContextV+257
j com.sun.xml.xwss.XWSSClientPipe.secureRequest(Lcom/sun/xml/ws/api/message/PacketLcom/sun/xml/ws/api/message/Packet;+233
j com.sun.xml.xwss.XWSSClientPipe.process(Lcom/sun/xml/ws/api/message/PacketLcom/sun/xml/ws/api/message/Packet;+32
j com.sun.xml.ws.api.pipe.helper.PipeAdapter.processRequest(Lcom/sun/xml/ws/api/message/PacketLcom/sun/xml/ws/api/pipe/NextAction;+6
j com.sun.xml.ws.api.pipe.Fiber.__doRun(Lcom/sun/xml/ws/api/pipe/TubeLcom/sun/xml/ws/api/pipe/Tube;+206
j com.sun.xml.ws.api.pipe.Fiber._doRun(Lcom/sun/xml/ws/api/pipe/TubeLcom/sun/xml/ws/api/pipe/Tube;+31
j com.sun.xml.ws.api.pipe.Fiber.doRun(Lcom/sun/xml/ws/api/pipe/TubeLcom/sun/xml/ws/api/pipe/Tube;+84
j com.sun.xml.ws.api.pipe.Fiber.runSync(Lcom/sun/xml/ws/api/pipe/Tube;Lcom/sun/xml/ws/api/message/PacketLcom/sun/xml/ws/api/message/Packet;+48
j com.sun.xml.ws.client.Stub.process(Lcom/sun/xml/ws/api/message/Packet;Lcom/sun/xml/ws/client/RequestContext;Lcom/sun/xml/ws/client/ResponseContextReceiverLcom/sun/xml/ws/api/message/Packet;+140
j com.sun.xml.ws.client.sei.SEIStub.doProcess(Lcom/sun/xml/ws/api/message/Packet;Lcom/sun/xml/ws/client/RequestContext;Lcom/sun/xml/ws/client/ResponseContextReceiverLcom/sun/xml/ws/api/message/Packet;+4
j com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(Ljava/lang/Object;[Ljava/lang/Object;Lcom/sun/xml/ws/client/RequestContext;Lcom/sun/xml/ws/client/ResponseContextReceiverLjava/lang/Object;+64
j com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(Ljava/lang/Object;[Ljava/lang/ObjectLjava/lang/Object;+14
j com.sun.xml.ws.client.sei.SEIStub.invoke(Ljava/lang/Object;Ljava/lang/reflect/Method;[Ljava/lang/ObjectLjava/lang/Object;+24
j $Proxy28.helloWorld()Ljava/lang/String;+9
j testjcapi.client.TutorialClient.main([Ljava/lang/StringV+126

tommy

Visitor

Joined: May 30, 2005
Messages: 148
Offline
Hi,

I've tested your web service example with Tomcat 6, JAX-WS 2.1.1, and Java 6 on Windows Vista without any problems.

Could you please answer the following questions:
1. Will your web service test program always crash the JVM, or are there any occasions when it turns out fine (indeterministic crashes)?
2. What happens if you load the JCAPI DLL by executing one of the JCAPI example programs from command line? Do they crash the JVM as well?
3. Can you use JCAPI in an applet via Tomcat without crashing the JVM?
4. Could you please send us your environment info to help us to locate your problem. Just call the method JCAPIUtil.getEnvironmentInfo() from within a Java app. For more info, see page 35 in the JCAPI User's Guide.

I've compiled and attached a special version of JCAPI for you to try as well. It will produce logging info when the jcapi.dll file is loaded into the JVM and store the result in file C:\JCAPI\jcapilog.txt (please make sure that the directory C:\JCAPI exists).
Please replace your current jcapi.jar file with the attached one and run your web service test again, and send us the content of "C:\JCAPI\jcapilog.txt".

Regards,
Tommy
 Filename JCAPI.jar [Disk] Download
 Description Patched jcapi.jar v1.2.2. Logging enabled.
 Filesize 447 Kbytes
 Downloaded:  31 time(s)

Anonymous


Thanks tommy!

I'll get to trying out those things you suggested and get back to you with more information when I can
Anonymous


It's trober again. I've been having trouble logging into the forum so I'll need to post anonymously.

Here's some background information to help answer the questions you asked.

1. We can get JCAPI to work correctly when run from a simple main line. When we involve JAX-WS it crashes consistantly. We believe the problem may be related to something happening with class loading carried out by JAX-WS, which in turn affects the operation of the JCAPI dll. We are still looking into this.

2. All the examples I have tried seem to work.

3. Sorry I didn't get around to trying an applet yet.

4. Here is the environment info is included below.

And regarding the jcapilog.txt, when we experience the VM crash, we are finding no log file is produced. (it is produced if we run the application from a mainline).

I can see that the DLL is extracted to the Documents and Settings Temp Directory though.


-------------- Environment info start --------------
JCAPI version: 1.2.2.0
JCAPI DLL version: 1.2.2.0

Certificate/system stores:
My
Root
Trust
CA
UserDS
TrustedPublisher
Disallowed
AuthRoot
TrustedPeople
ACRS
ADDRESSBOOK
REQUEST

Using cert entry store: ADDRESSBOOK
Using key entry store: My
Using intermediate cert store: CA
Using root cert store: Root
Using untrusted cert store: null

Available CSPs:
Gemplus GemSAFE Card CSP v1.0
Infineon SICRYPT Base Smart Card CSP
Microsoft Base Cryptographic Provider v1.0
Microsoft Base DSS and Diffie-Hellman Cryptographic Provider
Microsoft Base DSS Cryptographic Provider
Microsoft DH SChannel Cryptographic Provider
Microsoft Enhanced Cryptographic Provider v1.0
Microsoft Enhanced DSS and Diffie-Hellman Cryptographic Provider
Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)
Microsoft RSA SChannel Cryptographic Provider
Microsoft Strong Cryptographic Provider
Schlumberger Cryptographic Service Provider

Using CSP: Microsoft Enhanced Cryptographic Provider v1.0

Supported PKCS#11 CSPs:
FTSafe ePass2000 RSA Cryptographic Service Provider
eToken Base Cryptographic Provider
SmartTrust Cryptographic Service Provider
SI_CSP
SafeSign CSP Version 1.0
AR Base Cryptographic Provider
Athena ASECard Crypto CSP


User added PKCS#11 CSPs:

Loaded JCAPI plugins: No plugins loaded!
Registered JCE providers: SUN, version 1.5
JCAPI, version 1.22
SunRsaSign, version 1.5
SunJSSE, version 1.5
SunJCE, version 1.5
SunJGSS, version 1.0
SunSASL, version 1.5

java.version: 1.5.0_06
java.vendor: Sun Microsystems Inc.
java.vm.version: 1.5.0_06-b05
java.vm.vendor: Sun Microsystems Inc.
os.name: Windows XP
os.arch: x86
os.version: 5.1
java.library.path: C:\Program Files\Java\jdk1.5.0_06\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\Program Files\Support Tools\;C:\Program Files\Java\jdk1.5.0_06\bin;C:\Program Files\Oracle\bin\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Common Files\ABS\Bin;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\lotus\notes\;C:\Documents and Settings\robeto\Notes;C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE;C:\Documents and Settings\robeto\Notes;\\Corp\Peopledfs\robeto\Notes6;C:\Program Files\lotus\notes\;C:\Data\maven-2.0.6\bin
-------------- Environment info end --------------
tommy

Visitor

Joined: May 30, 2005
Messages: 148
Offline
Hi,

Hmm, when looking closer at your JVM dump:

# Java VM: Java HotSpot(TM) Client VM (1.5.0_06-b05 mixed mode)
# Problematic frame:
# j java.lang.ClassLoader$NativeLibrary.load(Ljava/lang/StringV+0

I see that the DLL fails to load completely i.e no native function in the JCAPI DLL is called at all. When an error (e.g a memory access violation) occurs inside the DLL it shall report that the error originated from within the DLL:

# Java VM: Java HotSpot(TM) Client VM (1.6.0_01-b06 mixed mode, sharing)
# Problematic frame:
# C [JCAPI.dll+0x70ffa]

This is also the reason why you won't get any log output from the DLL since it is never loaded.

Just a thought, how is JCAPI packaged and deployed with your web service? Is it part of your web service WAR file (and thus loaded through the same class loader as your web service context i.e from webapps\<your service>\WEB-INF\lib) or is it stored in a shared JAR file folder or in any endorsed directory? In my tests, I did package JCAPI within my test WAR file without any problems.

Another possible reason for the JVM crash might be due to the protection (obfuscation) mechanisms applied onto the evaluation version of JCAPI. When the DLL is loaded, it will decrypt and relocate the PE sections in the DLL file which in turn might have some ugly side effects in rare situations. One possible solution here would be for us to send you the commercial (unprotected) version of JCAPI for you to test with. In this case we can at least disregard the protection mechanism to be the cause to your problem. Please send a mail to Pheox support (including a reference to this forum post) and we'll send you the unprotected version for you to try with.

Regards,
Tommy
Trober

Visitor

Joined: Jul 27, 2007
Messages: 4
Offline
I'll spend some time moving the JCAPI.jar around and putting it in different locations to see if that helps.

We have had class loader issues with JAX-WS before. Initially we tried to deploy the JAX-WS libraries with each web service deployed to Tomcat, but we found this allowed only one web service to run on a server. We then moved those libraries into the shared lib area of Tomcat and the problem went away. Perhaps this sort of problem is affecting the operation of the JCAPI.jar?

At the moment JCAPI is being packaged with our Web Service. But we are also having some issues with simple java client which is calling the webservice.

So yeah, we'll do a bit more research today and see if we uncover any more information. If that goes nowhere, we may send you an e-mail and take you up on the offer for the non-eval version of JCAPI.

Thanks again for your assistance. We really appreciate it.
Trober

Visitor

Joined: Jul 27, 2007
Messages: 4
Offline
Thanks for sending us the updated jar. Initial tests show that it is working!

I'll post here if any other issues appear.
billhuber01

Visitor

Joined: Dec 10, 2008
Messages: 3
Offline
Hello,
And help! I have run into practically the same problem that's described here. I've installed an evaluation copy of JCAPI and wrote a simple Java test program to see how it worked and see that it does work. (Actually I hacked one of the sample programs.) The evaluation worked fine, allowing me to load and print out the contents of the certificates from a CAC smartcard. However, when I tried to include the identical code in our (fairly large) Java application, the JVM crashed in a way nearly identical to what was described in this post.

By way of environment, I'm running on Windows, using Eclipse with Java 1.5.0_10. I'll include the information from the JVM about the crash below. I am quite interested in the product, but only if I can get it to work. This is a blocking problem.

Thanks,
-Bill

#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# EXCEPTION_FLT_STACK_CHECK (0xc0000092) at pc=0x00b87ad9, pid=4752, tid=5616
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_10-b03 mixed mode)
# Problematic frame:
# j java.lang.ClassLoader$NativeLibrary.load(Ljava/lang/StringV+0
#

--------------- T H R E A D ---------------

Current thread (0x008236c0): JavaThread "main" [_thread_in_Java, id=5616]

siginfo: ExceptionCode=0xc0000092, ExceptionInformation=0x00000000 0x0006e01e

Registers:
EAX=0x02b9c0a0, EBX=0x00b87ad0, ECX=0x008236c0, EDX=0x00b8a0d2
ESP=0x0006f314, EBP=0x0006f330, ESI=0x22c7a9e8, EDI=0x0006f344
EIP=0x00b87ad9, EFLAGS=0x00210202

Top of Stack: (sp=0x0006f314)
0x0006f314: 0006f314 22c7a9e8 0006f344 22c7af80
0x0006f324: 00000000 22c7a9e8 0006f340 0006f374
0x0006f334: 00b829e3 00000000 00b873e9 02b9bf08
0x0006f344: 02b9bfb8 00000001 052fc328 00000001
0x0006f354: 052fcd58 0006f348 22b9b764 0006f3b4
0x0006f364: 22be7860 00000000 22b9b7f0 0006f3b0
0x0006f374: 0006f3d4 00b82b3b 00000000 00000000
0x0006f384: 00000000 00000000 02b9bfb8 00000000

Instructions: (pc=0x00b87ad9)
0x00b87ac9: 00 00 00 ff ff ff ff 8b 75 e8 8b 7d ec 8b 65 e4
0x00b87ad9: dd c7 dd c6 dd c5 dd c4 dd c3 dd c2 dd c1 dd c0


Stack: [0x00030000,0x00070000), sp=0x0006f314, free space=252k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
j java.lang.ClassLoader$NativeLibrary.load(Ljava/lang/StringV+0
j java.lang.ClassLoader.loadLibrary0(Ljava/lang/Class;Ljava/io/FileZ+300
j java.lang.ClassLoader.loadLibrary(Ljava/lang/Class;Ljava/lang/String;Z)V+48
j java.lang.Runtime.load0(Ljava/lang/Class;Ljava/lang/StringV+57
j java.lang.System.load(Ljava/lang/StringV+7
j com.pheox.jcapi.g.g()V+170
j com.pheox.jcapi.JCAPIProvider.init()V+16
j com.pheox.jcapi.JCAPIProvider.<clinit>()V+0
v ~StubRoutines::call_stub
V [jvm.dll+0x8757c]
V [jvm.dll+0xde804]
V [jvm.dll+0x8744d]
V [jvm.dll+0x79b74]
V [jvm.dll+0x78a40]
V [jvm.dll+0x81f44]
j com.bladelogic.auth.client.CACUserCredential.<init>(Lcom/bladelogic/session/common/BlSite;Ljava/lang/String;Lcom/bladelogic/security/cert/ClientTrustStoreV+116
j com.bladelogic.client.BRProfile.createCACUserCredential(Lcom/bladelogic/session/common/BlSiteLcom/bladelogic/auth/client/CACUserCredential;+16
j com.bladelogic.client.cm.login.protocol.CACUserCredentialPanel.getUserCredential()Lcom/bladelogic/auth/client/UserCredential;+3
j com.bladelogic.client.cm.login.protocol.CACUserCredentialPanel.initLayout()V+12
j com.bladelogic.client.cm.login.protocol.CACUserCredentialPanel.<init>(Ljavax/swing/JPanel;Ljavax/swing/JComponent;Lcom/bladelogic/client/nodes/login/ServiceProfileNodeV+8
j com.bladelogic.client.cm.login.protocol.UserCredentialPanelFactory.createUserCredentialPanel(Lcom/bladelogic/client/nodes/login/ServiceProfileNode;Ljavax/swing/JPanel;Ljavax/swing/JComponentLcom/bladelogic/client/cm/login/protocol/AbstractUserCredentialPanel;+150
j com.bladelogic.client.cm.login.LoginPanel.layoutPanel()V+178
j com.bladelogic.client.cm.login.LoginPanel.resetlayout(Z)V+53
j com.bladelogic.client.cm.login.LoginPanel.<init>(Lcom/bladelogic/shared/option/OptionsManagerV+20
j com.bladelogic.client.cm.login.LoginManager.doLogin(Lcom/bladelogic/shared/option/OptionsManager;Lcom/bladelogic/client/cm/SplashScreen;Ljava/lang/String;ILjava/util/LocaleLcom/bladelogic/client/cm/LoginResult;+43
j com.bladelogic.client.cm.login.GuiLoginOperations.obtainSessionCredential()Lcom/bladelogic/session/common/SessionCredential;+23
j com.bladelogic.session.client.SessionLoginManager.connect()V+9
j com.bladelogic.session.client.SessionLoginManager.login()V+5
j com.bladelogic.client.cm.BRMain.main([Ljava/lang/StringV+180
v ~StubRoutines::call_stub
V [jvm.dll+0x8757c]
V [jvm.dll+0xde804]
V [jvm.dll+0x8744d]
V [jvm.dll+0x8e4a9]
C [javaw.exe+0x14c5]
C [javaw.exe+0x3151]
C [kernel32.dll+0x16fd7]


--------------- P R O C E S S ---------------

Java Threads: ( => current thread )
0x00903220 JavaThread "TimerQueue" daemon [_thread_blocked, id=6044]
0x008ace70 JavaThread "Thread-2" [_thread_blocked, id=6136]
0x00888400 JavaThread "AWT-EventQueue-0" [_thread_blocked, id=5720]
0x0087e220 JavaThread "AWT-Windows" daemon [_thread_in_native, id=5772]
0x0087ea90 JavaThread "AWT-Shutdown" [_thread_blocked, id=2384]
0x0087cad0 JavaThread "Java2D Disposer" daemon [_thread_blocked, id=5704]
0x0083b260 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=4380]
0x0083aa70 JavaThread "CompilerThread0" daemon [_thread_blocked, id=5204]
0x00838420 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=5784]
0x00836140 JavaThread "JDWP Command Reader" daemon [_thread_in_native, id=5756]
0x00836e60 JavaThread "JDWP Event Helper Thread" daemon [_thread_blocked, id=4732]
0x00834960 JavaThread "JDWP Transport Listener: dt_socket" daemon [_thread_blocked, id=4156]
0x0082da70 JavaThread "Finalizer" daemon [_thread_blocked, id=5372]
0x0082c800 JavaThread "Reference Handler" daemon [_thread_blocked, id=5104]
=>0x008236c0 JavaThread "main" [_thread_in_Java, id=5616]

Other Threads:
0x0082bae0 VMThread [id=4408]
0x0083de00 WatcherThread [id=1572]

VM state:not at safepoint (normal execution)

VM Mutex/Monitor currently owned by a thread: None

Heap
def new generation total 768K, used 168K [0x02b80000, 0x02c50000, 0x052e0000)
eden
[error occurred during error reporting, step 190, id 0xc0000092]

Dynamic libraries:
0x00400000 - 0x0040d000 C:\Program Files\Java\jdk1.5.0_10\bin\javaw.exe
0x7c900000 - 0x7c9b0000 C:\WINDOWS\system32\ntdll.dll
0x7c800000 - 0x7c8f5000 C:\WINDOWS\system32\kernel32.dll
0x77dd0000 - 0x77e6b000 C:\WINDOWS\system32\ADVAPI32.dll
0x77e70000 - 0x77f01000 C:\WINDOWS\system32\RPCRT4.dll
0x7e410000 - 0x7e4a0000 C:\WINDOWS\system32\USER32.dll
0x77f10000 - 0x77f57000 C:\WINDOWS\system32\GDI32.dll
0x77c10000 - 0x77c68000 C:\WINDOWS\system32\MSVCRT.dll
0x76390000 - 0x763ad000 C:\WINDOWS\system32\IMM32.DLL
0x629c0000 - 0x629c9000 C:\WINDOWS\system32\LPK.DLL
0x74d90000 - 0x74dfb000 C:\WINDOWS\system32\USP10.dll
0x6d730000 - 0x6d8cc000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\client\jvm.dll
0x76b40000 - 0x76b6d000 C:\WINDOWS\system32\WINMM.dll
0x6d2f0000 - 0x6d2f8000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\hpi.dll
0x76bf0000 - 0x76bfb000 C:\WINDOWS\system32\PSAPI.DLL
0x6d3f0000 - 0x6d425000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\jdwp.dll
0x6d700000 - 0x6d70c000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\verify.dll
0x6d370000 - 0x6d38d000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\java.dll
0x6d720000 - 0x6d72f000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\zip.dll
0x6d290000 - 0x6d297000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\dt_socket.dll
0x71ab0000 - 0x71ac7000 C:\WINDOWS\system32\WS2_32.dll
0x71aa0000 - 0x71aa8000 C:\WINDOWS\system32\WS2HELP.dll
0x71a50000 - 0x71a8f000 C:\WINDOWS\System32\mswsock.dll
0x76f20000 - 0x76f47000 C:\WINDOWS\system32\DNSAPI.dll
0x76fb0000 - 0x76fb8000 C:\WINDOWS\System32\winrnr.dll
0x76f60000 - 0x76f8c000 C:\WINDOWS\system32\WLDAP32.dll
0x76fc0000 - 0x76fc6000 C:\WINDOWS\system32\rasadhlp.dll
0x662b0000 - 0x66308000 C:\WINDOWS\system32\hnetcfg.dll
0x71a90000 - 0x71a98000 C:\WINDOWS\System32\wshtcpip.dll
0x6d070000 - 0x6d1d9000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\awt.dll
0x73000000 - 0x73026000 C:\WINDOWS\system32\WINSPOOL.DRV
0x774e0000 - 0x7761d000 C:\WINDOWS\system32\ole32.dll
0x73760000 - 0x737a9000 C:\WINDOWS\system32\ddraw.dll
0x73bc0000 - 0x73bc6000 C:\WINDOWS\system32\DCIMAN32.dll
0x6d2b0000 - 0x6d2f0000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\fontmanager.dll
0x755c0000 - 0x755ee000 C:\WINDOWS\system32\msctfime.ime
0x7c9c0000 - 0x7d1d5000 C:\WINDOWS\system32\shell32.dll
0x77f60000 - 0x77fd6000 C:\WINDOWS\system32\SHLWAPI.dll
0x773d0000 - 0x774d3000 C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2982_x-ww_ac3f9c03\comctl32.dll
0x5d090000 - 0x5d12a000 C:\WINDOWS\system32\comctl32.dll
0x6d530000 - 0x6d543000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\net.dll
0x6d550000 - 0x6d559000 C:\Program Files\Java\jdk1.5.0_10\jre\bin\nio.dll
0x77a80000 - 0x77b14000 C:\WINDOWS\system32\crypt32.dll
0x77b20000 - 0x77b32000 C:\WINDOWS\system32\MSASN1.dll
0x77c00000 - 0x77c08000 C:\WINDOWS\system32\version.dll
0x71ad0000 - 0x71ad9000 C:\WINDOWS\system32\wsock32.dll

VM Arguments:
jvm_args: -Dblx.cmrootdir=C:\workspaces\7_5_bugfix_cac/om/build/classes -Xmx512m -agentlib:jdwp=transport=dt_socket,suspend=y,address=localhost:2823
java_command: com.bladelogic.client.cm.BRMain
Launcher Type: SUN_STANDARD

Environment Variables:
JAVA_HOME=C:\Program Files\Java\jdk1.5.0_10
PATH=C:\Program Files\Java\jdk1.5.0_10\jre\bin;C:\workspaces\7_5_bugfix_cac\om\bin\Release;C:\workspaces\7_5_bugfix_cac\3rdparty\bladelogic\Win32
USERNAME=BHUBER
OS=Windows_NT
PROCESSOR_IDENTIFIER=x86 Family 6 Model 23 Stepping 6, GenuineIntel



--------------- S Y S T E M ---------------

OS: Windows XP Build 2600 Service Pack 2

CPU:total 1 (cores per cpu 2, threads per core 1) family 6 model 7 stepping 6, cmov, cx8, fxsr, mmx, sse, sse2

Memory: 4k page, physical 2097151k(2097151k free), swap 4194303k(3995076k free)

vm_info: Java HotSpot(TM) Client VM (1.5.0_10-b03) for windows-x86, built on Nov 9 2006 13:13:34 by "java_re" with MS VC++ 6.0



tommy

Visitor

Joined: May 30, 2005
Messages: 148
Offline
Hi Bill,

Yes, it seems to be exactly the same problem as reported earlier in this forum thread.
The possibility that our third party provided obfuscation solution causes this problem is quite large so to say
We have recently received an upgrade of this software, but not tested it yet. I will, tomorrow, create a new JCAPI DLL file using the most recent version of the obfuscation software for you to try with. I will also fix a non obfuscated dito. Meanwhile, could you please send your email address to support@pheox.com, please include a link to this thread. I will send you the new JCAPI JAR files asap. Please report your findings back to this thread.

Thanks.

Regards,
Tommy
billhuber01

Visitor

Joined: Dec 10, 2008
Messages: 3
Offline
Hi Tommy,

Thanks for your speedy reply with the JCAPI jar file. The good news is that it did get me past the problem I reported previously. The JVM crash is gone. The bad news is that I stumbled into the same problem that others have reported in 2 threads. The problem manifests itself as an SSLHandshakeException with the text "Error signing certificate verify". As near as I can tell from reading the other posts (and given my newness to this all), it seems that the problem has to do with trying to access hardware that does not allow the private key to be exported.

Backing up to try to give some perspective on the problem, basically all I was trying to do was to access a smart card (a CAC) from Java in order to use the certs on the card for an SSL handshake. The original thinking was that we would use the Sun PKCS#11 provider "framework" which would utilize the ActivClient middleware from ActivIdentity. I couldn't get this to work and we are waiting for a response from ActivIdentity.

In the mean time, I learned of the SunMSCAPI in Java 6. I tried this in a simple test program and it seemed to work OK in at least accessing the CAC hardware. However, it's not clear that we can use Java 6 (yet) in our current release of the product. So, I kept on looking around on the web and that's when I read about JCAPI. It seemed like a nice end-run around the PKCS#11 requirement. A test program worked, so I was hopeful (of course the test program wasn't trying to do an SSL handshake). However, when I put JCAPI in our app. (that does the handshake) , I ran into the problem I described yesterday.

With the new fix, I was able to get around the JVM crash problem. However, I've now run into the problem with supporting hardware, which doesn't export the private key. From reading the descriptions, it sounds like you need to have a working PKCS#11 provider, which is what I was having trouble with in the first place. Perhaps ActivIdentity provides this and I just haven't heard/discovered that yet.

In the mean time, I'm still wondering how I can access the CAC smartcard hardware from Java. This doesn't seem like that odd of a requirement. Any ideas about how this can be done with any mixture of JCAPI and ActivIdentity ActivClient? Any other ideas? Thanks for your time.

Regards,
-Bill
tommy

Visitor

Joined: May 30, 2005
Messages: 148
Offline
Hi Bill,

Aha, yes, I see your problem.
The problem from a JCAPI perspective is that SSL is managed outside JCAPI i.e. through JSSE which in turns relies on the fact that a private key is exportable. Unfortunately we can't provide a solution for that unless we either hack the JSSE implementation or provide our own SSL stack.
Support for this will be implemented in JCAPI v2.0 with Java 6. We have though currently no plans on fixing this for earlier Java versions unless there is a very good reason for doing so, since we must in that case make large changes into code/products which are outside the scope of the JCAPI product. There is currently no incentive for such a massive work so to say since the customer base is fairly small for niched products like JCAPI, even though it's a good product

I hope you do find another solution that suit your needs and solve your problems.

Regards,
Tommy
billhuber01

Visitor

Joined: Dec 10, 2008
Messages: 3
Offline
Hi Tommy,

Thanks very much for spending time on this and giving me (and others) your feedback. Just so I'm completely clear about our options, do you have any idea when JCAPI v2.0 will become available (even in some pre-release form)? Thanks.

Regards,
-Bill
tommy

Visitor

Joined: May 30, 2005
Messages: 148
Offline
Hi Bill,

JCAPI v2 should have been released this year, but have been temporarily postponed since focus have been put on other projects instead. Due to its nished nature, JCAPI is currently too small to carry its own full time development costs. Well, it's pure business in the end so to say.
But a a good guesstimate is around July-August 2009.

Of course, if time is of most importance, then your company is welcome to contact Pheox for consultancy service. I'm rather sure that some kind of satisfactory solution can be arranged to solve your specific problem within a reasonable time frame.

Regards,
Tommy
 
Forum Index » General Issues
Go to:   
Mobile view
Powered by JForum 2.8.3 © 2023 JForum Team • Maintained by Andowson Chang and Ulf Dittmer