mirror of
https://github.com/KDE/kdeconnect-android
synced 2025-08-30 21:55:10 +00:00
Fixed certificate fingerprint formatting
This commit is contained in:
@@ -63,8 +63,8 @@
|
||||
<string name="error_invalid_key">Invalid key received</string>
|
||||
<string name="encryption_info_title">Encryption Info</string>
|
||||
<string name="encryption_info_msg_no_ssl">The other device doesn\'t use a recent version of KDE Connect, using the legacy encryption method.</string>
|
||||
<string name="my_device_key">My device key : </string>
|
||||
<string name="remote_device_key">Remote device key : </string>
|
||||
<string name="my_device_fingerprint">SHA1 fingerprint of your device certificate is : </string>
|
||||
<string name="remote_device_fingerprint">SHA1 fingerprint of remote device certificate is : </string>
|
||||
<string name="pair_requested">Pair requested</string>
|
||||
<string name="pairing_request_from">Pairing request from %1s</string>
|
||||
<string name="received_url_title">Received link from %1s</string>
|
||||
|
@@ -228,7 +228,7 @@ public class SslHelper {
|
||||
formatter.format("%02x:", hash[i]);
|
||||
}
|
||||
formatter.format("%02x", hash[i]);
|
||||
return formatter.toString().toUpperCase();
|
||||
return formatter.toString();
|
||||
} catch (Exception e) {
|
||||
return null;
|
||||
}
|
||||
|
@@ -197,8 +197,8 @@ public class PairActivity extends ActionBarActivity {
|
||||
if (device.certificate == null) {
|
||||
builder.setMessage(R.string.encryption_info_msg_no_ssl);
|
||||
} else {
|
||||
builder.setMessage(context.getResources().getString(R.string.my_device_key) + " " + SslHelper.getCertificateHash(SslHelper.certificate) + "\n"
|
||||
+ context.getResources().getString(R.string.remote_device_key) + " " + SslHelper.getCertificateHash(device.certificate));
|
||||
builder.setMessage(context.getResources().getString(R.string.my_device_fingerprint) + " " + SslHelper.getCertificateHash(SslHelper.certificate) + "\n\n"
|
||||
+ context.getResources().getString(R.string.remote_device_fingerprint) + " " + SslHelper.getCertificateHash(device.certificate));
|
||||
}
|
||||
builder.create().show();
|
||||
return true;
|
||||
|
Reference in New Issue
Block a user