CLOUDSTACK-4186. Signature computed while accessing VM's console is not aligned with how signature is computed for other APIs

This commit is contained in:
Likitha Shetty 2013-08-08 16:16:31 +05:30 committed by root
parent 9a67a5d1ee
commit be5d076964

View File

@ -601,7 +601,7 @@ public class ConsoleProxyServlet extends HttpServlet {
mac.init(keySpec);
mac.update(unsignedRequest.getBytes());
byte[] encryptedBytes = mac.doFinal();
String computedSignature = Base64.encodeBase64URLSafeString(encryptedBytes);
String computedSignature = Base64.encodeBase64String(encryptedBytes);
boolean equalSig = signature.equals(computedSignature);
if (!equalSig) {
s_logger.debug("User signature: " + signature + " is not equaled to computed signature: " + computedSignature);