Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lAICT-0008Ps-Id for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Feb 2021 20:04:29 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lAICR-0003KJ-Pp for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Feb 2021 20:04:27 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lAICR-0003KB-Is for pgsql-hackers@lists.postgresql.org; Thu, 11 Feb 2021 20:04:27 +0000 Received: from relay2-d.mail.gandi.net ([217.70.183.194]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lAICO-0005IC-R6 for pgsql-hackers@lists.postgresql.org; Thu, 11 Feb 2021 20:04:26 +0000 X-Originating-IP: 99.10.92.30 Received: from [192.168.10.146] (99-10-92-30.lightspeed.rlghnc.sbcglobal.net [99.10.92.30]) (Authenticated sender: adsend@dunslane.net) by relay2-d.mail.gandi.net (Postfix) with ESMTPSA id 3AA0C40002; Thu, 11 Feb 2021 20:04:20 +0000 (UTC) Subject: Re: Tightening up allowed custom GUC names To: Tom Lane , Noah Misch Cc: pgsql-hackers@lists.postgresql.org References: <951335.1612910077@sss.pgh.pa.us> <20210209230155.GA551305@rfd.leadboat.com> <1477413.1613068373@sss.pgh.pa.us> From: Andrew Dunstan Message-ID: Date: Thu, 11 Feb 2021 15:04:17 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: <1477413.1613068373@sss.pgh.pa.us> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2/11/21 1:32 PM, Tom Lane wrote: > Noah Misch writes: >> On Tue, Feb 09, 2021 at 05:34:37PM -0500, Tom Lane wrote: >>> * A case could be made for tightening things up a lot more, and not >>> allowing anything that doesn't look like an identifier. I'm not >>> pushing for that, as it seems more likely to break existing >>> applications than the narrow restriction proposed here. But I could >>> live with it if people prefer that way. >> I'd prefer that. Characters like backslash, space, and double quote have >> significant potential to reveal bugs, while having negligible application >> beyond revealing bugs. > Any other opinions here? I'm hesitant to make such a change on the > basis of just one vote. > > That might be a bit restrictive. I could at least see allowing '-' as reasonable, and maybe ':'. Not sure about other punctuation characters. OTOH I'd be surprised if the identifier restriction would burden a large number of people. cheers andrew -- Andrew Dunstan EDB: https://www.enterprisedb.com