Re: [ietf-smtp] [Emailcore] Proposed ESMTP keyword RCPTLIMIT

John R Levine <johnl@taugh.com> Tue, 20 April 2021 15:01 UTC

Return-Path: <johnl@taugh.com>
X-Original-To: ietf-smtp@ietfa.amsl.com
Delivered-To: ietf-smtp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 0C01B3A2720 for <ietf-smtp@ietfa.amsl.com>; Tue, 20 Apr 2021 08:01:15 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.1
X-Spam-Level:
X-Spam-Status: No, score=-2.1 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, 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=iecc.com header.b=dfODV+RV; dkim=pass (2048-bit key) header.d=taugh.com header.b=eyK1uOzN
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 BWMwAKQ-VAaP for <ietf-smtp@ietfa.amsl.com>; Tue, 20 Apr 2021 08:01:08 -0700 (PDT)
Received: from gal.iecc.com (gal.iecc.com [IPv6:2001:470:1f07:1126:0:43:6f73:7461]) (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 97F0B3A2729 for <ietf-smtp@ietf.org>; Tue, 20 Apr 2021 08:01:08 -0700 (PDT)
Received: (qmail 29517 invoked from network); 20 Apr 2021 15:01:05 -0000
DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=iecc.com; h=date:message-id:from:to:cc:subject:in-reply-to:references:mime-version:content-type; s=734b.607eecb1.k2104; bh=izSatUf2wQRGXL2MFcW/Y+n8fQCeU8eW+ZUsu68gG2k=; b=dfODV+RV82nqKMuWoq5MvDicGPetxjiNU0dm0fKjtfO4b/SUtA24PKRGxmr7DJKTGCpH0XmFH2o55wZwTPvc9fckNKHFoHkRFde7nCsYXfrXy36dCawMrNood8E8BCUdC0/DQd9N/7SbheO9RqSXsruQqc1lO475RvlWtMzn8ispryDnriF0wfNTh5WCZLXF+jLXMCPYj96vSwV3elWy+iTfL7sTo23zBlAZISxz9Eyt025lQ/P7ObFTkQJTUA3EWCWzJgRjZxweA8yfQyG5pP+qfv7YoSf65fZtiXxnEpBkPSaxw96xbLav+S2b7w5IKzOEtojU8kAFPwQMM/kIDQ==
DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=taugh.com; h=date:message-id:from:to:cc:subject:in-reply-to:references:mime-version:content-type; s=734b.607eecb1.k2104; bh=izSatUf2wQRGXL2MFcW/Y+n8fQCeU8eW+ZUsu68gG2k=; b=eyK1uOzNOusDqoTnSRj7+zYhNWmNlrMx1W5Q0Pp3wRWEr72CBeXWPndzWWQZFovoO5OIC4slR32l+f+eVdCpxuQmp+dXkR5VnwrlqRxy4cYqegzM11NHo+lCRwMLGPANMHc749AQoApTUco4qaUaTWTYDtYawxN/KHYO64gEAxmSVbSV4PXw3WkmXyf0ANiagGH9ZT2UXY7qKCJlufWRgt7s/g/aTlve87R6GCJcKNcQPSxSqmONkybvLVOOncdbixZI6AVMxNPuMgrk9eDZ0i6rAJ6wYx2HkSppGM328njc3Bmcv1uIasvjBWdRQHURbAShyzlAoEMapyILKzE8UQ==
Received: from ary.qy ([IPv6:2001:470:1f07:1126::78:696d:6170]) by imap.iecc.com ([IPv6:2001:470:1f07:1126::78:696d:6170]) with ESMTPS (TLS1.2 ECDHE-RSA AES-256-GCM AEAD) via TCP6; 20 Apr 2021 15:01:04 -0000
Received: by ary.qy (Postfix, from userid 501) id 5F57E73B63E7; Tue, 20 Apr 2021 11:01:04 -0400 (EDT)
Received: from localhost (localhost [127.0.0.1]) by ary.qy (Postfix) with ESMTP id 01F9273B63C9; Tue, 20 Apr 2021 11:01:03 -0400 (EDT)
Date: Tue, 20 Apr 2021 11:01:03 -0400
Message-ID: <d792943-a35f-bb15-84de-eadd72c92b9b@taugh.com>
From: John R Levine <johnl@taugh.com>
To: Ned Freed <ned.freed@mrochek.com>
Cc: "ietf-smtp@ietf.org" <ietf-smtp@ietf.org>
X-X-Sender: johnl@ary.qy
In-Reply-To: <01RY34ECJRWG0085YQ@mauve.mrochek.com>
References: <cone.1615844513.220592.51342.1004@monster.email-scan.com> <20210315234648.563C0708B340@ary.qy> <CAO=DXp-+fJwsNegzu3zgwDLtCcSF104AUF=i+_GMgSYVBAKjWg@mail.gmail.com> <01RY24IJ225Q0085YQ@mauve.mrochek.com> <4fe09f20-66ee-b3c-94bb-be654b8354bc@taugh.com> <01RY292U84V40085YQ@mauve.mrochek.com> <BN6PR22MB022669CD015B89D47AA063F3DA489@BN6PR22MB0226.namprd22.prod.outlook.com> <01RY34ECJRWG0085YQ@mauve.mrochek.com>
MIME-Version: 1.0
Content-Type: text/plain; charset="US-ASCII"; format="flowed"
Archived-At: <https://mailarchive.ietf.org/arch/msg/ietf-smtp/mVcEVFgYHEREtS_zKUSJzHPoy7I>
Subject: Re: [ietf-smtp] [Emailcore] Proposed ESMTP keyword RCPTLIMIT
X-BeenThere: ietf-smtp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Discussion of issues related to Simple Mail Transfer Protocol \(SMTP\) \[RFC 821, RFC 2821, RFC 5321\]" <ietf-smtp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ietf-smtp>, <mailto:ietf-smtp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ietf-smtp/>
List-Post: <mailto:ietf-smtp@ietf.org>
List-Help: <mailto:ietf-smtp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ietf-smtp>, <mailto:ietf-smtp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Apr 2021 15:01:15 -0000

It looks like something like this would handle a lot, quite possibly most, 
of the rate limits that receivers are willing to disclose:

   CONNRATE=m/s MSGRATE=m/s

Where m is a number of connections or messages or whatever, and s is a 
number of seconds.

I suppose it could also have something like SCOPE=HOST or SCOPE=GROUP to 
say whether it's for a single host or a group but I don't see any way of 
describing groups that wouldn't be too complicated and I doubt that many 
mail providers would want to tell hostile strangers that much about their 
internal architecture.

R's,
John


On Tue, 20 Apr 2021, Ned Freed wrote:
>>> A little surveying might be in order.
>
>>> I see that Postfix lets you set both the numerator and denominator of
>>> the rate limit, but the denominator defaults to a minute.  It has
>>> separate rate limits for connections and messages.
>
>>> Exim also lets you set both, the examples use an hour.  The
>>> documentation says that if you use a large interval that lets people send bursts.
>
>> Sounds familiar. Oracle Messaging Server lets you set both; the denominator default is one hour.
>
>> We store the limits in memcache or Redis so they can apply across mutiple MTAs.
>> The usual limit is per-IP, but we support per-host and per-domain as well.
>
>> The demoninator in PowerMTA is a string rather than a number, possible values are sec, s, min, m, hr, or h. It supports per-IP and per-host and probably other stuff; my familiarity here is limited.
>
>> I assume the Exim and Postfix limits are per-host, which in most cases translates to per-IP.
>
>> I have to say there's more consistency here than I expected.


Regards,
John Levine, johnl@taugh.com, Taughannock Networks, Trumansburg NY
Please consider the environment before reading this e-mail. https://jl.ly