mirror of
				https://github.com/apache/cloudstack.git
				synced 2025-11-04 00:02:37 +01:00 
			
		
		
		
	bug 8313: still encrypt the passwords when setting up account
This commit is contained in:
		
							parent
							
								
									1dee569f0e
								
							
						
					
					
						commit
						426b464aab
					
				@ -16,7 +16,8 @@
 | 
				
			|||||||
 * 
 | 
					 * 
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
// Default password is MD5 hashed.  Set the following variable to false to disable this.
 | 
					// Default password is MD5 hashed.  Set the following variable to false to disable this.
 | 
				
			||||||
var md5Hashed = false;
 | 
					var md5Hashed = true;
 | 
				
			||||||
 | 
					var md5HashedLogin = false;
 | 
				
			||||||
 
 | 
					 
 | 
				
			||||||
$(document).ready(function() { 
 | 
					$(document).ready(function() { 
 | 
				
			||||||
	function initUI() {
 | 
						function initUI() {
 | 
				
			||||||
@ -659,7 +660,7 @@ $(document).ready(function() {
 | 
				
			|||||||
		array1.push("&username="+encodeURIComponent(username));
 | 
							array1.push("&username="+encodeURIComponent(username));
 | 
				
			||||||
		
 | 
							
 | 
				
			||||||
		var password = $("#account_password").val();
 | 
							var password = $("#account_password").val();
 | 
				
			||||||
		if (md5Hashed) {
 | 
							if (md5HashedLogin) {
 | 
				
			||||||
			password = $.md5(password);
 | 
								password = $.md5(password);
 | 
				
			||||||
		} 
 | 
							} 
 | 
				
			||||||
		array1.push("&password="+password);
 | 
							array1.push("&password="+password);
 | 
				
			||||||
 | 
				
			|||||||
@ -136,7 +136,7 @@
 | 
				
			|||||||
        array1.push("&username=" + encodeURIComponent(args.data.username));
 | 
					        array1.push("&username=" + encodeURIComponent(args.data.username));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        var password;
 | 
					        var password;
 | 
				
			||||||
        if (md5Hashed)
 | 
					        if (md5HashedLogin)
 | 
				
			||||||
          password = $.md5(args.data.password);
 | 
					          password = $.md5(args.data.password);
 | 
				
			||||||
        else
 | 
					        else
 | 
				
			||||||
          password = args.data.password;
 | 
					          password = args.data.password;
 | 
				
			||||||
 | 
				
			|||||||
@ -22,7 +22,8 @@ var ERROR_INTERNET_CANNOT_CONNECT = 12029;
 | 
				
			|||||||
var ERROR_VMOPS_ACCOUNT_ERROR = 531;
 | 
					var ERROR_VMOPS_ACCOUNT_ERROR = 531;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// Default password is MD5 hashed.  Set the following variable to false to disable this.
 | 
					// Default password is MD5 hashed.  Set the following variable to false to disable this.
 | 
				
			||||||
var md5Hashed = false;
 | 
					var md5Hashed = true;
 | 
				
			||||||
 | 
					var md5HashedLogin = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
//page size for API call (e.g."listXXXXXXX&pagesize=N" )
 | 
					//page size for API call (e.g."listXXXXXXX&pagesize=N" )
 | 
				
			||||||
var pageSize = 50;
 | 
					var pageSize = 50;
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user