mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2024-12-17 17:20:21 +01:00
core: change database encryption API to require current passphrase on all changes (#1019)
This commit is contained in:
committed by
GitHub
parent
229f385f42
commit
082e12683b
+4
-4
@@ -2769,11 +2769,11 @@ testDatabaseEncryption = withTmpFiles $ do
|
||||
bob <# "alice> hi"
|
||||
alice ##> "/db encrypt mykey"
|
||||
alice <## "error: chat not stopped"
|
||||
alice ##> "/db decrypt"
|
||||
alice ##> "/db decrypt mykey"
|
||||
alice <## "error: chat not stopped"
|
||||
alice ##> "/_stop"
|
||||
alice <## "chat stopped"
|
||||
alice ##> "/db decrypt"
|
||||
alice ##> "/db decrypt mykey"
|
||||
alice <## "error: chat database is not encrypted"
|
||||
alice ##> "/db encrypt mykey"
|
||||
alice <## "ok"
|
||||
@@ -2785,7 +2785,7 @@ testDatabaseEncryption = withTmpFiles $ do
|
||||
testChatWorking alice bob
|
||||
alice ##> "/_stop"
|
||||
alice <## "chat stopped"
|
||||
alice ##> "/db encrypt nextkey"
|
||||
alice ##> "/db password mykey nextkey"
|
||||
alice <## "ok"
|
||||
withTestChatOpts testOpts {maintenance = True, dbKey = "nextkey"} "alice" $ \alice -> do
|
||||
alice ##> "/_start"
|
||||
@@ -2793,7 +2793,7 @@ testDatabaseEncryption = withTmpFiles $ do
|
||||
testChatWorking alice bob
|
||||
alice ##> "/_stop"
|
||||
alice <## "chat stopped"
|
||||
alice ##> "/db decrypt"
|
||||
alice ##> "/db decrypt nextkey"
|
||||
alice <## "ok"
|
||||
withTestChat "alice" $ \alice -> testChatWorking alice bob
|
||||
|
||||
|
||||
Reference in New Issue
Block a user