Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rtNBv-00EJ1t-Jh for pgsql-hackers@arkaria.postgresql.org; Sun, 07 Apr 2024 07:43:52 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rtNBu-004K45-AG for pgsql-hackers@arkaria.postgresql.org; Sun, 07 Apr 2024 07:43:50 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rtNBt-004K3w-UQ for pgsql-hackers@lists.postgresql.org; Sun, 07 Apr 2024 07:43:50 +0000 Received: from mail-lf1-x136.google.com ([2a00:1450:4864:20::136]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rtNBn-001Zi5-5s for pgsql-hackers@lists.postgresql.org; Sun, 07 Apr 2024 07:43:48 +0000 Received: by mail-lf1-x136.google.com with SMTP id 2adb3069b0e04-516cbf3fd3dso3983127e87.2 for ; Sun, 07 Apr 2024 00:43:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712475821; x=1713080621; darn=lists.postgresql.org; h=user-agent:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:subject:cc:to:from:date :sender:message-id:from:to:cc:subject:date:message-id:reply-to; bh=zU6KC2jWIRp1T16LanXbLkKxeauK04jXijYT+QsM6VY=; b=irdstNtICV5IumT/9IhGO+wO/KOh5dO1CNah0PMEN7Sd+6VO/WLA3nUVt4qFpEI3gK km2T50hQK3i7nAT+kchhGcuKStb4JcaoZP0GQOL36hwLVA2Al8BwVhVJeof6GxOp+zc/ eT8/C7A/wN9PUWWGMICNcndWHOfwOXI3JYAMdMRrvm0ZQemafRcx0aVLxjQ0Dzw4mWbJ /p0mdI4AxhtbJOGW6RQgPkABdwATSsFomaH3Qd18458Vvy1aKFXeBF+2b61v/vBXfGqq sKY4XX+U9kBEWs51G/L48f0qQY/Ir2+FvvBQp0o1YmWKtLmr6vchNahXn/qaqNSUSNwn NdJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712475821; x=1713080621; h=user-agent:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:subject:cc:to:from:date :sender:message-id:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=zU6KC2jWIRp1T16LanXbLkKxeauK04jXijYT+QsM6VY=; b=fQflNUYGoBeVVyiMwOb1OW8J2Gm8nxDqdLVIG+wtxhtrKoVWQh7IJ2L9d+PKM9Mp2C YwVOXmyG2FptE3vXQG4nkwWVa+VgrpT8phiCb7XgF4c7yz8UqTwZVh6tMFPWZBURg6xe ToVKG3RVZJFNPdxBpX1cw7tr1V0+FyqmImhCEODGwlA7sft3BuknNjr5McdjLSvNXM8E Mb/sTMsoGBY/F+ijkVtz5zERWckfwp8JDzLQ7jAGFLQxkm/WxkOMszi62AEr/sveWNZx OzXmiU38H6jZOqynUbhf87TTWm54fWIsHZj78YJjk+MGsZp+qpyZBVfjBzvJo2Nvu+7b rk7Q== X-Forwarded-Encrypted: i=1; AJvYcCWWPekm7xxZR0ep43qQoJz0vuArqAf692NXqTXa5Gp/d086MQf+/LOp8cfCqWvvF56xX9ZV+wUkeHMmTSX2hZ4POfwm0eissLxcSB8Wibu+ExtY X-Gm-Message-State: AOJu0YxEUeFkzKlRubXEck/gT9N4TDEDAu/T/aCZGk3LZJgMhaypSTj+ dmmMpHguY1AakRskA8QORWsJdqvTNY2+KvltYLPmdlB3raHxuAUp X-Google-Smtp-Source: AGHT+IHMjiu7j6f/onGNKrjuE7MwU9ln0kftelySiGULjCxDXYG8vj38ztBTK2MEKsd9uzXwajt6bQ== X-Received: by 2002:a19:9119:0:b0:514:a821:a020 with SMTP id t25-20020a199119000000b00514a821a020mr4143122lfd.26.1712475820428; Sun, 07 Apr 2024 00:43:40 -0700 (PDT) Received: from lightning.caipicrew.dd-dns.de ([2001:a61:a0e:9401:f815:e42b:c961:9a62]) by smtp.gmail.com with ESMTPSA id b93-20020a509f66000000b0056e0376286bsm2753142edf.24.2024.04.07.00.43.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 07 Apr 2024 00:43:39 -0700 (PDT) Message-ID: <66124eab.500a0220.47342.091b@mx.google.com> X-Google-Original-Message-ID: <20240407074339.GD17346@caipicrew.dd-dns.de;lightning.caipicrew.dd-dns.de> Sender: Michael Banck Received: from mbanck by lightning.caipicrew.dd-dns.de with local (Exim 4.92) (envelope-from ) id 1rtNBj-00059c-G7; Sun, 07 Apr 2024 09:43:39 +0200 Date: Sun, 7 Apr 2024 09:43:39 +0200 From: Michael Banck To: Daniel Gustafsson Cc: Jacob Champion , Tomas Vondra , Nathan Bossart , Abhijit Menon-Sen , pgsql-hackers@lists.postgresql.org, =?utf-8?B?5oiQ5LmL54SV?= Subject: Re: [PATCH] Exponential backoff for auth_delay References: <65e62440.170a0220.f6a7c.6f7f@mx.google.com> <20240305215044.GA3538518@nathanxps13> <20240306161045.GA3542434@nathanxps13> <65e8f208.170a0220.ba91f.1ea3@mx.google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On Wed, Mar 20, 2024 at 11:22:12PM +0100, Daniel Gustafsson wrote: > > On 20 Mar 2024, at 22:21, Jacob Champion wrote: > > > > On Wed, Mar 20, 2024 at 2:15 PM Jacob Champion > > wrote: > >> I think solutions for case 1 and case 2 are necessarily at odds under > >> the current design, if auth_delay relies on slot exhaustion to do its > >> work effectively. Weakening that on purpose doesn't make much sense to > >> me; if a DBA is uncomfortable with the DoS implications then I'd argue > >> they need a different solution. (Which we could theoretically > >> implement, but it's not my intention to sign you up for that. :D ) > > > > The thread got quiet, and I'm nervous that I squashed it unintentionally. :/ > > > > Is there consensus on whether the backoff is useful, even without the > > host tracking? (Or, alternatively, is the host tracking helpful in a > > way I'm not seeing?) Failing those, is there a way forward that could > > make it useful in the future? > > I actually wrote more or less the same patch with rudimentary attacker > fingerprinting, and after some off-list discussion decided to abandon it for > the reasons discussed in this thread. It's unlikely to protect against the > attackers we wan't to protect the cluster against since they won't wait for the > delay anyways. I have marked the patch "Returned with Feedback" now. Maybe I will get back to this for v18, but it was clearly not ready for v17. Michael