You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Claus Ibsen (Jira)" <ji...@apache.org> on 2022/07/25 12:33:00 UTC

[jira] [Resolved] (CAMEL-18291) SSLContextParameters parsePropertyValue support for certAlias property

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

Claus Ibsen resolved CAMEL-18291.
---------------------------------
    Fix Version/s: 3.19.0
       Resolution: Fixed

> SSLContextParameters parsePropertyValue support for certAlias property
> ----------------------------------------------------------------------
>
>                 Key: CAMEL-18291
>                 URL: https://issues.apache.org/jira/browse/CAMEL-18291
>             Project: Camel
>          Issue Type: New Feature
>          Components: camel-core
>            Reporter: Robin Vishwakarma
>            Priority: Minor
>              Labels: sslContextParameters
>             Fix For: 3.19.0
>
>
> SSLContextParameters does have the provision to provide certAlias in case there are multiple certificate-key pair aliases present inside keystore but it doesn't have support for parsing the value for certAlias. 
> It would be nice to add support of parsePropertyValue for certAlias property so that it can be externalized based on the configuration. 
> Example - We have 2 environments, System Integration Testing(SIT) and User Acceptance Testing(UAT). We store certificate-key pair of both the environments in keystore JKS file and we want to select certificate-key pair for SSLContext via certAlias but here we have to provide the exact name of alias - 
> {code:java}
> <camel:sslContextParameters id="sslContextParameters" certAlias="ALIASNAME">
>     <camel:keyManagers keyPassword="{{keystore.key.password}}">
>         <camel:keyStore resource="keystore/keystore.jks" password="{{keystore.password}}"/>
>     </camel:keyManagers>
>     <camel:trustManagers>
>         <camel:keyStore resource="truststore/truststore.jks" password="{{truststore.password}}"/>
>     </camel:trustManagers>
> </camel:sslContextParameters>{code}
> Since certAlias doesn't have support for parsePropertyValue like other properties keyPassword, password, etc. We can't use property place holders for passing certAlias name.
> {code:java}
> <!--Not Supported certAlias="{{env.alias}}-->
> <camel:sslContextParameters id="sslContextParameters" certAlias="{{env.alias}}">
>     <camel:keyManagers keyPassword="{{keystore.key.password}}">
>         <camel:keyStore resource="keystore/keystore.jks" password="{{keystore.password}}"/>
>     </camel:keyManagers>
>     <camel:trustManagers>
>         <camel:keyStore resource="truststore/truststore.jks" password="{{truststore.password}}"/>
>     </camel:trustManagers>
> </camel:sslContextParameters> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)