score:1
Accepted answer
ok, so, the bug was that the sun ldap library can not load the jks file from the jar. the workaround was to extract the file from the car to tomcat temp dir, then setting this "real" file as javax.net.ssl.truststore property.
string tmpdir = system.getenv("catalina_tmpdir");
if(tmpdir == null)
tmpdir = system.getenv("catalina_home") + "/temp";
final string tmpjksfile = tmpdir + "/ldap.jks";
url ts = getclass().getresource("/ldap.jks");
try {
inputstream in = new bufferedinputstream(ts.openstream());
outputstream out = new bufferedoutputstream(new fileoutputstream(tmpjksfile));
ioutils.copy(in, out);
out.flush();
out.close();
in.close();
} catch (ioexception eio) {
/* your logging */
}
system.setproperty(truststoreproperty, tmpjksfile);
Source: stackoverflow.com
Related Query
- Debugging a custom tomcat realm
- Remote debugging Tomcat with Eclipse
- debugging java application deployed in tomcat
- eclipse: remote debugging a tomcat server behind a firewall
- eclipse + maven + tomcat debugging
- Debugging a tomcat project in Eclipse 3.4.2
- Amazon EC2- Tomcat remote debugging issue
- Remote Debugging with JPDA won't connect to Tomcat through eclipse when using Docker-Compose
- Tomcat 7 remote debugging on EC2
- Debugging Tomcat Running in Vagrant using Port Forwarding
- Eclipse 3.4 + Tomcat 6.0 + Remote Debugging with Console Output
- Remote debugging on Tomcat with Eclipse
- How to fix eclipse spinning CPU while debugging on tomcat server
- Debugging remote application in Eclipse using Tomcat
- Tomcat crashes while remote debugging
- Debugging a Spring MVC application running on Tomcat
- Can't find source for specific jar/class when debugging tomcat in eclipse
- remote debugging with maven tomcat and eclipse
- Spring context is reloaded everytime there is a change during debugging in tomcat eclipse
- Remote debugging Tomcat with Eclipse - breakpoints ignored
- Internal exception while debugging custom classes in STS
- Specifying a relative path in web.xml when debugging a servlet with Eclipse's WTP Tomcat Server?
- Eclipse Step Over is not working as expected - Tomcat web app debugging
- Remote Debugging Tomcat 7 with Eclipse Mars on MacOS X
- Remote debugging tomcat with OpenShift
- Step through debugging of web app code in Eclipse maven app running on tomcat
- tomcat server instance debugging in the eclipse
- I am unable to setup remote debugging for my Tomcat 6 web app on Ubuntu 12.04, can anyone help me?
- Eclipse Java EE IDE need tomcat source for debugging
- eclipse and tomcat debugging
More Query from same tag
- Where are Eclipse remote debugging packages?
- http://java.sun.com/jsp/jstl/core cannot be resolved in either web.xml...... (only in some of the jsp pages of a project)
- How to set initial window size in Java OpenGL
- Can't Run Simulator
- Get SessionBean Instance
- How to deploy an Eclipse project referencing a sub-project on Heroku?
- Change PHP Language Library in eclipse Oxygen
- Making one project's jars available to another dependent project
- A UDP receiver on android
- Is there an IDE that offers C++ <Thread> support?
- NullPointerExceptions while trying to read data from a public Google Spreadsheet
- Easy partial path name search in Eclipse
- How do I make my while() loop go back to an if() statement?
- registering app / deploying with Google App Engine and Android
- Connecting Eclipse JSP Page with MySQL DataSource
- Changed JSF-Implementation in Tomcat. From Mojarra to MyFaces. Managed-Beans does not work
- Eclipse IDE - source code for 'Outline' feature
- Getting the raw code in xtext dsl
- impossible to compile class for JSP tomcat
- How to create a glass card with custom view\layout?
- Avoid publish of EJBs and ManagedBeans when saving xhtml file in Maven project
- Debugging cortex m3 using eclipse
- Eclipse string.xml not color coding in editor correctly
- unable to see sqlite database in under app_database folder android emulator
- Golang on eclipse: "Resource doesn't have a corresponding Go package" on Mac
- gradle: No source task ':processTestResources' and ':processtResources'
- How to let eclipse break on a stack overflow?
- Cannot download bundle at http://repo1.maven.org/maven2/....oss-catalog-1.6.jar: HTTP Server 'Not Implemented'
- Eclipse CDT - Keyboard shortcuts or plugins for creating new Classes and methods from compile errors
- Run All the Tests