gnunet-svn
[Top][All Lists]
Advanced

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

[gnunet-scheme] 18/49: dht/client: Correct struct access when verifying


From: gnunet
Subject: [gnunet-scheme] 18/49: dht/client: Correct struct access when verifying messages.
Date: Sat, 25 Dec 2021 22:59:55 +0100

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

maxime-devos pushed a commit to branch master
in repository gnunet-scheme.

commit e11cdb4dde4ea2b75b2f64747a318dc79450112b
Author: Maxime Devos <maximedevos@telenet.be>
AuthorDate: Fri Sep 24 20:27:36 2021 +0200

    dht/client: Correct struct access when verifying messages.
    
    * gnu/gnunet/dht/client.scm (well-formed?/path-length): Call read%
      on the header, not the full message stucture.
---
 gnu/gnunet/dht/client.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gnu/gnunet/dht/client.scm b/gnu/gnunet/dht/client.scm
index af7f1bc..53381ea 100644
--- a/gnu/gnunet/dht/client.scm
+++ b/gnu/gnunet/dht/client.scm
@@ -221,7 +221,7 @@ message header is assumed to be correct."
       (and (>= (slice-length slice) (sizeof type '()))
           (let* ((header (slice/read-only slice 0 (sizeof type '())))
                  (extra-size (- (slice-length slice) (sizeof type '())))
-                 (field (read% type '(field) slice))
+                 (field (read% type '(field) header))
                  ...)
             (compare extra-size (* (+ field ...) (sizeof /peer-identity 
'()))))))
 

-- 
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]