merged heads sync
authorKrista 'DarthMama' Bennett <krista@pep.foundation>
Thu, 08 Aug 2019 15:05:54 +0200
branchsync
changeset 39757a0961661cf8
parent 3973 7f5f08c3e9b4
parent 3971 8b2d20579b85
child 3976 fee417e9c90d
child 3981 6c2d703cea6d
merged heads
     1.1 --- a/src/message_api.c	Thu Aug 08 15:04:39 2019 +0200
     1.2 +++ b/src/message_api.c	Thu Aug 08 15:05:54 2019 +0200
     1.3 @@ -1083,6 +1083,7 @@
     1.4      return status;
     1.5  }
     1.6  
     1.7 +/*
     1.8  static bool _has_PGP_MIME_format(message* msg) {
     1.9      if (!msg || !msg->attachments || !msg->attachments->next)
    1.10          return false;
    1.11 @@ -1097,6 +1098,7 @@
    1.12          return false;
    1.13      return true;    
    1.14  }
    1.15 +*/
    1.16  
    1.17  static PEP_rating _rating(PEP_comm_type ct)
    1.18  {
     2.1 --- a/src/sync_api.h	Thu Aug 08 15:04:39 2019 +0200
     2.2 +++ b/src/sync_api.h	Thu Aug 08 15:05:54 2019 +0200
     2.3 @@ -32,6 +32,9 @@
     2.4      // handshake dialog must be closed
     2.5      SYNC_NOTIFY_OVERTAKEN = 9,
     2.6  
     2.7 +    // formig group
     2.8 +    SYNC_NOTIFY_FORMING_GROUP = 10,
     2.9 +
    2.10      // notificaton of actual group status
    2.11      SYNC_NOTIFY_SOLE = 254,
    2.12      SYNC_NOTIFY_IN_GROUP = 255
     3.1 --- a/sync/cond_act_sync.yml2	Thu Aug 08 15:04:39 2019 +0200
     3.2 +++ b/sync/cond_act_sync.yml2	Thu Aug 08 15:05:54 2019 +0200
     3.3 @@ -324,6 +324,9 @@
     3.4  action showDeviceAdded
     3.5      call "show_handshake" with "type" > SYNC_NOTIFY_ACCEPTED_DEVICE_ADDED
     3.6  
     3.7 +action showFormingGroup
     3.8 +    call "show_handshake" with "type" > SYNC_NOTIFY_FORMING_GROUP
     3.9 +    
    3.10  action showGroupCreated
    3.11      call "show_handshake" with "type" > SYNC_NOTIFY_ACCEPTED_GROUP_CREATED
    3.12  
     4.1 --- a/sync/sync.fsm	Thu Aug 08 15:04:39 2019 +0200
     4.2 +++ b/sync/sync.fsm	Thu Aug 08 15:05:54 2019 +0200
     4.3 @@ -231,8 +231,17 @@
     4.4              on Init {
     4.5                  do prepareOwnKeys;
     4.6                  send OwnKeysOfferer; // we're not grouped yet, this is our own keys
     4.7 +                do showFormingGroup;
     4.8              }
     4.9  
    4.10 +            on Cancel {
    4.11 +                send Rollback;
    4.12 +                go Sole;
    4.13 +            }
    4.14 +
    4.15 +            on Rollback
    4.16 +                go Sole;
    4.17 +
    4.18              on OwnKeysRequester {
    4.19                  do saveGroupKeys;
    4.20                  do receivedKeysAreDefaultKeys;
    4.21 @@ -242,14 +251,22 @@
    4.22          }
    4.23  
    4.24          state FormingGroupRequester {
    4.25 -            on Init {
    4.26 -                do prepareOwnKeys;
    4.27 -                send OwnKeysRequester; // we're not grouped yet, this is our own keys
    4.28 +            on Init
    4.29 +                do showFormingGroup;
    4.30 +
    4.31 +            on Cancel {
    4.32 +                send Rollback;
    4.33 +                go Sole;
    4.34              }
    4.35  
    4.36 +            on Rollback
    4.37 +                go Sole;
    4.38 +
    4.39              on OwnKeysOfferer {
    4.40                  do saveGroupKeys;
    4.41 +                do prepareOwnKeys;
    4.42                  do ownKeysAreDefaultKeys;
    4.43 +                send OwnKeysRequester; // we're not grouped yet, this is our own keys
    4.44                  do showGroupCreated;
    4.45                  go Grouped;
    4.46              }
     5.1 --- a/test/src/SuiteMaker.cc	Thu Aug 08 15:04:39 2019 +0200
     5.2 +++ b/test/src/SuiteMaker.cc	Thu Aug 08 15:05:54 2019 +0200
     5.3 @@ -21,7 +21,6 @@
     5.4  #include "Engine463Tests.h"
     5.5  #include "IOS1664Tests.h"
     5.6  #include "BloblistTests.h"
     5.7 -#include "KeyImportAndRetrieveTests.h"
     5.8  #include "NewUpdateIdAndMyselfTests.h"
     5.9  #include "NoOwnIdentWritesOnDecryptTests.h"
    5.10  #include "LiteralFilenameTests.h"
    5.11 @@ -31,7 +30,6 @@
    5.12  #include "PgpBinaryTests.h"
    5.13  #include "SubkeyRatingEvalTests.h"
    5.14  #include "MessageNullFromTests.h"
    5.15 -#include "Engine587Tests.h"
    5.16  #include "ExportKeyTests.h"
    5.17  #include "LeastCommonDenomColorTests.h"
    5.18  #include "StringlistTests.h"
    5.19 @@ -92,7 +90,6 @@
    5.20      "Engine463Tests",
    5.21      "IOS1664Tests",
    5.22      "BloblistTests",
    5.23 -    "KeyImportAndRetrieveTests",
    5.24      "NewUpdateIdAndMyselfTests",
    5.25      "NoOwnIdentWritesOnDecryptTests",
    5.26      "LiteralFilenameTests",
    5.27 @@ -102,7 +99,6 @@
    5.28      "PgpBinaryTests",
    5.29      "SubkeyRatingEvalTests",
    5.30      "MessageNullFromTests",
    5.31 -    "Engine587Tests",
    5.32      "ExportKeyTests",
    5.33      "LeastCommonDenomColorTests",
    5.34      "StringlistTests",
    5.35 @@ -154,7 +150,7 @@
    5.36  };
    5.37  
    5.38  // This file is generated, so magic constants are ok.
    5.39 -int SuiteMaker::num_suites = 68;
    5.40 +int SuiteMaker::num_suites = 66;
    5.41  
    5.42  void SuiteMaker::suitemaker_build(const char* test_class_name, const char* test_home, Test::Suite** test_suite) {
    5.43      if (strcmp(test_class_name, "URIAddressTests") == 0)
    5.44 @@ -175,8 +171,6 @@
    5.45          *test_suite = new IOS1664Tests(test_class_name, test_home);
    5.46      else if (strcmp(test_class_name, "BloblistTests") == 0)
    5.47          *test_suite = new BloblistTests(test_class_name, test_home);
    5.48 -    else if (strcmp(test_class_name, "KeyImportAndRetrieveTests") == 0)
    5.49 -        *test_suite = new KeyImportAndRetrieveTests(test_class_name, test_home);
    5.50      else if (strcmp(test_class_name, "NewUpdateIdAndMyselfTests") == 0)
    5.51          *test_suite = new NewUpdateIdAndMyselfTests(test_class_name, test_home);
    5.52      else if (strcmp(test_class_name, "NoOwnIdentWritesOnDecryptTests") == 0)
    5.53 @@ -195,8 +189,6 @@
    5.54          *test_suite = new SubkeyRatingEvalTests(test_class_name, test_home);
    5.55      else if (strcmp(test_class_name, "MessageNullFromTests") == 0)
    5.56          *test_suite = new MessageNullFromTests(test_class_name, test_home);
    5.57 -    else if (strcmp(test_class_name, "Engine587Tests") == 0)
    5.58 -        *test_suite = new Engine587Tests(test_class_name, test_home);
    5.59      else if (strcmp(test_class_name, "ExportKeyTests") == 0)
    5.60          *test_suite = new ExportKeyTests(test_class_name, test_home);
    5.61      else if (strcmp(test_class_name, "LeastCommonDenomColorTests") == 0)