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

Claus Ibsen updated CAMEL-23799:
--------------------------------
    Fix Version/s: 4.21.0

> Simple language: sort init-block substitution keys by length to prevent 
> prefix collision
> ----------------------------------------------------------------------------------------
>
>                 Key: CAMEL-23799
>                 URL: https://issues.apache.org/jira/browse/CAMEL-23799
>             Project: Camel
>          Issue Type: Bug
>            Reporter: Adriano Machado
>            Assignee: Adriano Machado
>            Priority: Major
>             Fix For: 4.21.0
>
>
> When SimpleExpressionParser and SimplePredicateParser substitute init\-block 
> keys in the expression string, shorter keys that are prefixes of longer ones 
> could match first and corrupt the substitution. Sorting keys by descending 
> length before substituting ensures longer \(more specific\) keys are always 
> replaced first, preventing this prefix collision.
> Discovered during the work on CAMEL\-22894 \(simple language parser 
> hardening\).



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

Reply via email to