changing comments to debug out sync
authorVolker Birk <vb@pep-project.org>
Thu, 16 Jan 2020 15:32:16 +0100
branchsync
changeset 43387a9de0786596
parent 4337 7e8015c705ae
child 4339 4cbb64ab4936
changing comments to debug out
sync/sync.fsm
     1.1 --- a/sync/sync.fsm	Thu Jan 16 15:04:04 2020 +0100
     1.2 +++ b/sync/sync.fsm	Thu Jan 16 15:32:16 2020 +0100
     1.3 @@ -18,6 +18,7 @@
     1.4                  if deviceGrouped
     1.5                      go Grouped;
     1.6                  do newChallengeAndNegotiationBase;
     1.7 +                debug > initial beacon
     1.8                  send Beacon;
     1.9                  go Sole;
    1.10              }
    1.11 @@ -29,10 +30,12 @@
    1.12              }
    1.13  
    1.14              on KeyGen {
    1.15 +                debug > key generated
    1.16                  send Beacon;
    1.17              }
    1.18  
    1.19 -            on CannotDecrypt { // cry baby
    1.20 +            on CannotDecrypt {
    1.21 +                debug > cry, baby
    1.22                  send Beacon;
    1.23              }
    1.24  
    1.25 @@ -43,6 +46,7 @@
    1.26                  else {
    1.27                      if weAreOfferer {
    1.28                          do useOwnChallenge;
    1.29 +                        debug > we are offerer
    1.30                          send Beacon;
    1.31                      }
    1.32                      else /* we are requester */ {
    1.33 @@ -59,7 +63,7 @@
    1.34              on NegotiationRequest {
    1.35                  if sameChallenge { // challenge accepted
    1.36                      if sameNegotiation {
    1.37 -                        // this is our own NegotiationRequest; ignore
    1.38 +                        debug > this is our own NegotiationRequest; ignore
    1.39                      }
    1.40                      else {
    1.41                          do storeNegotiation;
    1.42 @@ -72,7 +76,7 @@
    1.43  
    1.44              // we get this from an existing device group
    1.45              on NegotiationRequestGrouped {
    1.46 -                if sameChallenge { // challenge accepted
    1.47 +                if sameChallenge { debub > challenge accepted
    1.48                      do storeNegotiation;
    1.49                      // offerer is accepting by confirming NegotiationOpen
    1.50                      send NegotiationOpen;
    1.51 @@ -81,7 +85,7 @@
    1.52              }
    1.53  
    1.54              on NegotiationOpen if sameNegotiationAndPartner {
    1.55 -                // requester is receiving NegotiationOpen
    1.56 +                debug > requester is receiving NegotiationOpen
    1.57                  do storeNegotiation;
    1.58                  go HandshakingRequester;
    1.59              }
    1.60 @@ -238,7 +242,7 @@
    1.61          state FormingGroupOfferer {
    1.62              on Init {
    1.63                  do prepareOwnKeys;
    1.64 -                send OwnKeysOfferer; // we're not grouped yet, this is our own keys
    1.65 +                send OwnKeysOfferer; debug > we're not grouped yet, this is our own keys
    1.66              }
    1.67  
    1.68              on Cancel {
    1.69 @@ -325,7 +329,7 @@
    1.70              }
    1.71  
    1.72              on InitUnledGroupKeyReset {
    1.73 -                // unled group key reset; new group keys will be elected
    1.74 +                debug > unled group key reset; new group keys will be elected
    1.75                  do unledGroupKeyReset;
    1.76                  send GroupKeyReset;
    1.77              }
    1.78 @@ -333,11 +337,11 @@
    1.79              on GroupKeyReset if fromGroupMember { // double check
    1.80                  do saveGroupKeys;
    1.81                  if isLedGroupKeyReset {
    1.82 -                    // led group key reset is executed without questions
    1.83 +                    debug > led group key reset is executed without questions
    1.84                      do receivedKeysAreDefaultKeys;
    1.85                  }
    1.86                  else {
    1.87 -                    // unled group key reset; election takes place
    1.88 +                    debug > unled group key reset; election takes place
    1.89                      if keyElectionWon {
    1.90                          // this is already the case:
    1.91                          // do ownKeysAreDefaultKeys;