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

Claus Ibsen updated CAMEL-27844:
--------------------------------
    Description: 
Found while improving the option descriptions of camel-cm-sms for CAMEL-23832 
(commit 
https://github.com/apache/camel/commit/387f7ff0b6ea13b1acc5d8ca1e8ae0ec8dbee737,
 pull request https://github.com/apache/camel/pull/31143).
These are separate problems of the component; the descriptions change only 
documents the current behavior.

h4. 1. GSM extension characters are counted as one septet
{{CMMessage.setUnicodeAndMultipart}} counts parts by msg.length(). A GSM 03.38 
extension character (€ [ ] { } ~ \ ^ | or form feed) takes 2 septets, so a GSM 
message of 155-160 characters with such characters is treated as one part and 
no MAXIMUMNUMBEROFMESSAGEPARTS is sent.
Proposed change: count extension characters as 2 for GSM messages.

h4. 2. A test passes for the wrong reason
CMTest.testInvalidHostDuplicateScheme ("cm-sms://https://demo.com";) passes only 
because productToken is missing; the duplicate scheme is never checked, so with 
a token the URL becomes https://https://demo.com.
Proposed change: reject a host with a scheme, and give the test a token.


_Claude Code on behalf of davsclaus_

  was:
Found while improving the option descriptions of camel-cm-sms for CAMEL-23832 
(pull request https://github.com/apache/camel/pull/31143).
These are separate problems of the component; the descriptions change only 
documents the current behavior.

h4. 1. GSM extension characters are counted as one septet
{{CMMessage.setUnicodeAndMultipart}} counts parts by msg.length(). A GSM 03.38 
extension character (€ [ ] { } ~ \ ^ | or form feed) takes 2 septets, so a GSM 
message of 155-160 characters with such characters is treated as one part and 
no MAXIMUMNUMBEROFMESSAGEPARTS is sent.
Proposed change: count extension characters as 2 for GSM messages.

h4. 2. A test passes for the wrong reason
CMTest.testInvalidHostDuplicateScheme ("cm-sms://https://demo.com";) passes only 
because productToken is missing; the duplicate scheme is never checked, so with 
a token the URL becomes https://https://demo.com.
Proposed change: reject a host with a scheme, and give the test a token.


_Claude Code on behalf of davsclaus_


> camel-cm-sms: GSM extension characters are counted as one, so the number of 
> message parts is wrong
> --------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-27844
>                 URL: https://issues.apache.org/jira/browse/CAMEL-27844
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cm-sms
>            Reporter: Claus Ibsen
>            Priority: Minor
>             Fix For: 4.25.0
>
>
> Found while improving the option descriptions of camel-cm-sms for CAMEL-23832 
> (commit 
> https://github.com/apache/camel/commit/387f7ff0b6ea13b1acc5d8ca1e8ae0ec8dbee737,
>  pull request https://github.com/apache/camel/pull/31143).
> These are separate problems of the component; the descriptions change only 
> documents the current behavior.
> h4. 1. GSM extension characters are counted as one septet
> {{CMMessage.setUnicodeAndMultipart}} counts parts by msg.length(). A GSM 
> 03.38 extension character (€ [ ] { } ~ \ ^ | or form feed) takes 2 septets, 
> so a GSM message of 155-160 characters with such characters is treated as one 
> part and no MAXIMUMNUMBEROFMESSAGEPARTS is sent.
> Proposed change: count extension characters as 2 for GSM messages.
> h4. 2. A test passes for the wrong reason
> CMTest.testInvalidHostDuplicateScheme ("cm-sms://https://demo.com";) passes 
> only because productToken is missing; the duplicate scheme is never checked, 
> so with a token the URL becomes https://https://demo.com.
> Proposed change: reject a host with a scheme, and give the test a token.
> _Claude Code on behalf of davsclaus_



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

Reply via email to