tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lars Fessen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (TOMEE-2161) TomEE-embedded: Attribute "keystoreFile" is not set correctly in Container startup
Date Wed, 10 Jan 2018 13:19:00 GMT

    [ https://issues.apache.org/jira/browse/TOMEE-2161?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16320208#comment-16320208
] 

Lars Fessen commented on TOMEE-2161:
------------------------------------

Hi,

No thanks, of course you can do this.

Best regards
Lars

> TomEE-embedded: Attribute "keystoreFile" is not set correctly in Container startup
> ----------------------------------------------------------------------------------
>
>                 Key: TOMEE-2161
>                 URL: https://issues.apache.org/jira/browse/TOMEE-2161
>             Project: TomEE
>          Issue Type: Bug
>    Affects Versions: 7.0.5
>            Reporter: Lars Fessen
>            Assignee: Jonathan Gallimore
>
> When using the Tomee-embedded Container and trying to use HTTPs the "keystoreFile"-attribute
is not set correctly. (We are using tomee-embedded 7.0.0 but the github master has still the
same bug)
> *How I use the container:*
> {code:java}
> Configuration cfg = new Configuration();
> cfg.setSsl(true);
> cfg.setKeystoreFile("my/path/to/keystore/keystore.p12");
> cfg.setKeystoreType("PKCS12");
> cfg.setKeystorePass("changeit");
> cfg.setSslProtocol("TLS");
> cfg.setKeyAlias("alias");
> cfg.setSkipHttp(true);
> cfg.setHttpsPort(config.getPort());
> org.apache.tomee.embedded.Container container;
> container = new Container();
> container.setup(cfg);
> container.start();
> {code}
> *Where is the bug in Tomee-embedded:*
> https://github.com/apache/tomee/blob/master/tomee/tomee-embedded/src/main/java/org/apache/tomee/embedded/Container.java
> Line: 632
> {code:java}
> if (configuration.getKeystoreFile() != null) {
>     httpsConnector.setAttribute("", configuration.getKeystoreFile());
> }
> {code}
> *What is the solution (in my opinion):*
> {code:java}
> if (configuration.getKeystoreFile() != null) {
>     httpsConnector.setAttribute("keystoreFile", configuration.getKeystoreFile());
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message