Skip to content

Commit 7168278

Browse files
author
Kelven Yang
committed
Console access API with API key, there is an issue that it actually depends on existing web session. This is the fix for it
1 parent 505848b commit 7168278

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

server/src/com/cloud/servlet/ConsoleProxyServlet.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,12 @@ private boolean verifyRequest(Map<String, Object[]> requestParameters) {
527527
if (!equalSig) {
528528
s_logger.debug("User signature: " + signature + " is not equaled to computed signature: " + computedSignature);
529529
}
530+
531+
if(equalSig) {
532+
requestParameters.put("userid", new Object[] {String.valueOf(user.getId())});
533+
requestParameters.put("account", new Object[] {account.getAccountName()});
534+
requestParameters.put("accountobj", new Object[] { account });
535+
}
530536
return equalSig;
531537
} catch (Exception ex) {
532538
s_logger.error("unable to verifty request signature", ex);

0 commit comments

Comments
 (0)