[Slirp] [Git][slirp/libslirp][master] 2 commits: Use target address from Neighbor Advertisement

Samuel Thibault (@sthibaul) gitlab at gitlab.freedesktop.org
Sun Aug 7 19:22:53 UTC 2022



Samuel Thibault pushed to branch master at slirp / libslirp


Commits:
1feabfef by Bastian Blank at 2022-08-07T12:51:22+02:00
Use target address from Neighbor Advertisement

The IPv6 support in libslirp fails to work with any NDP proxy.  The code
used to interpret the NA packets uses the wrong address to insert into
it's neighbor table, the address of the source of the packet, aka the
proxy itself.

However the NA packet got the real target address readily available.
Just use it directly instead.

Signed-off-by: Bastian Blank <waldi at debian.org>

- - - - -
c7c151fe by Samuel Thibault at 2022-08-07T19:22:49+00:00
Merge branch 'icmp6-na-use-target' into 'master'

Use target address from Neighbor Advertisement

See merge request slirp/libslirp!129
- - - - -


1 changed file:

- src/ip6_icmp.c


Changes:

=====================================
src/ip6_icmp.c
=====================================
@@ -367,7 +367,7 @@ static void ndp_input(struct mbuf *m, Slirp *slirp, struct ip6 *ip,
             ntohs(ip->ip_pl) >= ICMP6_NDP_NA_MINLEN &&
             !IN6_IS_ADDR_MULTICAST(&icmp->icmp6_nna.target) &&
             (!IN6_IS_ADDR_MULTICAST(&ip->ip_dst) || icmp->icmp6_nna.S == 0)) {
-            ndp_table_add(slirp, ip->ip_src, eth->h_source);
+            ndp_table_add(slirp, icmp->icmp6_nna.target, eth->h_source);
         }
         break;
 



View it on GitLab: https://gitlab.freedesktop.org/slirp/libslirp/-/compare/7132fef2a6b08d270b412d37a4c38b34728993ea...c7c151fe3a2700bcabfc07235176fcedf7e9b089

-- 
View it on GitLab: https://gitlab.freedesktop.org/slirp/libslirp/-/compare/7132fef2a6b08d270b412d37a4c38b34728993ea...c7c151fe3a2700bcabfc07235176fcedf7e9b089
You're receiving this email because of your account on gitlab.freedesktop.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/slirp/attachments/20220807/36bc09d7/attachment.htm>


More information about the Slirp mailing list