An Azure service that provides a general-purpose, serverless container platform.
Hi RIDVAN EYYUPKOCA,
Thanks for reaching out on Microsoft Q&A
The issue of "authentication exchange unsuccessful" from Azure Container Apps to Azure PostgreSQL Flexible Server often relates to authentication and network configuration problems rather than the specific app like Kong.
Key points to address:
1.Managed Identity Authentication:
If you are using Azure AD/Entra ID Managed Identity for authentication, confirm that the Container App has a system-assigned or user-assigned managed identity enabled.
Ensure this identity is properly granted access to the PostgreSQL Flexible Server and that PostgreSQL is configured to accept Azure AD authentication.
2.Password and SCRAM Authentication:
If using password authentication, confirm the password is SCRAM-SHA-256 hashed, and the client library in the Container App supports that authentication method.
Password authentication failure or SSL misconfiguration can also cause the "authentication exchange" error.
3.SSL and Network Configuration:
Confirm SSL settings are correct: SSL is enabled, and the client connecting from Container App supports SNI (Server Name Indication) during TLS handshake which PostgreSQL Flexible Server requires.
Check firewall rules and VNET settings. Ensure the Container App has network access to the database server, and that no firewall or NSG is blocking the connection.
Reference
Connect with Managed Identity - Azure Database for PostgreSQL | Microsoft Learn