yyqdbngt opened a new issue, #2252: URL: https://github.com/apache/rocketmq-dashboard/issues/2252
## Problem `CredentialUtils.mask` measures and slices credentials by UTF-16 code units. If a supplementary Unicode character falls across the four-character visibility boundary, the method can split its surrogate pair and return malformed Unicode. The current length threshold is also based on code units rather than user-visible code points. ## Expected behavior Credential masking should preserve the existing ASCII behavior while: - measuring the partial-mask threshold in Unicode code points; - keeping the first and last four complete code points; - never returning an isolated surrogate; - failing closed for malformed UTF-16 input. ## Proposed scope Update the shared credential masking utility and add focused boundary, supplementary-character, short-value, null/empty, and malformed-input tests. I searched the repository's issues and pull requests for credential masking, Unicode, and surrogate handling and found no existing report or open implementation for this behavior. -- 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]
