From owner-freebsd-pf@freebsd.org Mon Oct 12 21:48:18 2020 Return-Path: Delivered-To: freebsd-pf@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A3C8B429382 for ; Mon, 12 Oct 2020 21:48:18 +0000 (UTC) (envelope-from longwitz@incore.de) Received: from dss.incore.de (dss.incore.de [195.145.1.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9C3P5zGXz3Sxw for ; Mon, 12 Oct 2020 21:48:17 +0000 (UTC) (envelope-from longwitz@incore.de) Received: from inetmail.dmz (inetmail.dmz [10.3.0.3]) by dss.incore.de (Postfix) with ESMTP id C7FA73AD9F; Mon, 12 Oct 2020 23:48:09 +0200 (CEST) X-Virus-Scanned: amavisd-new at incore.de Received: from dss.incore.de ([10.3.0.3]) by inetmail.dmz (inetmail.dmz [10.3.0.3]) (amavisd-new, port 10024) with LMTP id Ws_DP83_77qj; Mon, 12 Oct 2020 23:48:09 +0200 (CEST) Received: from mail.local.incore (fwintern.dmz [10.0.0.253]) by dss.incore.de (Postfix) with ESMTP id 1E2DB3AD7F; Mon, 12 Oct 2020 23:48:09 +0200 (CEST) Received: from bsdmhs.longwitz (unknown [192.168.99.6]) by mail.local.incore (Postfix) with ESMTP id 0319D11F; Mon, 12 Oct 2020 23:48:08 +0200 (CEST) Message-ID: <5F84CF18.1040905@incore.de> Date: Mon, 12 Oct 2020 23:48:08 +0200 From: Andreas Longwitz User-Agent: Thunderbird 2.0.0.19 (X11/20090113) MIME-Version: 1.0 To: J David CC: freebsd-pf@freebsd.org Subject: Re: Packets passed by pf don't make it out? References: <5F8336C7.5020709@incore.de> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4C9C3P5zGXz3Sxw X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of longwitz@incore.de designates 195.145.1.138 as permitted sender) smtp.mailfrom=longwitz@incore.de X-Spamd-Result: default: False [-1.49 / 15.00]; RCVD_TLS_LAST(0.00)[]; ARC_NA(0.00)[]; RCVD_COUNT_FIVE(0.00)[5]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; NEURAL_HAM_LONG(-0.97)[-0.971]; TAGGED_RCPT(0.00)[]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[incore.de]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.25)[-0.251]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_MEDIUM(-0.97)[-0.972]; FREEMAIL_TO(0.00)[gmail.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:3320, ipnet:195.145.0.0/16, country:DE]; SUBJECT_ENDS_QUESTION(1.00)[]; MAILMAN_DEST(0.00)[freebsd-pf] X-BeenThere: freebsd-pf@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: "Technical discussion and general questions about packet filter \(pf\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Oct 2020 21:48:18 -0000 Hello, now I can confirm (on FreeBSD 10 Stable) what you see on fb2 when your program udp_client is running on fb1. pf creates a state for the first packet only, for the other packets pf failes to create a state with messages like pf: stack key attach failed on re0: UDP in wire: 192.168.14.10:23456 172.16.0.2:12345 stack: 192.168.14.10:23456 192.168.14.100:12345 1:0, existing: UDP in wire: 192.168.14.10:23456 172.16.0.1:12345 stack: 192.168.14.10:23456 192.168.14.100:12345 1:0 pf gives this messages in debug mode (pfctl -x loud). I do not know if we see a bug in pf or if your program udp_client does something illegal, I think Kristof can tell us. Regards Andreas