Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hwCsO-0006Dt-RF for pgsql-hackers@arkaria.postgresql.org; Fri, 09 Aug 2019 21:56:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hwCsL-0000Sj-Ob for pgsql-hackers@arkaria.postgresql.org; Fri, 09 Aug 2019 21:56:41 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hwCsL-0000Sc-CB for pgsql-hackers@lists.postgresql.org; Fri, 09 Aug 2019 21:56:41 +0000 Received: from mail-pf1-x443.google.com ([2607:f8b0:4864:20::443]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hwCsE-0002ac-D0 for pgsql-hackers@postgresql.org; Fri, 09 Aug 2019 21:56:40 +0000 Received: by mail-pf1-x443.google.com with SMTP id r7so46726966pfl.3 for ; Fri, 09 Aug 2019 14:56:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=j-davis-com.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:cc:date:in-reply-to:references :mime-version:content-transfer-encoding; bh=zFxwFN89gWRGUkn3FdZvaCw+m2mKPJ+ce+nQWjZ7Nvw=; b=K2LlQV7bdIguJEDHZgognGV9FojeL/zNhYMMGIE/av0WDA/G0aSQnWltVyPtYwuydW OXMlbI3HqI8RkwvCe+CeR9mDXMbuFb70fQuKDtQpDXe/rumfB4jGshFtnejPRNlAEmHY qmItbKCZn1Fkv8rEYwTx2b33kvf/W+r50nscl3p0S9PyQGK+pjHUies/bmN0jx0zkMSZ Uolqvf0ziPvJO1sz+v+ubk6BTfT1sCOYj+SBrOhM3j26W0wsBviisJT2+LPKDifwumvg KGJPkct4OLXkd//fGYMwg1bIK07LWw/Vf0V9HhBFpkiny6CaKkYQNMFOsulvTQYQjAPX 0xWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=zFxwFN89gWRGUkn3FdZvaCw+m2mKPJ+ce+nQWjZ7Nvw=; b=m38wVg3PF8FPlB9EcnXVdHz5vIxPZpfV2Dzm9q9JJCKXN0MPN2KOX9yZGTqvo2qOoy 3lCMYe1x9/yCon5o+s+pBsm7deuZHbktDec+L2GZujEpnS2s+OxTEMN2wqepr4eQlFAW 7YGSnMfLyP2BQVgui259G5y9v32a/yPa47qbOZ4yTDlEe1HkwaNMfKccp5B1p36mXiDa +8t63TQbLBm5do9cjoLooDmXeIdjmh3Hpnvblh3kf34enjxKzCcXR4Y2Ckm02Ejcg7E4 njxNRpgtmIkGy10f9a5c0aA1DN3Wa/+7yIoiwoiZAGTU5tWZx/osn+Z4pGMQLASi6mih Yk+g== X-Gm-Message-State: APjAAAV+y+PQaF96rT92GgWDy8A+SaPRuA28UHnMQMq77U/3i8Z4kEp6 TLckV1rAAGG8Y9RgS+SA/rdBVw== X-Google-Smtp-Source: APXvYqx88/7M5/NRFJ9LW6+hr/d7rljfVsZ9K8IiCRcpWph2ZxNSgg+v9KpUY4p6vcfyL56GLyaopA== X-Received: by 2002:a17:90a:bc42:: with SMTP id t2mr11425340pjv.121.1565387791823; Fri, 09 Aug 2019 14:56:31 -0700 (PDT) Received: from jdavis ([2600:1010:b04e:32eb:f8ed:1038:616a:715e]) by smtp.gmail.com with ESMTPSA id 185sm108107919pfa.170.2019.08.09.14.56.30 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 09 Aug 2019 14:56:31 -0700 (PDT) Message-ID: Subject: Re: Add "password_protocol" connection parameter to libpq From: Jeff Davis To: "Jonathan S. Katz" , Stephen Frost , Michael Paquier Cc: pgsql-hackers@postgresql.org Date: Fri, 09 Aug 2019 14:56:28 -0700 In-Reply-To: <071e45a6-97f7-1614-371c-98ecb03aed65@postgresql.org> References: <227015d8417f2b4fef03f8966dbfa5cbcc4f44da.camel@j-davis.com> <20190809030021.GG3194@paquier.xyz> <3bbf5968ea705700a2605d6db74d8510bea7940b.camel@j-davis.com> <20190809100922.GI3194@paquier.xyz> <20190809132850.GL16436@tamriel.snowman.net> <609482826475e0063c7d71b2449ae31c0d61b232.camel@j-davis.com> <071e45a6-97f7-1614-371c-98ecb03aed65@postgresql.org> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Fri, 2019-08-09 at 16:27 -0400, Jonathan S. Katz wrote: > Seems to be a lot to configure. I'm more of a fan of the previous > method; it'd work nicely with how we've presently defined things and > should be easy to put into a DSN/URI/env variable. Proposals on the table: 1. Hierarchical semantics, where you specify the least-secure acceptable method: password_protocol = {any,md5,scram-sha-256,scram-sha-256-plus} 2. Comma-list approach, where you specify exactly which protocols are acceptable, or "any" to mean that we don't care. 3. three-setting approach: channel_binding = {disable|prefer|require} password_plaintext = {disable|enable} password_md5 = {disable|enable} It looks like Jonathan prefers #1. #1 seems direct and clearly applies today, and corresponds to auth methods on the server side. I'm not a fan of #2, it seems likely to result in a bunch of clients with overly-specific lists of things with long names that can never really go away. #3 is a little more abstract, but also seems more future-proof, and may tie in to what Stephen is talking about with respect to controlling auth methods from the client, or moving more protocols within SASL. Regards, Jeff Davis