From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=none (p=none dis=none) header.from=njh.eu Received: from mail.notjusthosting.com (mail.notjusthosting.com [IPv6:2a01:4f8:a0:516f:1::1]) by passt.top (Postfix) with ESMTPS id 69D1F5A0271 for ; Thu, 11 Sep 2025 22:19:26 +0200 (CEST) Received: from echelon-telekom.c-base.org ([80.147.140.51] helo=vlap) by mail.notjusthosting.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1uwnlN-0006Ny-SM; Thu, 11 Sep 2025 22:19:25 +0200 From: Volker Diels-Grabsch To: passt-dev@passt.top Subject: [PATCH v5 1/5] Show debug message whenever we learn a new guest MAC address Date: Thu, 11 Sep 2025 22:18:57 +0200 Message-ID: <20250911201900.237677-2-v@njh.eu> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-ID-Hash: 66YKGIIXRXHZ6YPQLZBTXIJHZZZSMDRH X-Message-ID-Hash: 66YKGIIXRXHZ6YPQLZBTXIJHZZZSMDRH X-MailFrom: v@njh.eu X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Volker Diels-Grabsch X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Signed-off-by: Volker Diels-Grabsch --- tap.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tap.c b/tap.c index 7ba6399..3c08126 100644 --- a/tap.c +++ b/tap.c @@ -1096,7 +1096,11 @@ void tap_add_packet(struct ctx *c, struct iov_tail *data, return; if (memcmp(c->guest_mac, eh->h_source, ETH_ALEN)) { + char bufmac[ETH_ADDRSTRLEN]; + memcpy(c->guest_mac, eh->h_source, ETH_ALEN); + debug("Guest MAC address: %s", + eth_ntop(c->guest_mac, bufmac, sizeof(bufmac))); proto_update_l2_buf(c->guest_mac, NULL); } -- 2.47.3