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.96) (envelope-from ) id 1wQbdl-001gNz-1P for pgsql-hackers@arkaria.postgresql.org; Sat, 23 May 2026 01:59:01 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wQbdi-00F8r5-02 for pgsql-hackers@arkaria.postgresql.org; Sat, 23 May 2026 01:58:58 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wQbdh-00F8qx-2A for pgsql-hackers@lists.postgresql.org; Sat, 23 May 2026 01:58:58 +0000 Received: from mail-ot1-x32d.google.com ([2607:f8b0:4864:20::32d]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wQbdg-00000000yh8-2NkN for pgsql-hackers@lists.postgresql.org; Sat, 23 May 2026 01:58:58 +0000 Received: by mail-ot1-x32d.google.com with SMTP id 46e09a7af769-7e61d3fb1c6so21191a34.3 for ; Fri, 22 May 2026 18:58:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1779501533; cv=none; d=google.com; s=arc-20240605; b=QV4+SwWPvT0qgzdK1ILDKrdWGvEYin1Tk9mXJecYhDaCAmFu5bXZTtZo+SUhL6xpBj U86bwSS12pSRXTzU++QGfJQNsbtX2JoRjtKDXsAjBWzpmQGpKiNCo/01xN5xHEKLz93h SgfqX7WIOV1Pdpl48X+GxE7YJNsBSsS10Xsut1UK2BcIYxxvcmCCwoAachxxgzXtEigp Q4jMSftu9Xz6PQUh/py/lSFTGdl63t/IOY+NvfflBddBMY0JzJr3TNHbzuHRLuwyMCqA pBzHCfANlMdx3pJScL1Xhz13lFfYrRIPNq0N0eyOPjFYFltzkGM42+uCLpksYB5oXUKu xkJg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=SJYgGYmQyW/sNemqB9INcLNqUUWHqP9Iv/aTgw1RVAM=; fh=msZ7vH1mbfja6+/WmutU4aZKNzdKO1jR7OxAI2TbZtI=; b=EUr2R1R7podAF00zk0mKbiK0yQVH5yfiWsnOXVaw2pKuyip+4r27AO/+AfrvQ2qTg5 u+Xi4NRjOrE5bqfpI7S6Y/gR1MsIHznbbsc10hFsYzTSd/X1bY+2WZc7m1Bjr5fj+CRZ OirkqWBKcyqfJ5vWDaLRgpnz2Cizcw5rnYQtRp6UyOMoTQf1ENPONCBNolrAMXVJU8BI gqJYUsLP9FU1OxWs2RBJxta6VIIcFn4BY9GnyeJFey49u/Ju86OlojBwGsLLzuev4Z9k OzYO32bndkRkYFOcLTUaXKO4efZJKZ/gklFb+JmZYcRF74FbYOHRa3xajfXxThKYdFKN VJLA==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1779501533; x=1780106333; darn=lists.postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=SJYgGYmQyW/sNemqB9INcLNqUUWHqP9Iv/aTgw1RVAM=; b=SflExyH0p6rSOp990xBZrybwb4ZdDNnr9XaXJCnHYXX+8TfDQuu1BcV9FPTF3hqHO1 Xc66E7N5VNhmkTJH2d3nqJfP6LXnPX3/Qla3KEb63cHNn2+aNBoAdIPviqNwR2LiIWwg 1VfmkCY+u+DXHqsOglZi3HRC2YByGfgIflQZ4MQEoU/DjTsfWbPUWqPEvVa8jv+/TlV3 fRDCEKV9JL1Ane1zpQM8YaYIVXUdEGGuO/R0eiXT7Neiq2B/UZ6hBUTDWbFwUPXARmKX RFmLixAJjAOBVbweyv/D6z/UAF9EHgwUX48ll7UEJk880daH8j0zwfHPrShpRvl4r5E7 UxwQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1779501533; x=1780106333; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=SJYgGYmQyW/sNemqB9INcLNqUUWHqP9Iv/aTgw1RVAM=; b=PUfMI5xoHWY5Z74Q0I4YZ95tpEuCnmvwWRfs+we9F8ozD+O32tRy9sFXVvtdmkTGuB KlqLj/XtnBMZQQmfzycLezwrcVJxPUz/yMvF2ZZb/I5NC1DEmNqmSUv/UUXaDNO9DdRM Xc4hg6Q8yOM904d8VF9CZZE+1JZnefSjEY8MbUZDiSLb1f04DpwwGZ8PBtRXJyTK0ttF a+NQQH7AU3ploLoBEkPEhCUtxjXsC2v23EcssfhUJPLOkEqaoiZAMjlvSPgusnx8M+IY JueaUCb/4C3mnCR45eHyvwvQkZP9G1ig7mZA6idECyIlsPAOSZ+MM2MX0HSaU6O4lnVA 68pA== X-Gm-Message-State: AOJu0YwQCIk00X5iz9Nbt6Gt/MvaxpJT9fW8XHleKV3qTq6QzV/5b+Zv Ada0T+UuW/qsGHBzM/wW2PoQ2joWhfAdKHcNpRHrJQ6IIV92I/wfzSNKxNaiPCYLbghooGsn7Rl kdurrQ/jtbm5AtLjm5r09zxaIolk4Bzd+Fp5nNw8= X-Gm-Gg: Acq92OEu3o1+IwDKGdDam4xcmTwXAAaj2DbNiL/Vj3tbMNq7IddN+S0BR1Apyn4m1LX SHSpPr7e1X3dcmS+6TTz3pMvTM2SMccNZDOpPRGsFe7KW1ZndbqvKSU2gpZvchG2kxQwsRHhVGR U/+sdVdUhDJNpyVVuZ16gVDQq7irDr5RlIJEy4sQfuyjQa7iMsBBQN2elHRkPZV4TwEWcFyQ9LJ Ay6ZNtS/LmMyvAyvFUl8q/8SYJMEUazBmbR06p18BgtwvarP4jRNbrzpNFG5PdA+R5e+jCLjwGn +NKT+zWuWdhdkStwUiYhrHDbhrBLF6zeLE1hTfgQJQ== X-Received: by 2002:a05:6820:208a:b0:69b:5696:e64d with SMTP id 006d021491bc7-69d7eb32e29mr3428026eaf.13.1779501533363; Fri, 22 May 2026 18:58:53 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Fujii Masao Date: Sat, 23 May 2026 10:58:40 +0900 X-Gm-Features: AVHnY4LQcpdgdKyzl22oxmR0wC4HOdnrgw1dGL-ircg8bMUSIIzCjq9fgndn_xQ Message-ID: Subject: Re: postgres_fdw: use_scram_passthrough on user mapping is ignored when also set on server To: Matheus Alcantara Cc: PostgreSQL Hackers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, May 18, 2026 at 11:42=E2=80=AFPM Matheus Alcantara wrote: > I think that the test is worth to have to avoid such issues in the > future again, but I agree that adding as a TAP test is overkill. I've > moved to sql/dblink.sql on the new attached version. > > Do you think that we need to add such test for postgres_fdw too? No, I don't think so. In dblink, use_scram_passthrough is handled by a dblink-specific validation path, and patch 0003 fixes that specific code path. So it might be worth adding such test for dblink. In postgres_fdw, however, this option is handled by the generic option/cont= ext validation machinery, not by any special-case code. We already have tests f= or context-sensitive option validation there. So adding such test for postgres= _fdw would be mostly redundant, I think. Thought? > Yeah, we don't have any documentation about this on 18, but we do have > for sslkey and sslcert where in postgres-fdw.sgml we have the following: > sslkey and sslcert - these may appear in either or both a connection > and a user mapping. If both are present, the user mapping setting > overrides the connection setting. > > So I think that is desirable to have the same behavior for > use_scram_passthrough. Agreed. I'm therefore thinking of backpatching patches 0001 and 0002 to v18= . Even in v18, this change is very narrow. It only affects cases where use_scram_passthrough is specified at both the server and user-mapping leve= ls with conflicting values. In such cases, the natural interpretation is that the user-mapping setting is intended to override the server-level setting; otherwise, there would be little reason to specify conflicting values. Given the limited impact, leaving v18 as the only branch with different semantics for a feature introduced in v18 seems more undesirable and potentially confusing. So I think backpatching to v18 makes sense. Regards, --=20 Fujii Masao