File tree Expand file tree Collapse file tree 3 files changed +8
-9
lines changed Expand file tree Collapse file tree 3 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -761,7 +761,9 @@ async fn add_parts(
761
761
ShowEmails :: from_i32 ( context. get_config_int ( Config :: ShowEmails ) . await ?) . unwrap_or_default ( ) ;
762
762
763
763
let allow_creation;
764
- if mime_parser. is_system_message != SystemMessage :: AutocryptSetupMessage
764
+ if mime_parser. decrypting_failed {
765
+ allow_creation = false ;
766
+ } else if mime_parser. is_system_message != SystemMessage :: AutocryptSetupMessage
765
767
&& is_dc_message == MessengerMessage :: No
766
768
&& !context. get_config_bool ( Config :: IsChatmail ) . await ?
767
769
{
Original file line number Diff line number Diff line change @@ -612,7 +612,7 @@ mod tests {
612
612
613
613
// the same sync message sent to bob must not be executed
614
614
let bob = TestContext :: new_bob ( ) . await ;
615
- bob. recv_msg ( & sent_msg) . await ;
615
+ bob. recv_msg_trash ( & sent_msg) . await ;
616
616
assert ! ( !token:: exists( & bob, token:: Namespace :: Auth , "testtoken" ) . await ?) ;
617
617
618
618
Ok ( ( ) )
Original file line number Diff line number Diff line change @@ -987,13 +987,10 @@ async fn test_verified_lost_member_added() -> Result<()> {
987
987
assert_eq ! ( sent_msg. get_showpadlock( ) , true ) ;
988
988
989
989
// The message will not be sent to Fiona.
990
- // Test that Fiona will not be able to decrypt it.
991
- let fiona_rcvd = fiona. recv_msg ( & sent) . await ;
992
- assert_eq ! ( fiona_rcvd. get_showpadlock( ) , false ) ;
993
- assert_eq ! (
994
- fiona_rcvd. get_text( ) ,
995
- "[...] – [This message was encrypted for another setup.]"
996
- ) ;
990
+ // Test that Fiona will not be able to decrypt it
991
+ // and the message is trashed because
992
+ // we don't create groups from undecipherable messages.
993
+ fiona. recv_msg_trash ( & sent) . await ;
997
994
998
995
// Advance the time so Alice does not leave at the same second
999
996
// as the group was created.
You can’t perform that action at this time.
0 commit comments