[riot-notifications] [RIOT-OS/RIOT] sock_dns: fix out-of-bound errors (#10740)

Kaspar Schleiser notifications at github.com
Wed Jan 9 22:19:54 CET 2019


kaspar030 commented on this pull request.



>  
+    if (bufpos >= buflim) {
+        /* out-of-bound */
+        return -EBADMSG;
+    }
     /* handle DNS Message Compression */
     if (*bufpos >= 192) {
         return 2;

I think this line also needs a check: ```if ((bufpos + 2) >= buflim) return -EBADMSG;```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/10740#pullrequestreview-190923989
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190109/3b15634b/attachment.html>


More information about the notifications mailing list