public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
* [PATCH v2 0/6] Improve IPv4 address endian handling and related bug fixes
@ 2022-11-04  3:10 David Gibson
  2022-11-04  3:10 ` [PATCH v2 1/6] Correct some missing endian conversions of IPv4 addresses David Gibson
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: David Gibson @ 2022-11-04  3:10 UTC (permalink / raw)
  To: passt-dev, Stefano Brivio; +Cc: David Gibson

While working on allowing us to use IPv4/IPv6 combined listening
sockets, I made several endian mistakes.  So, I took a diversion to
make it harder to make such mistakes.

Along the way I found some small existing endian and other bugs in
IPv4 address handling.

Changes since v1:
 * Added extra patch making more safety conversion
 * Added extra patch making some tangentially related comment fixes

David Gibson (6):
  Correct some missing endian conversions of IPv4 addresses
  Minor improvements to IPv4 netmask handling
  Use IPV4_IS_LOOPBACK more widely
  Use typing to reduce chances of IPv4 endianness errors
  Use endian-safer typing in struct tap4_l4_t
  tcp: Correct function comments for address types

 checksum.c |   7 ++--
 checksum.h |   3 +-
 conf.c     | 118 ++++++++++++++++++++++++++++++-----------------------
 dhcp.c     |  15 ++++---
 icmp.c     |   5 +--
 passt.c    |   2 +-
 passt.h    |  16 ++++----
 pasta.c    |   7 +---
 tap.c      |  49 +++++++++++-----------
 tap.h      |   8 ++--
 tcp.c      |  60 +++++++++++++--------------
 tcp.h      |   2 +-
 udp.c      |  30 +++++++-------
 udp.h      |   2 +-
 util.h     |  12 +++++-
 15 files changed, 182 insertions(+), 154 deletions(-)

-- 
2.38.1


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-11-04  3:10 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-04  3:10 [PATCH v2 0/6] Improve IPv4 address endian handling and related bug fixes David Gibson
2022-11-04  3:10 ` [PATCH v2 1/6] Correct some missing endian conversions of IPv4 addresses David Gibson
2022-11-04  3:10 ` [PATCH v2 2/6] Minor improvements to IPv4 netmask handling David Gibson
2022-11-04  3:10 ` [PATCH v2 3/6] Use IPV4_IS_LOOPBACK more widely David Gibson
2022-11-04  3:10 ` [PATCH v2 4/6] Use typing to reduce chances of IPv4 endianness errors David Gibson
2022-11-04  3:10 ` [PATCH v2 5/6] Use endian-safer typing in struct tap4_l4_t David Gibson
2022-11-04  3:10 ` [PATCH v2 6/6] tcp: Correct function comments for address types David Gibson

Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).