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 1oCSRk-0005zB-K2 for pgsql-hackers@arkaria.postgresql.org; Fri, 15 Jul 2022 21:02:00 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oCSRj-0001ol-EF for pgsql-hackers@arkaria.postgresql.org; Fri, 15 Jul 2022 21:01:59 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oCSRj-0001oW-4q for pgsql-hackers@lists.postgresql.org; Fri, 15 Jul 2022 21:01:59 +0000 Received: from mail-pl1-x632.google.com ([2607:f8b0:4864:20::632]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1oCSRg-0007rD-QC for pgsql-hackers@postgresql.org; Fri, 15 Jul 2022 21:01:57 +0000 Received: by mail-pl1-x632.google.com with SMTP id f11so4163589plr.4 for ; Fri, 15 Jul 2022 14:01:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=timescale.com; s=google; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=JLTUbF2fRO0fe01UyNHLTOJPgikxNrGcgLVD9SNNpQQ=; b=Pn5i6S2EI9/dJylTqAe6FqR8J21KKifvceAgcPeo7WOeUPnGP00fa8Cw0geUcRFG69 nHHTt7nW+7FLhwKPpX8r3LXpzWU3ekPlnq/BcuAB9NdNg35lcpT+J2LoLsFrKP5+fiUX 5f2lrmsIJjV68V6fhpLXoaSq88s7lM8akyZiLRzUcIVIYASJ0LVbT19eOt1lA3QqaVbe x3e0LXw/MKzAP1Dnxox0cjyrsWM0KszjOYJWdA5MWpPOkOiWDw/b+vOOr/Kv5VikQarE lZtcwjVg2RytzXET3idStQ0nK280M+GtkJxDx+tIOBxqtH4Wg5cogD0KLpe2rykPXwSk 2DeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=JLTUbF2fRO0fe01UyNHLTOJPgikxNrGcgLVD9SNNpQQ=; b=kH819RH/PI6zWu785opksxSlg2Gqe+dX7+ZqBRjsD4+FAR0Xyn1V9b6CILtQVaTpHy zY3IHbg2nxeY38DBOUAypNkg0Ra4EeR6oEfghNQwGK0XTmzKGyGunDIDg3VC8yisPn1w aN8sElkJdwEoOPmQwS97Z9Mf5szDKe1MdyYqQX9UHNne8FAF9ru7Zc8kk/sqMLZ/WRUD WkMXL0vfag7HECvtLulkKSHPZnuDHyuANPCimhu3nad07aV/53v5DIVcyuzdd0nK5OQH bHPJGdUpy832z3sRl6Thd9BDS03sIJ5DoAYrbxZGsXoipr0YZ/TY926cMu3UN6MGnF/B iuiA== X-Gm-Message-State: AJIora/i8qwehJDLYN/X3g3Xfwpg1aIASKEnyJGEB/eIz6D5s6CmBna9 zRn68ZF4n86DYwheJFw46UicYg== X-Google-Smtp-Source: AGRyM1sIq6c6SnZt+bae937RrGGnzxc/nOnKWlpho77DY6UAngXUMlEXxSdgLwGVyCIHER34aFbnSQ== X-Received: by 2002:a17:903:c5:b0:16b:d8d5:5f14 with SMTP id x5-20020a17090300c500b0016bd8d55f14mr15430002plc.18.1657918915626; Fri, 15 Jul 2022 14:01:55 -0700 (PDT) Received: from [192.168.1.21] ([50.39.205.221]) by smtp.gmail.com with ESMTPSA id e2-20020a17090a118200b001ef3f85d1aasm6198588pja.9.2022.07.15.14.01.54 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 15 Jul 2022 14:01:54 -0700 (PDT) Message-ID: <2878aee8-a4a6-8078-9740-efe90fcf8328@timescale.com> Date: Fri, 15 Jul 2022 14:01:53 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH] Log details for client certificate failures Content-Language: en-US To: Andres Freund Cc: Peter Eisentraut , "pgsql-hackers@postgresql.org" References: <61aa4b6c-9de2-d61b-821a-a34ab1e515e2@enterprisedb.com> <2ef20161-e99d-a6ea-a36d-577843a2daae@enterprisedb.com> <49b48719-d6cf-9e03-fab3-e4505cf9d585@enterprisedb.com> <059e67f5-3769-24c8-f460-4e5d87af529a@enterprisedb.com> <0167a8c5-1754-9121-b994-0719a6493a21@timescale.com> <20220715191156.jecddreykoakdljm@awork3.anarazel.de> <20220715203500.vanqxt23bmufjais@awork3.anarazel.de> From: Jacob Champion In-Reply-To: <20220715203500.vanqxt23bmufjais@awork3.anarazel.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 7/15/22 13:35, Andres Freund wrote: >> (And do we want to fix it now, regardless?) > > Yes. Cool. I can get on board with that. >> What guarantees are we supposed to be making for log encoding? > > I don't know, but I don't think not caring at all is a good > option. Particularly for unauthenticated data I'd say that escaping everything > but printable ascii chars is a sensible approach. It'll also be painful for anyone whose infrastructure isn't in a Latin character set... Maybe that's worth the tradeoff for a v1. Is there an acceptable approach that could centralize it, so we fix it once and are done? E.g. a log_encoding GUC and either conversion or escaping in send_message_to_server_log()? --Jacob