mirror of
https://github.com/bitwarden/mobile
synced 2025-12-20 10:13:42 +00:00
make exceptiond available
This commit is contained in:
@@ -92,7 +92,7 @@ namespace Bit.Android.Services
|
|||||||
{
|
{
|
||||||
return App.Utilities.Crypto.AesCbcDecrypt(new App.Models.CipherString(cs), aesKey);
|
return App.Utilities.Crypto.AesCbcDecrypt(new App.Models.CipherString(cs), aesKey);
|
||||||
}
|
}
|
||||||
catch
|
catch(Exception e)
|
||||||
{
|
{
|
||||||
Console.WriteLine("Failed to decrypt from secure storage.");
|
Console.WriteLine("Failed to decrypt from secure storage.");
|
||||||
_settings.Remove(formattedKey);
|
_settings.Remove(formattedKey);
|
||||||
@@ -122,7 +122,7 @@ namespace Bit.Android.Services
|
|||||||
var cipherString = App.Utilities.Crypto.AesCbcEncrypt(dataBytes, aesKey);
|
var cipherString = App.Utilities.Crypto.AesCbcEncrypt(dataBytes, aesKey);
|
||||||
_settings.AddOrUpdateValue(formattedKey, cipherString.EncryptedString);
|
_settings.AddOrUpdateValue(formattedKey, cipherString.EncryptedString);
|
||||||
}
|
}
|
||||||
catch
|
catch(Exception e)
|
||||||
{
|
{
|
||||||
Console.WriteLine("Failed to encrypt to secure storage.");
|
Console.WriteLine("Failed to encrypt to secure storage.");
|
||||||
Utilities.SendCrashEmail(e);
|
Utilities.SendCrashEmail(e);
|
||||||
@@ -225,7 +225,7 @@ namespace Bit.Android.Services
|
|||||||
return new App.Models.SymmetricCryptoKey(key);
|
return new App.Models.SymmetricCryptoKey(key);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch
|
catch(Exception e)
|
||||||
{
|
{
|
||||||
Console.WriteLine("Cannot get AesKey.");
|
Console.WriteLine("Cannot get AesKey.");
|
||||||
_keyStore.DeleteEntry(KeyAlias);
|
_keyStore.DeleteEntry(KeyAlias);
|
||||||
|
|||||||
Reference in New Issue
Block a user