IOSAD-95 really needed? Backed out changeset cb0e8fd9b407
authorDirk Zimmermann <dirk@pep-project.org>
Mon, 18 Jun 2018 11:37:18 +0200
changeset 630ac0b9f0507ba
parent 629 7e6343055e4d
child 631 6c9a4f311de7
IOSAD-95 really needed? Backed out changeset cb0e8fd9b407
pEpObjCAdapter/PEPInternalSession.m
pEpObjCAdapter/PEPSession.m
pEpObjCAdapter/PEPSessionProtocol.h
     1.1 --- a/pEpObjCAdapter/PEPInternalSession.m	Mon Jun 18 11:37:17 2018 +0200
     1.2 +++ b/pEpObjCAdapter/PEPInternalSession.m	Mon Jun 18 11:37:18 2018 +0200
     1.3 @@ -267,11 +267,12 @@
     1.4  
     1.5  - (PEPDict * _Nullable)encryptMessageDict:(PEPDict * _Nonnull)messageDict
     1.6                                  extraKeys:(PEPStringList * _Nullable)extraKeys
     1.7 -                                    flags:(PEP_encrypt_flags_t)flags
     1.8                                  encFormat:(PEP_enc_format)encFormat
     1.9                                     status:(PEP_STATUS * _Nullable)status
    1.10                                      error:(NSError * _Nullable * _Nullable)error
    1.11  {
    1.12 +    PEP_encrypt_flags_t flags = 0;
    1.13 +
    1.14      message *_src = PEP_messageDictToStruct([self removeEmptyRecipients:messageDict]);
    1.15      message *_dst = NULL;
    1.16      stringlist_t *_keys = PEP_arrayToStringlist(extraKeys);
    1.17 @@ -305,15 +306,13 @@
    1.18  }
    1.19  
    1.20  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    1.21 -                               extraKeys:(PEPStringList * _Nullable)extraKeys
    1.22 -                                   flags:(PEP_encrypt_flags_t)flags
    1.23 +                                   extraKeys:(PEPStringList * _Nullable)extraKeys
    1.24                                 encFormat:(PEP_enc_format)encFormat
    1.25                                    status:(PEP_STATUS * _Nullable)status
    1.26                                     error:(NSError * _Nullable * _Nullable)error
    1.27  {
    1.28      PEPDict *encryptedDict = [self encryptMessageDict:(NSDictionary *) message
    1.29                                              extraKeys:extraKeys
    1.30 -                                                flags:flags
    1.31                                              encFormat:encFormat
    1.32                                                 status:status
    1.33                                                  error:error];
    1.34 @@ -327,15 +326,13 @@
    1.35  }
    1.36  
    1.37  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    1.38 -                               extraKeys:(PEPStringList * _Nullable)extraKeys
    1.39 -                                   flags:(PEP_encrypt_flags_t)flags
    1.40 +                                   extraKeys:(PEPStringList * _Nullable)extraKeys
    1.41                                    status:(PEP_STATUS * _Nullable)status
    1.42                                     error:(NSError * _Nullable * _Nullable)error
    1.43  {
    1.44      return [self
    1.45              encryptMessage:message
    1.46              extraKeys:extraKeys
    1.47 -            flags:flags
    1.48              encFormat:PEP_enc_PEP
    1.49              status:status
    1.50              error:error];
    1.51 @@ -344,10 +341,11 @@
    1.52  - (PEPDict * _Nullable)encryptMessageDict:(PEPDict * _Nonnull)messageDict
    1.53                                    forSelf:(PEPIdentity * _Nonnull)ownIdentity
    1.54                                  extraKeys:(PEPStringList * _Nullable)extraKeys
    1.55 -                                    flags:(PEP_encrypt_flags_t)flags
    1.56                                     status:(PEP_STATUS * _Nullable)status
    1.57                                      error:(NSError * _Nullable * _Nullable)error
    1.58  {
    1.59 +    PEP_encrypt_flags_t flags = 0;
    1.60 +
    1.61      message *_src = PEP_messageDictToStruct([self removeEmptyRecipients:messageDict]);
    1.62      pEp_identity *ident = PEP_identityToStruct(ownIdentity);
    1.63      message *_dst = NULL;
    1.64 @@ -393,7 +391,6 @@
    1.65  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    1.66                                   forSelf:(PEPIdentity * _Nonnull)ownIdentity
    1.67                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    1.68 -                                   flags:(PEP_encrypt_flags_t)flags
    1.69                                    status:(PEP_STATUS * _Nullable)status
    1.70                                     error:(NSError * _Nullable * _Nullable)error
    1.71  {
    1.72 @@ -401,7 +398,6 @@
    1.73                         encryptMessageDict:message.dictionary
    1.74                         forSelf:ownIdentity
    1.75                         extraKeys:extraKeys
    1.76 -                       flags:flags
    1.77                         status:status
    1.78                         error:error];
    1.79  
     2.1 --- a/pEpObjCAdapter/PEPSession.m	Mon Jun 18 11:37:17 2018 +0200
     2.2 +++ b/pEpObjCAdapter/PEPSession.m	Mon Jun 18 11:37:18 2018 +0200
     2.3 @@ -76,7 +76,6 @@
     2.4  - (PEPDict * _Nullable)encryptMessageDict:(PEPDict * _Nonnull)messageDict
     2.5                                      extraKeys:(PEPStringList * _Nullable)extraKeys
     2.6                                  encFormat:(PEP_enc_format)encFormat
     2.7 -                                    flags:(PEP_encrypt_flags_t)flags
     2.8                                     status:(PEP_STATUS * _Nullable)status
     2.9                                      error:(NSError * _Nullable * _Nullable)error
    2.10  {
    2.11 @@ -85,7 +84,6 @@
    2.12              encryptMessageDict:messageDict
    2.13              extraKeys:extraKeys
    2.14              encFormat:encFormat
    2.15 -            flags:flags
    2.16              status:status
    2.17              error:error];
    2.18  }
    2.19 @@ -93,7 +91,6 @@
    2.20  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    2.21                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    2.22                                 encFormat:(PEP_enc_format)encFormat
    2.23 -                                   flags:(PEP_encrypt_flags_t)flags
    2.24                                    status:(PEP_STATUS * _Nullable)status
    2.25                                     error:(NSError * _Nullable * _Nullable)error
    2.26  {
    2.27 @@ -102,30 +99,22 @@
    2.28              encryptMessage:message
    2.29              extraKeys:extraKeys
    2.30              encFormat:encFormat
    2.31 -            flags:flags
    2.32              status:status
    2.33              error:error];
    2.34  }
    2.35  
    2.36  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    2.37                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    2.38 -                                   flags:(PEP_encrypt_flags_t)flags
    2.39                                    status:(PEP_STATUS * _Nullable)status
    2.40                                     error:(NSError * _Nullable * _Nullable)error
    2.41  {
    2.42      PEPInternalSession *session = [PEPSessionProvider session];
    2.43 -    return [session
    2.44 -            encryptMessage:message
    2.45 -            extraKeys:extraKeys
    2.46 -            flags:flags
    2.47 -            status:status
    2.48 -            error:error];
    2.49 +    return [session encryptMessage:message extraKeys:extraKeys status:status error:error];
    2.50  }
    2.51  
    2.52  - (PEPDict * _Nullable)encryptMessageDict:(PEPDict * _Nonnull)messageDict
    2.53                                    forSelf:(PEPIdentity * _Nonnull)ownIdentity
    2.54                                  extraKeys:(PEPStringList * _Nullable)extraKeys
    2.55 -                                    flags:(PEP_encrypt_flags_t)flags
    2.56                                     status:(PEP_STATUS * _Nullable)status
    2.57                                      error:(NSError * _Nullable * _Nullable)error
    2.58  {
    2.59 @@ -134,7 +123,6 @@
    2.60              encryptMessageDict:messageDict
    2.61              forSelf:ownIdentity
    2.62              extraKeys:extraKeys
    2.63 -            flags:flags
    2.64              status:status
    2.65              error:error];
    2.66  }
    2.67 @@ -142,7 +130,6 @@
    2.68  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    2.69                                   forSelf:(PEPIdentity * _Nonnull)ownIdentity
    2.70                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    2.71 -                                   flags:(PEP_encrypt_flags_t)flags
    2.72                                    status:(PEP_STATUS * _Nullable)status
    2.73                                     error:(NSError * _Nullable * _Nullable)error
    2.74  {
    2.75 @@ -151,7 +138,6 @@
    2.76              encryptMessage:message
    2.77              forSelf:ownIdentity
    2.78              extraKeys:extraKeys
    2.79 -            flags:flags
    2.80              status:status
    2.81              error:error];
    2.82  }
     3.1 --- a/pEpObjCAdapter/PEPSessionProtocol.h	Mon Jun 18 11:37:17 2018 +0200
     3.2 +++ b/pEpObjCAdapter/PEPSessionProtocol.h	Mon Jun 18 11:37:18 2018 +0200
     3.3 @@ -54,7 +54,6 @@
     3.4   */
     3.5  - (PEPDict * _Nullable)encryptMessageDict:(PEPDict * _Nonnull)messageDict
     3.6                                  extraKeys:(PEPStringList * _Nullable)extraKeys
     3.7 -                                    flags:(PEP_encrypt_flags_t)flags
     3.8                                  encFormat:(PEP_enc_format)encFormat
     3.9                                     status:(PEP_STATUS * _Nullable)status
    3.10                                      error:(NSError * _Nullable * _Nullable)error __deprecated;
    3.11 @@ -65,7 +64,6 @@
    3.12   */
    3.13  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    3.14                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    3.15 -                                   flags:(PEP_encrypt_flags_t)flags
    3.16                                 encFormat:(PEP_enc_format)encFormat
    3.17                                    status:(PEP_STATUS * _Nullable)status
    3.18                                     error:(NSError * _Nullable * _Nullable)error;
    3.19 @@ -73,7 +71,6 @@
    3.20  /** Encrypt a message with default encryption format (PEP_enc_PEP) */
    3.21  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    3.22                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    3.23 -                                   flags:(PEP_encrypt_flags_t)flags
    3.24                                    status:(PEP_STATUS * _Nullable)status
    3.25                                     error:(NSError * _Nullable * _Nullable)error;
    3.26  
    3.27 @@ -81,7 +78,6 @@
    3.28  - (PEPDict * _Nullable)encryptMessageDict:(PEPDict * _Nonnull)messageDict
    3.29                                    forSelf:(PEPIdentity * _Nonnull)ownIdentity
    3.30                                  extraKeys:(PEPStringList * _Nullable)extraKeys
    3.31 -                                    flags:(PEP_encrypt_flags_t)flags
    3.32                                     status:(PEP_STATUS * _Nullable)status
    3.33                                      error:(NSError * _Nullable * _Nullable)error __deprecated;
    3.34  
    3.35 @@ -89,7 +85,6 @@
    3.36  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    3.37                                   forSelf:(PEPIdentity * _Nonnull)ownIdentity
    3.38                                 extraKeys:(PEPStringList * _Nullable)extraKeys
    3.39 -                                   flags:(PEP_encrypt_flags_t)flags
    3.40                                    status:(PEP_STATUS * _Nullable)status
    3.41                                     error:(NSError * _Nullable * _Nullable)error;
    3.42