gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnunet] branch master updated: TNG: Sanitize struct members in UDP comm


From: gnunet
Subject: [gnunet] branch master updated: TNG: Sanitize struct members in UDP communicator signatures and packets.
Date: Thu, 27 Jul 2023 22:16:30 +0200

This is an automated email from the git hooks/post-receive script.

martin-schanzenbach pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new 526a111bd TNG: Sanitize struct members in UDP communicator signatures 
and packets.
526a111bd is described below

commit 526a111bd9dc0c83def348ebed63d527b7bbb4f4
Author: Martin Schanzenbach <schanzen@gnunet.org>
AuthorDate: Thu Jul 27 22:15:57 2023 +0200

    TNG: Sanitize struct members in UDP communicator signatures and packets.
---
 src/transport/gnunet-communicator-udp.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/transport/gnunet-communicator-udp.c 
b/src/transport/gnunet-communicator-udp.c
index c26a3b11f..1d80b5abc 100644
--- a/src/transport/gnunet-communicator-udp.c
+++ b/src/transport/gnunet-communicator-udp.c
@@ -206,12 +206,12 @@ struct InitialKX
    * HMAC for the following encrypted message, using GCM.  HMAC uses
    * key derived from the handshake with sequence number zero.
    */
-  char gcm_tag[GCM_TAG_SIZE];
+  uint8_t gcm_tag[GCM_TAG_SIZE];
 
   /**
    * A flag indicating, if the sender is doing rekeying.
    */
-  int rekeying;
+  uint16_t rekeying;
 };
 
 
@@ -343,12 +343,12 @@ struct UDPBox
    * wrong, the receiver should check if the message might be a
    * `struct UdpHandshakeSignature`.
    */
-  char gcm_tag[GCM_TAG_SIZE];
+  uint8_t gcm_tag[GCM_TAG_SIZE];
 
   /**
    * A flag indicating, if the sender is doing rekeying.
    */
-  int rekeying;
+  uint16_t rekeying;
 };
 
 /**
@@ -373,7 +373,7 @@ struct UDPRekey
    * wrong, the receiver should check if the message might be a
    * `struct UdpHandshakeSignature`.
    */
-  char gcm_tag[GCM_TAG_SIZE];
+  uint8_t gcm_tag[GCM_TAG_SIZE];
 
   /**
    * Sender's identity
@@ -517,7 +517,7 @@ struct SenderAddress
   /**
    * Flag indicating sender is initiated rekeying for this receiver.
    */
-  int rekeying;
+  uint16_t rekeying;
 
   /**
    * To whom are we talking to.
@@ -623,7 +623,7 @@ struct ReceiverAddress
   /**
    * Flag indicating sender is initiated rekeying for this receiver.
    */
-  int rekeying;
+  uint16_t rekeying;
 
   /**
    * Number of kce we retain for sending the rekeying shared secret.
@@ -1337,7 +1337,7 @@ setup_cipher (const struct GNUNET_HashCode *msec,
  */
 static int
 try_decrypt (const struct SharedSecret *ss,
-             const char tag[GCM_TAG_SIZE],
+             const uint8_t *tag,
              uint32_t serial,
              const char *in_buf,
              size_t in_buf_size,

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]