libsignal-protocol-java
libsignal-protocol-java copied to clipboard
Displayable fingerprint computation depends on platform character set
This call to String.getBytes()
should probably be replaced with getBytes(StandardCharsets.UTF_8)
or getBytes(Charset.forName("UTF-8"))
.
Thankfully this seems to default to UTF-8 on Android anyway, though it's still worth being explicit: http://stackoverflow.com/questions/2207631/android-default-character-encoding
There are many calls to getBytes() throughout the entire codebase which do not specify a character encoding. We've always depended on UTF8 being mandatory and default on Android. Maybe one day we'll go through and make them all explicit.