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

Claus Ibsen updated CAMEL-27498:
--------------------------------
    Description: 
_Claude Code on behalf of davsclaus_

Inside a Kamelet, an optional property that is not set, such as {{?user}}, 
resolves from the OS environment variable with the same name. 
DefaultPropertiesParser does the env lookup 
(ENVIRONMENT_VARIABLES_MODE_OVERRIDE, the default) right after the local 
(template) lookup misses. A plain route log: "user=[{{?user}}]" logs the login 
name.

Kamelet properties in the catalog that clash with common env vars:
* user (USER): the 4 Elasticsearch/OpenSearch Kamelets
* username / userName (USERNAME, always set on Windows): about 35 Kamelets
* password: about 50
* hostName (HOSTNAME is the container id in Docker): azure-cosmosdb-source
* host: rest-openapi-sink
* domain (smb), region (ibm-cos), key (couchbase-sink)

Suggested direction: a Kamelet property that is not set resolves only from the 
Kamelet parameters and the camel.kamelet.<name>[.<route>].<prop> keys, not from 
a bare-name env var or system property.

Not a security issue: the environment is controlled by the operator. It is a 
correctness issue: a value meant for something else is picked up (CAMEL-27497 
is one case).

  was:
_Claude Code on behalf of davsclaus_

Inside a Kamelet, an optional property that is not set, such as {{?user}}, 
resolves from the OS environment variable with the same name. 
DefaultPropertiesParser does the env lookup 
(ENVIRONMENT_VARIABLES_MODE_OVERRIDE, the default) right after the local 
(template) lookup misses. A plain route log: "user=[{{?user}}]" logs the login 
name.

Kamelet properties in the catalog that clash with common env vars:
* user (USER): the 4 Elasticsearch/OpenSearch Kamelets
* username / userName (USERNAME, always set on Windows): about 35 Kamelets
* password: about 50
* hostName (HOSTNAME is the container id in Docker): azure-cosmosdb-source
* host: rest-openapi-sink
* domain (smb), region (ibm-cos), key (couchbase-sink)

Suggested direction: a Kamelet property that is not set resolves only from the 
Kamelet parameters and the camel.kamelet.<name>[.<route>].<prop> keys, not from 
a bare-name env var or system property.

Not a security issue: the environment is controlled by the operator. It is a 
correctness issue: a value meant for something else is picked up (CAMEL-27487 
is one case).


> camel-kamelet - Kamelet properties that are not set fall back to an OS env 
> var of the same bare name
> ----------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-27498
>                 URL: https://issues.apache.org/jira/browse/CAMEL-27498
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-kamelet
>            Reporter: Claus Ibsen
>            Priority: Minor
>             Fix For: 4.25.0
>
>
> _Claude Code on behalf of davsclaus_
> Inside a Kamelet, an optional property that is not set, such as {{?user}}, 
> resolves from the OS environment variable with the same name. 
> DefaultPropertiesParser does the env lookup 
> (ENVIRONMENT_VARIABLES_MODE_OVERRIDE, the default) right after the local 
> (template) lookup misses. A plain route log: "user=[{{?user}}]" logs the 
> login name.
> Kamelet properties in the catalog that clash with common env vars:
> * user (USER): the 4 Elasticsearch/OpenSearch Kamelets
> * username / userName (USERNAME, always set on Windows): about 35 Kamelets
> * password: about 50
> * hostName (HOSTNAME is the container id in Docker): azure-cosmosdb-source
> * host: rest-openapi-sink
> * domain (smb), region (ibm-cos), key (couchbase-sink)
> Suggested direction: a Kamelet property that is not set resolves only from 
> the Kamelet parameters and the camel.kamelet.<name>[.<route>].<prop> keys, 
> not from a bare-name env var or system property.
> Not a security issue: the environment is controlled by the operator. It is a 
> correctness issue: a value meant for something else is picked up (CAMEL-27497 
> is one case).



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to