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 1p8Ky6-0002v5-Az for pgsql-admin@arkaria.postgresql.org; Thu, 22 Dec 2022 12:46:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1p8Ky4-0007go-0p for pgsql-admin@arkaria.postgresql.org; Thu, 22 Dec 2022 12:46:36 +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 1p8Ky3-0007gf-JG for pgsql-admin@lists.postgresql.org; Thu, 22 Dec 2022 12:46:35 +0000 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1p8Ky1-0004I2-8p for pgsql-admin@lists.postgresql.org; Thu, 22 Dec 2022 12:46:34 +0000 Received: by mail-wm1-x336.google.com with SMTP id bg10so1332367wmb.1 for ; Thu, 22 Dec 2022 04:46:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:user-agent:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=+PDoHx3YhcUJ9hmWzCN+TgaYH7FWTDYmuqWN+UgCcP0=; b=DKNzVOM3UFVn+y8a2ID0IIYxXHmWRO85u/GLhtiPXWGI92pUtBXhzQIhk+BTSvOkIE H8Mkz8O6W1PwBil63TXZU4P80tLPPcCizNIRvL8zGTeA6j1Y0JudXfF+3cWz85i0+c5u OLY05HGCLZ3oIdmdxxYrB/yCfDgWUXE7Z/VS2B4XBnW0SSzZrRuBr5NQ18IviXvkywOF 5998QxR7KyylzoBuK+dfGmGETB7TyBZ43vZrVl6oH+5ssbkJyI4O4VnJLY5cbQJHEpaa Tjt4jx7LFscK9mu/JN0KgmJTU74Xm4juAHzxrxzo5P1SpL4AwVfQjCh87IvKHTWpviFN jsiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:user-agent:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=+PDoHx3YhcUJ9hmWzCN+TgaYH7FWTDYmuqWN+UgCcP0=; b=lUPvFPmVe5IS45Iy2XC8lxjpOrqniK6esGfGHoPKPe3YzRgSTesmisk4gV6iEi6soU ZKaMgQ8XmfTThOiUcIm8dMiCp9jSayhLAubI8JEwhM6LffwXpvaeVqoODdML5GFtcJX0 ISfPHXEvPqLA1USz8jDzx1C6ZWW29+eFUtcY7W1AiGpHQ0ENO9LTmgyskZmdssWVWKSE SW0nKcKRTgbLklDynOwRNq7EHomZgdZIy/EQws3WKsN5PuTT2SxVZmXG3deY11RGS/EB iP0Ee2Uc/aTx9D0nRI61YE7Q38pEW1PHjRxaT0VAl6DSeFL0bMh6WTmE7NfDZhUFBTZC +uww== X-Gm-Message-State: AFqh2kqumCgEGGXZ86ZwyzSnEHPpoF+aXkd2+r20kFGJza3AGsqCqbsF qf8UDROei5BZLHJl6MLc2cIVNA== X-Google-Smtp-Source: AMrXdXs1YVfVO1T4h/B6K6Tot5mFaLvbw75RUS7vCZcsv2YLJC006s0mhUNV2C8OST8lSwaw6kbupQ== X-Received: by 2002:a05:600c:43ca:b0:3d0:73f5:b2c0 with SMTP id f10-20020a05600c43ca00b003d073f5b2c0mr4411974wmn.20.1671713191626; Thu, 22 Dec 2022 04:46:31 -0800 (PST) Received: from localhost.localdomain ([2001:871:5e:539:1b2c:c52a:475d:310c]) by smtp.gmail.com with ESMTPSA id k17-20020a5d4291000000b002415dd45320sm413385wrq.112.2022.12.22.04.46.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Dec 2022 04:46:31 -0800 (PST) Message-ID: <40ba97d7584f20dbf04ebedfc02cb1b8a146f45e.camel@cybertec.at> Subject: Re: Facing issue with cert authentication From: Laurenz Albe To: Dhirendra Singh , "David G. Johnston" Cc: pgsql-admin@lists.postgresql.org Date: Thu, 22 Dec 2022 13:46:30 +0100 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.4 (3.42.4-2.fc35) MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, 2022-12-22 at 14:39 +0530, Dhirendra Singh wrote: > On Thu, Dec 22, 2022 at 10:21 AM David G. Johnston wrote: > > On Wed, Dec 21, 2022 at 9:25 PM Dhirendra Singh wrote: > > > > > > I am using cert authentication to authenticate. > > > I have created a user with name S114546 (with uppercase 'S'). user > > > created is s114546 (with lowercase 's'). > > > > > > I can create the user with uppercase 'S' by double quoting the username. > > > but the script which creates the user will do the same for all users > > > which i do not want. > > > > It seems considerably easier to modify your database role creation > > compared to the PKI certification creation.  I suggest you figure out > > what you can live with on that front. > > It seems regex provides a way to convert the extracted string to lowercase > by using "\L\1". but this is also not working...seems not supported by postgres. > Is there a way to convert the matched string to lowercase ? That syntax is not supported by PostgreSQL, and I cannot think of a better way that to create the role with an upper case "S". Yours, Laurenz Albe