After configuring the Tomcat certificate KeyStore file, the error has been started: (Tomcat version: apache-tomcat-6.0.43)
Tomcat configuration:
<ConnectorPort= "8443"Protocol= "http/1.1"sslenabled= "true"MaxThreads= "Max"Scheme= "https"Secure= "true"ClientAuth= "false"Sslprotocol= "TLS"Keystorefile= "Conf/tomcat.keystore"Keystorepass= "123456" />
Tomcat.keystore Location:
Error message:
Severity: Error Initializing Endpoint
Java.lang.Exception:No Certificate file specified or invalid file format
At Org.apache.tomcat.jni.SSLContext.setCertificate (Native Method)
At Org.apache.tomcat.util.net.AprEndpoint.init (aprendpoint.java:836)
At Org.apache.coyote.http11.Http11AprProtocol.init (http11aprprotocol.java:109)
At Org.apache.catalina.connector.Connector.initialize (connector.java:1123)
At Org.apache.catalina.core.StandardService.initialize (standardservice.java:703)
At Org.apache.catalina.core.StandardServer.initialize (standardserver.java:843)
At Org.apache.catalina.startup.Catalina.load (catalina.java:538)
At Org.apache.catalina.startup.Catalina.load (catalina.java:562)
At Sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
At Sun.reflect.NativeMethodAccessorImpl.invoke (nativemethodaccessorimpl.java:39)
At Sun.reflect.DelegatingMethodAccessorImpl.invoke (delegatingmethodaccessorimpl.java:25)
At Java.lang.reflect.Method.invoke (method.java:597)
At Org.apache.catalina.startup.Bootstrap.load (bootstrap.java:261)
At Org.apache.catalina.startup.Bootstrap.main (bootstrap.java:413)
2015-3-3 16:05:52 Org.apache.catalina.core.StandardService Initialize
Severity: Failed to initialize connector [connector[http/1.1-8443]]
Lifecycleexception:protocol handler initialization failed:java.lang.Exception:No Certificate file specified or invalid File format
At Org.apache.catalina.connector.Connector.initialize (connector.java:1125)
At Org.apache.catalina.core.StandardService.initialize (standardservice.java:703)
At Org.apache.catalina.core.StandardServer.initialize (standardserver.java:843)
At Org.apache.catalina.startup.Catalina.load (catalina.java:538)
At Org.apache.catalina.startup.Catalina.load (catalina.java:562)
At Sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
At Sun.reflect.NativeMethodAccessorImpl.invoke (nativemethodaccessorimpl.java:39)
At Sun.reflect.DelegatingMethodAccessorImpl.invoke (delegatingmethodaccessorimpl.java:25)
At Java.lang.reflect.Method.invoke (method.java:597)
At Org.apache.catalina.startup.Bootstrap.load (bootstrap.java:261)
At Org.apache.catalina.startup.Bootstrap.main (bootstrap.java:413)
Workaround:
Different Tomcat version number SSL configuration is different, you use if is tomcat6.0 words:
<connector protocol= "org.apache.coyote.http11.Http11NioProtocol" port= "8443" minsparethreads= "5"
Maxsparethreads= "enablelookups=" true "disableuploadtimeout=" true "acceptcount=" "maxthreads=" 200 "
Scheme= "https" secure= "true" sslenabled= "true" Clientauth= "false" sslprotocol= "TLS"
Keystorefile= "F:/apache-tomcat/server.keystore" keystorepass= "password"/>
So change the config file to
<ConnectorPort= "8443"Protocol= "Org.apache.coyote.http11.Http11NioProtocol"sslenabled= "true"MaxThreads= "Max"Scheme= "https"Secure= "true"ClientAuth= "false"Sslprotocol= "TLS"Keystorefile= "Conf/tomcat.keystore"Keystorepass= "123456" />
The problem is solved.
It is worth mentioning that Tomcat is also fraught ah, server.xml in the sample configuration of annotations is
Protocol= "http/1.1"
<!--
<connector port= "8443" protocol= "http/1.1" sslenabled= "true"
maxthreads= "Scheme=" "https" secure= "true"
Clientauth= "false" sslprotocol= "TLS"/>
-
Really is too the pit Father!!!
Configuring CAS error no Certificate file specified or invalid file format