You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@knox.apache.org by "Kevin Risden (JIRA)" <ji...@apache.org> on 2019/05/22 17:14:00 UTC

[jira] [Resolved] (KNOX-1856) Incorrect error message in case there is no 'gateway-identity' certificate in the configured keystore

     [ https://issues.apache.org/jira/browse/KNOX-1856?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kevin Risden resolved KNOX-1856.
--------------------------------
    Resolution: Fixed

> Incorrect error message in case there is no 'gateway-identity' certificate in the configured keystore
> -----------------------------------------------------------------------------------------------------
>
>                 Key: KNOX-1856
>                 URL: https://issues.apache.org/jira/browse/KNOX-1856
>             Project: Apache Knox
>          Issue Type: Improvement
>    Affects Versions: 1.2.0
>            Reporter: Sandor Molnar
>            Assignee: Sandor Molnar
>            Priority: Major
>             Fix For: 1.3.0
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> See the following {{if-else}} branch within {{org.apache.knox.gateway.services.security.impl.JettySSLService.logAndValidateCertificate(GatewayConfig)}} :
> {code}
>     if (cert != null) {
>       if (cert instanceof X509Certificate) {
>        ...
>       } else {
>         throw new ServiceLifecycleException("Public certificate for the gateway cannot be found with the alias gateway-identity. Plase check the identity certificate alias.");
>       }
>     } else {
>       throw new ServiceLifecycleException("Public certificate for the gateway is not of the expected type of X509Certificate. Something is wrong with the gateway keystore.");
>     }
> {code}
> As you can see the actions within the {{'else'}} branches are swapped:
> - in case the {{cert}} is null we should indicate that it's not found
> - in case the {{cert}} is not an {{X509Certificate}} we should say that



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)