pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <bruce@momjian.us>
To: Peter Eisentraut <peter@eisentraut.org>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Make query cancellation keys longer
Date: Tue, 5 Mar 2024 20:12:18 -0500
Message-ID: <ZefC8pFljxDXLRWk@momjian.us> (raw)
In-Reply-To: <ba9f1055-40b3-42c7-a7c9-0b62d1959ee6@eisentraut.org>
References: <508d0505-8b7a-4864-a681-e7e5edfe32aa@iki.fi>
	<ba9f1055-40b3-42c7-a7c9-0b62d1959ee6@eisentraut.org>

On Fri, Mar  1, 2024 at 03:19:23PM +0100, Peter Eisentraut wrote:
> On 29.02.24 22:25, Heikki Linnakangas wrote:
> > Currently, cancel request key is a 32-bit token, which isn't very much
> > entropy. If you want to cancel another session's query, you can
> > brute-force it. In most environments, an unauthorized cancellation of a
> > query isn't very serious, but it nevertheless would be nice to have more
> > protection from it. The attached patch makes it longer. It is an
> > optional protocol feature, so it's fully backwards-compatible with
> > clients that don't support longer keys.
> 
> My intuition would be to make this a protocol version bump, not an optional
> feature.  I think this is something that everyone should eventually be
> using, not a niche feature that you explicitly want to opt-in for.

Agreed.

-- 
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EDB                                      https://enterprisedb.com

  Only you can decide what is important to you.





view thread (40+ messages)  latest in thread

Message-ID: <ZefC8pFljxDXLRWk@momjian.us>
Permalink:  ../ZefC8pFljxDXLRWk@momjian.us/
Also on:    postgresql.org/message-id/ZefC8pFljxDXLRWk@momjian.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: bruce@momjian.us, peter@eisentraut.org, hlinnaka@iki.fi
  Subject: Re: Make query cancellation keys longer
  In-Reply-To: <ZefC8pFljxDXLRWk@momjian.us>
  References: <508d0505-8b7a-4864-a681-e7e5edfe32aa@iki.fi> <ba9f1055-40b3-42c7-a7c9-0b62d1959ee6@eisentraut.org> <ZefC8pFljxDXLRWk@momjian.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox