Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LongTermCredential, lossy conversion from UTF-8 #103

Open
flurbi opened this issue Mar 24, 2017 · 1 comment
Open

LongTermCredential, lossy conversion from UTF-8 #103

flurbi opened this issue Mar 24, 2017 · 1 comment
Labels

Comments

@flurbi
Copy link

flurbi commented Mar 24, 2017

org.ice4j.security.LongTermCredential.toString(...)
    line 77
    incorrect: new String(bytes, "UTF-8");
    problem  : unexpected bytes translated to 0xFFFD
    correct  : CharsetDecoder with onMalformedInput(REPORT), onUnmappableCharacter(REPORT)
    Also consider using static final Charset UTF_8 = Charset.forName("UTF-8"),
    (no UnsupportedEncodingException, UTF-8 must be supported).
@bgrozev bgrozev added the bug label Apr 19, 2017
@OrangeDog
Copy link

or java.nio.charset.StandardCharsets.UTF_8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants