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 1qHSeL-0002H7-4J for pgsql-hackers@arkaria.postgresql.org; Thu, 06 Jul 2023 17:20:13 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1qHSeK-0005q8-0d for pgsql-hackers@arkaria.postgresql.org; Thu, 06 Jul 2023 17:20:12 +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 1qHSeJ-0005pz-Lz for pgsql-hackers@lists.postgresql.org; Thu, 06 Jul 2023 17:20:11 +0000 Received: from mail-pj1-x102b.google.com ([2607:f8b0:4864:20::102b]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1qHSeG-002a0x-BT for pgsql-hackers@postgresql.org; Thu, 06 Jul 2023 17:20:10 +0000 Received: by mail-pj1-x102b.google.com with SMTP id 98e67ed59e1d1-262dc1ced40so742262a91.3 for ; Thu, 06 Jul 2023 10:20:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1688664006; x=1691256006; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=iabWDZu39iqEPBEUqxFUfOubtbunJQSrdeHgTT2ztIY=; b=gW3JcaWIAHte3DB1mx90eDN/7hJaKYcsRyb6xtZhgODmVT6OSSnC2ch2T9EP0UWAD7 LLxxvA5SD2dWwQr5gitZzKhx7d8FxoX0MflPU5MMtyuMiWShgk2cYtgKIPZTSTqiSf5t uOudqzOwD14LFvGiMsIZX8KTu+OMgC1pXSZfPexWH3MMdfJZfDKBLdPmw+rayT0v8jJc CC36p6zQHrjo7Cft40iMYDM2Q6m1nPBUgWEdV72nncGtDn/GOOyuYqsb9X3XsPGZjPK2 xJY86yGeGMGAe1gq/J2bjwFajFDJA8jw2F+gnqbxsG8uoCitd6Hcbb2IgJ1QukOp+OdH gBwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688664006; x=1691256006; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=iabWDZu39iqEPBEUqxFUfOubtbunJQSrdeHgTT2ztIY=; b=fUEa45nYVuN8sEwFONrhdNMk1BUNuAtS3bdxAnvgzkfP0IEQYq55Ms3YUp6nPhii+T EsVoz2exWcoR4i8Ikryl2EcnsLOIVkE0KWGiwpThf2TuNbqW2Ao+R1yIaD6AykqM7p2E Lun/rTxaSNQu0FcOQJwrI1JAXlF9IySTdBNeafoieKf6fV6NqlTfHHkNAF4ExRzq5bpi RyqpTg10HW/f+U/VDDiGDiwmB7beMqGjROt7SNB9eHcUaVYsjwwLzPCWAjRly9INcht0 4FYA5jOWU3hxga8jEd9B2O0i4ccrBR3NVppIkp8kN+KNfEV+V/VTbVT3TXlm998HydBX aQ1Q== X-Gm-Message-State: ABy/qLbml+JeOHHQpcPlpEAEL4xc0VNLUSZUs9OJ78cjQ2LekLlyPkYP C/rW6+3SNjLQtHsdigST3nM= X-Google-Smtp-Source: APBJJlEprHVuxW727kSkH0Cfv4xU7OueKgoZoE9Gw0G3dYXuhBiRDiWjgoRGPGElGytgv5soh+TuNQ== X-Received: by 2002:a17:90a:6b06:b0:25c:8b5e:814 with SMTP id v6-20020a17090a6b0600b0025c8b5e0814mr2319346pjj.44.1688664005951; Thu, 06 Jul 2023 10:20:05 -0700 (PDT) Received: from nathanxps13 ([50.47.162.83]) by smtp.gmail.com with ESMTPSA id 8-20020a17090a098800b002638e5d2986sm61629pjo.17.2023.07.06.10.20.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Jul 2023 10:20:05 -0700 (PDT) Date: Thu, 6 Jul 2023 10:20:04 -0700 From: Nathan Bossart To: Jeff Davis Cc: Tom Lane , Robert Haas , Noah Misch , "pgsql-hackers@postgresql.org" Subject: Re: pgsql: Fix search_path to a safe value during maintenance operations. Message-ID: <20230706172004.GA3635686@nathanxps13> References: <20230613182920.GA259321@gust.leadboat.com> <1799839.1686687804@sss.pgh.pa.us> <4df537f5a0d8c0ceac3eec3809d1144880b8e76d.camel@j-davis.com> <578fb4be80247570e6a05924908765a0b345971e.camel@j-davis.com> <43bbc9f7318057f51552d5986830908cb018dadf.camel@j-davis.com> <1659699.1688086436@sss.pgh.pa.us> <20230630050921.GA2640352@nathanxps13> <931c23465c331fc3d53073cdefa53bad464b0469.camel@j-davis.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <931c23465c331fc3d53073cdefa53bad464b0469.camel@j-davis.com> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Jul 06, 2023 at 12:55:14AM -0700, Jeff Davis wrote: > It was difficult to review standalone, so I tried a quick version > myself and ended up with very similar results. Thanks for taking a look. > The only substantial > difference was that I put back: > > > + if (!vacuum_is_relation_owner(relid, classForm, > options)) > + continue; > > > in get_all_vacuum_rels() whereas your patch left it out -- double-check > that we're doing the right thing there. The privilege check was moved in d46a979, which I think still makes sense, so I left it there. That might be why it looks like I removed it. > Also remember to bump the catversion. Other than that, it looks good to > me. Will do. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com