From owner-freebsd-pf@freebsd.org Thu Oct 6 08:31:00 2016 Return-Path: Delivered-To: freebsd-pf@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D9750BD3A63 for ; Thu, 6 Oct 2016 08:31:00 +0000 (UTC) (envelope-from franco@lastsummer.de) Received: from host64.shmhost.net (unknown [IPv6:2a01:4f8:a0:51d6::108:1]) (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 A20CBC21; Thu, 6 Oct 2016 08:31:00 +0000 (UTC) (envelope-from franco@lastsummer.de) Received: from francos-mbp.homeoffice.local (ipservice-092-208-160-166.092.208.pools.vodafone-ip.de [92.208.160.166]) by host64.shmhost.net (Postfix) with ESMTPSA id 8FC0083717; Thu, 6 Oct 2016 10:30:49 +0200 (CEST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Subject: Re: dscp set/get From: Franco Fichtner In-Reply-To: <311888F1-3BD6-4C4E-818D-C4A9C00B55ED@FreeBSD.org> Date: Thu, 6 Oct 2016 10:30:48 +0200 Cc: "Eugene M. Zheganin" , "freebsd-pf@freebsd.org" Content-Transfer-Encoding: 7bit Message-Id: References: <57F5D9D2.1060103@norma.perm.ru> <311888F1-3BD6-4C4E-818D-C4A9C00B55ED@FreeBSD.org> To: Kristof Provost X-Mailer: Apple Mail (2.3124) X-Virus-Scanned: clamav-milter 0.99.2 at host64.shmhost.net X-Virus-Status: Clean X-BeenThere: freebsd-pf@freebsd.org X-Mailman-Version: 2.1.23 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: Thu, 06 Oct 2016 08:31:00 -0000 Hi, > On 06 Oct 2016, at 10:10 AM, Kristof Provost wrote: > > On 6 Oct 2016, at 6:57, Eugene M. Zheganin wrote: >> pf still lacks the DSCP handling, will it be difficult/expensive to add >> this ? AFAIK ipfw got this recently. >> > pf has set-tos and tos keywords. What is it not letting you do? I think it works already with the plain hex/decimal values given, though we're missing OpenBSD's parser support for special DSCP options with its funky naming: "This rule applies to packets with the specified TOS bits set. string may be one of critical, inetcontrol, lowdelay, netcontrol,throughput, reliability, or one of the DiffServ Code Points: ef, af11 ... af43, cs0 ... cs7; number may be either a hex or decimal number." http://man.openbsd.org/OpenBSD-current/man5/pf.conf.5 Looks like pfctl(8) is the only thing to "fix" here. I'll take a look. Cheers, Franco