LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-03-2015, 01:45 AM   #1
abdul.adil02
LQ Newbie
 
Registered: Nov 2015
Posts: 2

Rep: Reputation: Disabled
SSL error


Hi all,

I'm trying to connect client to ldap using java program but i'm getting the following error dump.

[02-11-15 05:45:58:331 CST] ajp-bio-8009-exec-23 22 example_internal_admin ERROR authentication.LDAPAuthenticationUtil:60 - Trust Store /opt/jdk1.7.0_17/jre/lib/security/jssecacerts- KeyStorenull
[02-11-15 05:45:58:394 CST] ajp-bio-8009-exec-23 22 example_internal_admin ERROR admin.UserAction:864 - Error getting ldap user list
javax.naming.CommunicationException: simple bind failed: ldap1.dp.example.com:636 [Root exception is javax.net.ssl.SSLHandshakeException: Received fatal alert: bad_certificate]
at com.sun.jndi.ldap.LdapClient.authenticate(LdapClient.java:215)
at com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2740)
at com.sun.jndi.ldap.LdapCtx.<init>(LdapCtx.java:316)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:193)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:211)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:154)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:84)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:684)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:307)
at javax.naming.InitialContext.init(InitialContext.java:242)
at javax.naming.InitialContext.<init>(InitialContext.java:216)
at javax.naming.directory.InitialDirContext.<init>(InitialDirContext.java:101)
at com.receivablesradius.deductions.action.authentication.LDAPAuthenticationUtil.authenticate(LDAPAuthe nticationUtil.java:61)
at com.receivablesradius.deductions.action.authentication.LDAPAuthenticationUtil.getListOfUsers(LDAPAut henticationUtil.java:92)
at com.receivablesradius.deductions.action.authentication.LDAPAuthenticationUtil$$FastClassByCGLIB$$518 e006d.invoke(<generated>)
at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProx y.java:688)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java :150)
at org.springframework.aop.interceptor.AbstractTraceInterceptor.invoke(AbstractTraceInterceptor.java:11 3)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java :172)
at org.springframework.aop.interceptor.AbstractTraceInterceptor.invoke(AbstractTraceInterceptor.java:11 3)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java :172)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.j ava:89)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java :172)
at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy. java:621)
at com.receivablesradius.deductions.action.authentication.LDAPAuthenticationUtil$$EnhancerByCGLIB$$f01d f5fd.getListOfUsers(<generated>)
at com.receivablesradius.deductions.action.admin.UserAction.getListOfLdapUserNames(UserAction.java:861)
at com.receivablesradius.deductions.action.admin.UserAction$$FastClassByCGLIB$$f5389eaa.invoke(<generat ed>)
at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint


Can any one please provide a solution for it?

Thanks & Regards,
Adil.
 
Old 11-03-2015, 01:56 AM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
It should be this:

Code:
simple bind failed: ldap1.dp.example.com:636 [Root exception is javax.net.ssl.SSLHandshakeException: Received fatal alert: bad_certificate
Your connection to the LDAP server didn't succeed because something is wrong with your certificate.
 
Old 11-03-2015, 04:22 AM   #3
abdul.adil02
LQ Newbie
 
Registered: Nov 2015
Posts: 2

Original Poster
Rep: Reputation: Disabled
Hi berndbausch,

We don't any issues with the certificate ,certificate is fine because we have imported same certificate to client and server as well but still it's failed also check the ldap port 636 it's open .So what can be the reason behind bad certificate?

Thanks,
Adil.
 
Old 11-03-2015, 05:43 AM   #4
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
I would then investigate the local certificate setup - correct directories? Permissions?
Also check the java programming forums or stackoverflow. My web search for "java ldap bind bad certificate" yields 170.000 results; there must be one that matches your environment.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
squid3 gives error: Error negotiating SSL connection !! hack-back !! Linux - Server 0 12-19-2014 07:45 PM
ERROR 2026 (HY000): SSL connection error: SSL_CTX_set_default_verify_paths failed prw8864 Linux - Software 1 11-15-2014 09:24 PM
[SOLVED] Error on SVN checkout: SSL handshake failed: SSL error: Key usage violation in certif jsaravana87 Linux - Server 3 05-07-2012 10:00 AM
sendmail: STARTTLS read error=generic SSL error.... All of a sudden! 3dMaster Linux - Server 2 12-08-2010 05:41 AM
Linux Citrix Receiver gives me error: provider code 20 SSL error 86 ebeyer Linux - Networking 1 09-16-2009 11:32 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration