sureshanaparti commented on code in PR #12689:
URL: https://github.com/apache/cloudstack/pull/12689#discussion_r2840971411
##########
plugins/user-authenticators/oauth2/src/main/java/org/apache/cloudstack/oauth2/api/command/OauthLoginAPIAuthenticatorCmd.java:
##########
@@ -177,6 +177,10 @@ private String doOauthAuthentication(HttpSession session,
Long domainId, String
protected Long getDomainIdFromParams(Map<String, Object[]> params,
StringBuilder auditTrailSb, String responseType) {
String[] domainIdArr = (String[])params.get(ApiConstants.DOMAIN_ID);
+ if (domainIdArr == null) {
+ // Fallback to support clients using the camelCase parameter name
"domainId"
+ domainIdArr = (String[])params.get(ApiConstants.DOMAIN__ID);
+ }
Review Comment:
done
##########
server/src/main/java/com/cloud/api/auth/DefaultLoginAPIAuthenticatorCmd.java:
##########
@@ -110,7 +110,11 @@ public String authenticate(String command, Map<String,
Object[]> params, HttpSes
// FIXME: ported from ApiServlet, refactor and cleanup
final String[] username = (String[])params.get(ApiConstants.USERNAME);
final String[] password = (String[])params.get(ApiConstants.PASSWORD);
- final String[] domainIdArr =
(String[])params.get(ApiConstants.DOMAIN_ID);
+ String[] domainIdArr = (String[])params.get(ApiConstants.DOMAIN_ID);
+ if (domainIdArr == null) {
+ // Fallback to support clients using the camelCase parameter name
"domainId"
+ domainIdArr = (String[])params.get(ApiConstants.DOMAIN__ID);
+ }
Review Comment:
done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]