title: 3.0.0.M1: SSL - Invalid keystore format
body: <p>Thanks @dmahapatro, I got first aid to ssl under spring-boot circumstances here: <a href="https://stackoverflow.com/questions/28303263/3-0-0-m1-how-to-run-on-https-connection/28303950?noredirect=1#comment44997337_28303950">3.0.0.M1 how to run on https connection</a></p>
  
  <p>So I generated a keystore:</p>
  
  <pre><code>keytool -genkey -keyalg RSA -alias rawi -keystore keystore.jks -storepass pass.pass -validity 365 -keysize 2048 -storetype JKS
  </code></pre>
  
  <p>I copied keystore.jks to grails-app/conf/</p>
  
  <p>Check keystore:</p>
  
  <pre><code>keytool -list -keystore grails-app/conf/keystore.jks
  Enter keystore password:  
  
  Keystore type: JKS
  Keystore provider: SUN
  
  Your keystore contains 1 entry
  
  rawi, 04.02.2015, PrivateKeyEntry, 
  Certificate fingerprint (SHA1): E9:83:C0.....
  </code></pre>
  
  <p>I added to application.yml:</p>
  
  <pre><code>server:
    port: 8443
    ssl:
      key-store: classpath:keystore.jks
      key-store-password: pass.pass
      key-password: pass.pass
  </code></pre>
  
  <p>(Adding "key-store-type: JKS" didn't help.)</p>
  
  <pre><code>grails&gt; run-app
  &gt; Configuring &gt; 1/1 projects &gt; Resolving dependencies ':agent' &gt; Resolving dependencies '::compileJava UP-TO-DATE
  &gt; Building 16% &gt; :compileGroovy &gt; Resolving dependencies ':compile' &gt; Resolving dependenci:compileGroovy
  :processResources
  :classes
  :findMainClass
  &gt; Building 83% &gt; :run &gt; Resolving dependencies ':runtime' &gt; Resolving dependencies 'detach:run
  ERROR org.apache.coyote.http11.Http11NioProtocol - Failed to start end point associated with ProtocolHandler ["http-nio-8443"]
  java.io.IOException: Invalid keystore format
          at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:650) ~[na:1.8.0_31]
          at sun.security.provider.JavaKeyStore$JKS.engineLoad(JavaKeyStore.java:55) ~[na:1.8.0_31]
          at java.security.KeyStore.load(KeyStore.java:1433) ~[na:1.8.0_31]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocketFactory.java:424) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESocketFactory.java:323) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:581) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:521) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.NioEndpoint.bind(NioEndpoint.java:363) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.AbstractEndpoint.start(AbstractEndpoint.java:737) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.coyote.AbstractProtocol.start(AbstractProtocol.java:471) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.coyote.http11.Http11NioProtocol.start(Http11NioProtocol.java:80) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.connector.Connector.startInternal(Connector.java:986) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.core.StandardService.addConnector(StandardService.java:237) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.addPreviouslyRemovedConnectors(TomcatEmbeddedServletContainer.java:186) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.st                                                                                   art(TomcatEmbeddedServletContainer.java:149) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.startEmbeddedServletContainer(EmbeddedWebApplicationContext.java:287) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:141) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:483) [spring-context-4.1.4.RELEASE.jar:4.1.4.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:40) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:187) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:176) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_31]
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_31]
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_31]
          at java.lang.reflect.Method.invoke(Method.java:483) ~[na:1.8.0_31]
          at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1270) [springloaded-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90) [groovy-2.4.0.jar:2.4.0]
          at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StatithodSite.invoke(StaticMetaMethodSite.java:43) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.call(StaticMetaMethodSite.java:88) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) [groovy-2.4.0.jar:2.4.0]
          at test.Application.main(Application.groovy:8) [main/:na]
  ERROR org.apache.catalina.core.StandardService - Failed to start connector [Connector[HTTP/1.1-8443]]
  org.apache.catalina.LifecycleException: Failed to start component [Connector[HTTP/1.1-8443]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.core.StandardService.addConnector(StandardService.java:237) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.addPreviouslyRemovedConnectors(TomcatEmbeddedServletContainer.java:186) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.start(TomcatEmbeddedServletContainer.java:149) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.startEmbeddedServletContainer(EmbeddedWebApplicationContext.java:287) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:141) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:483) [spring-context-4.1.4.RELEASE.jar:4.1.4.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext                                                           .java:118) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:40) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:187) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:176) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_31]
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_31]
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_31]
          at java.lang.reflect.Method.invoke(Method.java:483) ~[na:1.8.0_31]
          at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1270) [springloaded-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90) [groovy-2.4.0.jar:2.4.0]
          at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.invoke(StaticMetaMethodSite.java:43) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.call(StaticMetaMethodSite.java:88) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) [groovy-2.4.0.jar:2.4.0]
          at test.Application.main(Application.groovy:8) [main/:na]
  Caused by: org.apache.catalina.LifecycleException: service.getName(): "Tomcat";  Protocol handler start failed
          at org.apache.catonnector.Connector.startInternal(Connector.java:993) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          ... 25 common frames omitted
  Caused by: java.io.IOException: Invalid keystore format
          at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:650) ~[na:1.8.0_31]
          at sun.security.provider.JavaKeyStore$JKS.engineLoad(JavaKeyStore.java:55) ~[na:1.8.0_31]
          at java.security.KeyStore.load(KeyStore.java:1433) ~[na:1.8.0_31]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocketFactory.java:424) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESocketFactory.java:323) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:581) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:521) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.NioEndpoint.bind(NioEndpoint.java:363) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.AbstractEndpoint.start(AbstractEndpoint.java:737) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.coyote.AbstractProtocol.start(AbstractProtocol.java:471) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.coyote.http11.Http11NioProtocol.start(Http11NioProtocol.java:80) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.connector.Connector.startInternal(Connector.java:986) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          ... 26 common frames omitted
  ERROR grails.boot.GrailsApp - Application startup failed
  java.lang.IllegalStateException: Tomcat connector in failed state
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.start(TomcatEmbeddedServletContainer.java:157) ~[spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.startEmbeddedServletContainer(EmbeddedWebApplicationContext.java:287) ~[spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:141) ~[spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:483) ~[spring-context-4.1.4.RELEASE.jar:4.1.4.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) ~[spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691) ~[spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321) ~[spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:40) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:187) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:176) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_31]
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_31]
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_31]
          at java.lang.reflect.Method.invoke(Method.java:483) ~[na:1.8.0_31]
          at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1270) [springloaded-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.codehaus.grolection.CachedMethod.invoke(CachedMethod.java:90) [groovy-2.4.0.jar:2.4.0]
          at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.invoke(StaticMetaMethodSite.java:43) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.call(StaticMetaMethodSite.java:88) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) [groovy-2.4.0.jar:2.4.0]
          at test.Application.main(Application.groovy:8) [main/:na]
  Exception in thread "main" java.lang.IllegalStateException: Tomcat connector in failed state
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.start(TomcatEmbeddedServletContainer.java:157)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.startEmbeddedServletContainer(EmbeddedWebApplicationContext.java:287)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:141)
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:483)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118)
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321)
          at grails.boot.GrailsApp.run(GrailsApp.groovy:40)
          at grails.boot.GrailsApp.run(GrailsApp.groovy:187)
          at grails.boot.GrailsApp.run(GrailsApp.groovy:176)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
          at java.lang.reflect.Method.invoke(Method.java:483)
          at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1270)
          at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
          at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324)
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.invoke(StaticMetaMethodSite.java:43)
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.call(StaticMetaMethodSite.java:88)
          at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
          at test.Application.main(Application.groovy:8)
  :run FAILED
  
  FAILURE: Build failed with an exception.
  
  * What went wrong:
  Execution failed for task ':run'.
  &gt; Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
  
  * Try:
  Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
  
  BUILD FAILED
  
  Total time: 9.513 secs
  | Error Failed to start server (Use --stacktrace to see the full trace)
  </code></pre>
  
  <p>As I red about such former problems with the old ressources plugin I deleted all lines of the asset-plugin from build.gradle. It didn't help.
  More than that, the asset-plugin is stil listed by list-plugins(also after a clean command)</p>
  
  <p>Later addition:
  If I create a keystore in PKCS12 format (and I adapt application.yml accordingly) I get a different Error:</p>
  
  <pre><code>grails&gt; run-app
  &gt; Configuring &gt; 1/1 projects &gt; Resolving dependencies ':agent' &gt; Resolving dependencies '::compileJava UP-TO-DATE
  &gt; Building 16% &gt; :compileGroovy &gt; Resolving dependencies ':compile' &gt; Resolving dependenci:compileGroovy UP-TO-DATE
  :processResources
  :classes
  :findMainClass
  &gt; Building 83% &gt; :run &gt; Resolving dependencies ':runtime' &gt; Resolving dependencies 'detach:run
  ERROR org.apache.coyote.http11.Http11NioProtocol - Failed to start end point associated with ProtocolHandler ["http-nio-8443"]
  java.io.IOException: DerInputStream.getLength(): lengthTag=111, too big.
          at sun.security.util.DerInputStream.getLength(DerInputStream.java:561) ~[na:1.8.0_31]
          at sun.security.util.DerValue.init(DerValue.java:365) ~[na:1.8.0_31]
          at sun.security.util.DerValue.&lt;init&gt;(DerValue.java:320) ~[na:1.8.0_31]
          at sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:1872) ~[na:1.8.0_31]
          at java.security.KeyStore.load(KeyStore.java:1433) ~[na:1.8.0_31]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocketFactory.java:424) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESocketFactory.java:323) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:581) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:521) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.NioEndpoint.bind(NioEndpoint.java:363) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.tomcat.util.net.AbstractEndpoint.start(AbstractEndpoint.java:737) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.coyote.AbstractProtocol.start(AbstractProtocol.java:471) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.coyote.http11.Http11NioProtocol.start(Http11NioProtocol.java:80) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.connector.Connector.startInternal(Connector.java:986) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.core.StandardService.addConnector(StandardService.java:237) [tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.addPreviouslyRemovedConnectors(Tomc                                                     atEmbeddedServletContainer.java:186) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.start(TomcatEmbeddedServletContainer.java:149) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.startEmbeddedServletContainer(EmbeddedWebApplicationContext.java:287) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:141) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:483) [spring-context-4.1.4.RELEASE.jar:4.1.4.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:40) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:187) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:176) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_31]
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_31]
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_31]
          at java.lang.reflect.Method.invoke(Method.java:483) ~[na:1.8.0_31]
          at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1270) [springloaded-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod0) [groovy-2.4.0.jar:2.4.0]
          at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.invoke(StaticMetaMethodSite.java:43) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.call(StaticMetaMethodSite.java:88) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) [groovy-2.4.0.jar:2.4.0]
          at test.Application.main(Application.groovy:8) [main/:na]
  ERROR org.apache.catalina.core.StandardService - Failed to start connector [Connector[HTTP/1.1-8443]]
  org.apache.catalina.LifecycleException: Failed to start component [Connector[HTTP/1.1-8443]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.core.StandardService.addConnector(StandardService.java:237) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.addPreviouslyRemovedConnectors(TomcatEmbeddedServletContainer.java:186) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.start(TomcatEmbeddedServletContainer.java:149) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.startEmbeddedServletContainer(EmbeddedWebApplicationContext.java:287) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:141) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.jav                                                                   a:483) [spring-context-4.1.4.RELEASE.jar:4.1.4.RELEASE]
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321) [spring-boot-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:40) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:187) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at grails.boot.GrailsApp.run(GrailsApp.groovy:176) [grails-core-3.0.0.M1.jar:3.0.0.M1]
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_31]
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_31]
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_31]
          at java.lang.reflect.Method.invoke(Method.java:483) ~[na:1.8.0_31]
          at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1270) [springloaded-1.2.1.RELEASE.jar:1.2.1.RELEASE]
          at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90) [groovy-2.4.0.jar:2.4.0]
          at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.invoke(StaticMetaMethodSite.java:43) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.call(StaticMetaMethodSite.java:88) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) [groovy-2.4.0.jar:2.4.0]
          at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) [groovy-2.4.0.jar:2.4.0]
          at test.ApplicatioApplication.groovy:8) [main/:na]
  Caused by: org.apache.catalina.LifecycleException: service.getName(): "Tomcat";  Protocol handler start failed
          at org.apache.catalina.connector.Connector.startInternal(Connector.java:993) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ~[tomcat-embed-core-8.0.15.jar:8.0.15]
          ... 25 common frames omitted
  Caused by: java.io.IOException: DerInputStream.getLength(): lengthTag=111, too big.
          at sun.security.util.DerInputStream.getLength(DerInputStream.java:561) ~[na:1.8.0_31]
          at sun.security.util.DerValue.init(DerValue.java:365) ~[na:1.8.0_31]
          at sun.security.util.DerValue.&lt;init&gt;(DerValue.java:320) ~[na:1.8.0_31]
          at sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:1872) ~[na:1.8.0_31]
          at java.security.KeyStore.load(KeyStore.java:1433) ~[na:1.8.0_31]
          at ----- CUT HERE BECAUSE OF SIZE LIMITATION OF MASSAGES
  </code></pre>
  
  <p>EDIT:
  But it works if I write in application.yml:</p>
  
  <pre><code>server:
    port: 8443
    ssl:
    keyStore: file:/absolute/path/to/keystore
  ...
  </code></pre>
  
  <p>I don't know, if this is worth a JIRA, or it is only my incapacity...</p>