[Top][All Lists]

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

[lwip-devel] [bug #50411] ip6addr_aton() fails on IPv4 mapped addresses

From: Joel Cunningham
Subject: [lwip-devel] [bug #50411] ip6addr_aton() fails on IPv4 mapped addresses
Date: Mon, 27 Feb 2017 10:02:55 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:51.0) Gecko/20100101 Firefox/51.0


                 Summary: ip6addr_aton() fails on IPv4 mapped addresses
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: jcunningham
            Submitted on: Mon 27 Feb 2017 03:02:54 PM UTC
                Category: IPv6
                Severity: 3 - Normal
              Item Group: Faulty Behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: None
            lwIP version: git head



I was testing out some of the socket examples with an IPv4 mapped IPv6 address
and found that ip6addr_aton() fails when encountering the dotted quads section
of the IPv4 mapped address

#define SOCK_TARGET_HOST6  "::FFFF:"

socket_examples_init() calls ip6addr_aton() which hits the "unexpected digit"
case when the first dot is encountered:

if (s[1] == ':') {
} else if (isxdigit(*s)) {
  /* add current digit */
  current_block_value = (current_block_value << 4) +
      (isdigit(*s) ? (u32_t)(*s - '0') :
      (u32_t)(10 + (islower(*s) ? *s - 'a' : *s - 'A')));
} else {
  /* unexpected digit, space? CRLF? */


Reply to this item at:


  Message sent via/by Savannah

reply via email to

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