Re: [spfbis] RFC6147 and RFC7208 interoperability issues

Klaus Frank <klaus.frank@posteo.de> Mon, 07 February 2022 01:08 UTC

Return-Path: <klaus.frank@posteo.de>
X-Original-To: spfbis@ietfa.amsl.com
Delivered-To: spfbis@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id B00AE3A10D0 for <spfbis@ietfa.amsl.com>; Sun, 6 Feb 2022 17:08:02 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level:
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=posteo.de
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1Z5trFgVuE6U for <spfbis@ietfa.amsl.com>; Sun, 6 Feb 2022 17:07:57 -0800 (PST)
Received: from mout01.posteo.de (mout01.posteo.de [185.67.36.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id C4C363A10CE for <spfbis@ietf.org>; Sun, 6 Feb 2022 17:07:55 -0800 (PST)
Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id C4DF1240026 for <spfbis@ietf.org>; Mon, 7 Feb 2022 02:07:53 +0100 (CET)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1644196073; bh=nfUabnfHe2Ws2qH+7S93y+Df/tuBwelwogJCZy2+Ros=; h=Date:Subject:To:From:From; b=JnLnTpKGcsQM5Z1Sk9lTV/EH/DgBeCKcLH+cm4BGNKkF2OCF5FwWrgkvlIJmv2O/D xWNDofHb7uu9WoXcTXPqJKozyWQM6OWDeFY9EdlN848vZfkbdppWZkgQCtOc4ek77y pjawVXSoGmwZ/Uo6ni3G7QSSHVsj+k9dsGWGiqVUyrWBB3ctx6wleqvxOQ+1vbcads tGgjrnTM/tNiGIUCsnHfoHjARNdGzwN8dF+8JCnRsLg6n0aIPFQetjD2Mnm6TIUwIj DkTQPAtO6AAB9yfrIkpKQSL0lvPGZSrnCTHdwvAHHI2cMBk3lhnYjMya2WqCGT4ud4 4Z/81h2uawXpQ==
Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JsSgF2Ps6z9rxF for <spfbis@ietf.org>; Mon, 7 Feb 2022 02:07:53 +0100 (CET)
Message-ID: <f2fccd74-355e-12b4-6b8a-539f61561a12@posteo.de>
Date: Mon, 07 Feb 2022 01:07:51 +0000
MIME-Version: 1.0
Content-Language: en-US
To: spfbis@ietf.org
References: <45e423cc-4095-cca2-bf8c-aa15e977b19c@posteo.de> <8021771.rLJEViv2lv@localhost> <85cb8ec0-4316-c4db-4aed-2d49fda46f49@posteo.de> <45673006.FIhfuaby8d@localhost> <20220206224715.kzynnbwkt5a26wii@crankycanuck.ca> <7ddee9f68efbef4bcf2dbfef69b0766a@leibzon.org>
From: Klaus Frank <klaus.frank@posteo.de>
In-Reply-To: <7ddee9f68efbef4bcf2dbfef69b0766a@leibzon.org>
Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg="sha-512"; boundary="------------ms060600050103090301040507"
Archived-At: <https://mailarchive.ietf.org/arch/msg/spfbis/C1boga9kdg2vqMPy82pOVdVVvXw>
Subject: Re: [spfbis] RFC6147 and RFC7208 interoperability issues
X-BeenThere: spfbis@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: SPFbis discussion list <spfbis.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/spfbis>, <mailto:spfbis-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/spfbis/>
List-Post: <mailto:spfbis@ietf.org>
List-Help: <mailto:spfbis-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/spfbis>, <mailto:spfbis-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 07 Feb 2022 01:08:03 -0000

On 2022-02-07 01:42, william@leibzon.org wrote:
>
> Yeah, I wasn't thrilled with the idea of SPF using TXT record way back 
> when. It opened it for quite a few others who followed. Putting ip 
> addresses there though is not something that is done for any other 
> protocol or software I can immediately think of.
>
> I'm curious, how does DNS64 inter-operates with DNSSEC? Would that not 
> break it and make DNSSEC folks very uncomfortable about what others 
> could decide to do?
>
Basically by offloading it towards the DNS64 server.

https://datatracker.ietf.org/doc/html/rfc6147#section-6.2

6.2.  DNSSEC Validators and DNS64

    An existing DNSSEC validator (i.e., one that is unaware of DNS64)
    might reject all the data that comes from DNS64 as having been
    tampered with (even if it did not set CD when querying). *If it is**
**   necessary to have validation behind the DNS64, then the validator**
**   must know how to perform the DNS64 function itself*. Alternatively,
    the validating host may establish a trusted connection with a DNS64,
    and allow the DNS64 recursive resolver to do all validation on its
    behalf.

> I think it could be helpful to collect various protocol operational 
> and similar issues for those running mail servers (and other servers) 
> behind NAT64 and write informational RFC which would be soft of 
> experimental best practice. I'd expect that some server software would 
> have to add special features to be used in this setup.
>
"special features" is exactly what I wanted to avoid. Also I don't know 
if it's strictly necessary to have a dedicated RFC for how to do the 
migration. Besides this issue with the SPF record it's basically the 
same as for any other server application. Use stateless NAT64 (aka. 
IPv4aaS) to have a dedicated public IPv4. Put that IPv4 (prefix) into 
the SPF record as usual. And for now disable the SPF validation for 
inbound mails. The only really noteworthy thing is with filtering stuff 
like SIEVE that these need to be updated to include their mapped IPv6 
addresses or similar. Everything else just works because of NAT64 and 
DNS64...

> On 2022-02-06 14:47, Andrew Sullivan wrote:
>
>> Hi,
>>
>> I'm one of the primary offenders behind DNS64.  I work for the Internet Society but I am not speaking for them (or anyone eles) right now.
>>
>> On Sun, Feb 06, 2022 at 02:57:08PM -0500, Scott Kitterman wrote:
>>
>>> I think your original suggestion that an SPF record be modified by the DNS64
>>> server to add ip6: mechanisms with <prefix> + <address> is a reasonable path
>>> forward, but I think it's really an RFC 6147 discussion, not so much RFC 7208.
>>
>> The problem with this is that it's importing the DNS64 intimate knowledge of this protocol for TXT records, which means in effect that DNS64 needs to start parsing arbitrary data in TXT records.  (There is a reason DNS weenies always got upset about ignoring the strong typing in DNS, and this is an example of it.)
>>
>> DNS64, to be honest, was always sort of a hack that was intended to make transition to v6 easier.  It really basically depended on the strong data typing of A, AAAA, and PTR records in order to give it clear places to insert itself.  "Look at every TXT record," doesn't really support that plan.  I never thought we were designing it for long life or high degrees of robustness, and I think it is likely to be extremely difficult to operate a modern mail server on v6-only infrastructure and be able to talk to v4-only mail servers.  In any case, I guess it would be _possible_ to teach a DNS64 server to parse and edit TXT records on the fly, but the idea that this is going to be limited to SPF is, I suspect, a false hope.  For that reason, my reaction is that it wouldn't be a great idea to do.  I nevertheless sympathize with the desire, even though I am made nervous about the implications.
>>
>>> It is not, however, without risks.  RFC 7208 Section 3.4 gives advice on SPF
>>> record size.  Your proposed approach would increase the record size, which, in
>>> theory, could be problematic.  It might be that anything running on an IPv6
>>> only network is modern enough that this isn't actually a problem.  I don't
>>> know.
>>
>> I'd be especially worried about RRset size, because a lot of stuff in contemporary operations is jammed into TXT records (all those application keys, for instance).  I can imagine cases where the change could move the response size across the response size boundary, forcing truncation and TCP fallback.
>>
>> Best regards,
>>
>> A
>
> _______________________________________________
> spfbis mailing list
> spfbis@ietf.org
> https://www.ietf.org/mailman/listinfo/spfbis