davsclaus opened a new pull request, #30241:
URL: https://github.com/apache/camel/pull/30241

   ## Backport of #30204
   
   Backport of #30204 (CAMEL-27049: camel-main - mask the server and vault 
options flagged secret) onto `camel-4.18.x`, for 4.18.6.
   
   **Original PR:** #30204 - CAMEL-27049: camel-main - mask the server and 
vault options flagged secret
   **Target branch:** `camel-4.18.x`
   **JIRA:** [CAMEL-27049](https://issues.apache.org/jira/browse/CAMEL-27049)
   
   ### Adapted, not a straight cherry-pick
   
   - `UpdateSensitizeHelper`: the generator of this branch has no security 
options, so the change is ported by hand: it reads the camel-main options 
flagged secret from `camel-main-configuration-metadata.json` (directly from its 
`properties`, as `JsonMapper.generateMainModel` is not on this branch) into 
`SENSITIVE_WHOLE_KEYS` of `SensitiveUtils` and `sensitive-whole-keys.json`, and 
also scans the beans catalog.
   - `IBMSecretsManagerVaultConfiguration`: `eventStreamUsername` and 
`eventStreamPassword` are flagged `secret = true`, as they are on `main` and 
`camel-4.22.x`. Without this they were not masked. The camel-main metadata (and 
its copy in the catalog) is regenerated.
   - The generated whole keys come from the metadata of this branch: 21 options 
(no `camel.cluster.*`, no secret `camel.ssl.*`, and only `token` for HashiCorp).
   - `SensitiveUtilsTest`: the new tests use JUnit assertions, as the rest of 
this test does on this branch.
   - `SecretOptionsAreSensitiveKeysTest`: uses `isSecret()` only, as 
`BaseOptionModel.getSecurity()` is not on this branch.
   - `MainSecurityPolicyTest` is left out: the security policy is not on 
`camel-4.18.x`. `MainAutoConfigurationSummaryMaskingTest` covers the masking.
   - The 4.24 upgrade guide entry is not part of the backport. The 4.18.6 note 
goes into `camel-4x-upgrade-guide-4_18.adoc` on `main`.
   
   ### Tests
   
   camel-util (185), camel-main (172) and camel-package-maven-plugin (35) pass 
locally (JDK 21, `./mvnw`). The check of `SecretOptionsAreSensitiveKeysTest` 
passes against the committed catalog of this branch (393 components, 430 
camel-main options).
   
   _Claude Code on behalf of Claus Ibsen_
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to