From 9a8b74d74472c89f0d86970cfa0dd176e880732a Mon Sep 17 00:00:00 2001 From: Grant Limberg Date: Wed, 31 May 2023 09:34:31 -0700 Subject: [PATCH] Fix oidc client lookup query join condition referenced the wrong table. Worked fine unless there were multiple identical client IDs --- controller/PostgreSQL.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controller/PostgreSQL.cpp b/controller/PostgreSQL.cpp index 8ac9bf747..1ec46e891 100644 --- a/controller/PostgreSQL.cpp +++ b/controller/PostgreSQL.cpp @@ -460,7 +460,7 @@ AuthInfo PostgreSQL::getSSOAuthInfo(const nlohmann::json &member, const std::str "LEFT OUTER JOIN ztc_network_oidc_config noc " " ON noc.network_id = n.id " "LEFT OUTER JOIN ztc_oidc_config oc " - " ON noc.client_id = oc.client_id AND noc.org_id = o.org_id " + " ON noc.client_id = oc.client_id AND oc.org_id = o.org_id " "WHERE n.id = $1 AND n.sso_enabled = true", networkId); std::string client_id = "";