Thanks for the quick response, I had hostname matching been banging my head
on this for a while.

I just fixed it - something is up with using a default constructor for
SSLHostConfigCertificate  (orig was new  SSLHostConfigCertificate ())  and
possibly with setting the keystore directly from the bundle (complained
about padding) .

I changed the above to:

SSLHostConfigCertificate sslHostCert = new SSLHostConfigCertificate(shc,
SSLHostConfigCertificate.Type.RSA);

// KeyStore ks = ssb.getKeyStore();

// sslHostCert.setCertificateKeystore(ssb.getKeyStore());

sslHostCert.setCertificateKeystoreFile("file:src/main/resources/RBup.p12");

sslHostCert.setCertificateKeystorePassword("Whatever321");

sslHostCert.setCertificateKeyAlias("RBup");


and voila! Thanks anyway


On Mon, Jun 3, 2024 at 5:29 AM Mark Thomas <ma...@apache.org> wrote:

> On 03/06/2024 09:16, Adam Danischewski wrote:
>
> > Not sure why I'm getting:
> >
> > Caused by: java.lang.NullPointerException: Cannot invoke
> > "org.apache.tomcat.util.net.SSLHostConfig.getProtocols()" because
> > "this.sslHostConfig" is null
>
> You haven't configured a default SSLHostConfig.
>
> Either use "_default_" for the host name of the SSLHostConfig you have
> defined or call setDefaultSSLHostConfigName("localhost") on the endpoint.
>
> Mark
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>

-- 

Adam Michael Danischewski

Software Engineer

Phone: (929) 308-9674

Email: adam.danischew...@gmail.com

Github: http://github.com/AdamDanischewski

Reply via email to