Closed mahmet closed 7 years ago
I have not tested it in German. You may want to ask on stack overflow and/or Xamarin forums to see, if anyone has similar experience or this is one off. Or is it specific to that localized make and model of Android. We an go from there. Thanks.
I guess the problem is in the SecureStorage Android implementation in the GetValue() method:
var encodedBytes = entry.SecretKey.GetEncoded(); return Encoding.ASCII.GetString(encodedBytes);
I found something on the Internet about this issue (https://bytes.com/topic/c-sharp/answers/279346-encoding-umlaut-becomes-when-using-system-text-encoding-ascii). Can we maybe try a different encoding like UTF-8 ?
I have made a Pull Request for this problem
Appreciate your efforts. It looks like UTF8 is backwards compatible with ASCII. So it should not affect the existing users. I will test and merge the pull request in a few days. Thx.
Checked in the code. It required more changes than your branch. So took that and merged. Thanks again for your efforts.
Hello, I have problems with German Umlaut's when restoring strings with the SecureStorage Plugin. The strings are saved as e.g. "Zürich" and then when I retrieve the string back with .GetValue I get "Z?rich" back. This problem only occurs on Android.