we are facing an issue with enabling cert based authentication between client and pgbouncer 1.17.0.
Pgbouncer 1.17.0 and postgresql 14 are on the same host in different containers. There is TLS enabled between client and pgbouncer. The issue is that we want client to connect to pgbouncer with client key and certificate, the certificate will have a Common Name (lets say "abc") which wont be same as the user "joe" which is trying to login to pgbouncer, so here we want a mapping of the user "joe" to "abc". If we try to login as joe , Immediately we get error because pgbouncer will check the user ("joe") and Common Name ("abc") in cert and they doesn't match. What is the right way of solving this issue? otherwise how can different users login to pgBouncer?
On postgreSQL, this mapping can be done using pg_ident.conf but that support is not available in pgBouncer. What is the most secured way of achieving this authentication?