Index: /tags/Beta_AMP_3_6_0_1/src/webui/webui/htdocs/new/src/cm/models/device_mgmt/device/__init__.py
===================================================================
--- /tags/Beta_AMP_3_6_0_1/src/webui/webui/htdocs/new/src/cm/models/device_mgmt/device/__init__.py	(revision 2323)
+++ /tags/Beta_AMP_3_6_0_1/src/webui/webui/htdocs/new/src/cm/models/device_mgmt/device/__init__.py	(working copy)
@@ -1,3 +1,7 @@
+# hash restapi passowrd with md5 by Jason Chou
+import hashlib
+from django.utils.encoding import force_bytes
+
 from hive.imports.model import *
 from django.utils.translation import ugettext_lazy as _
 from hive.utils import andebug, get_device_type, standard_model_type
@@ -296,6 +300,8 @@
                 del each['extend']
                 each["backup_enable"] = False
                 each['device_group'] = [{'name': each['device_group']}]
+                # hash restapi passowrd with md5 by Jason Chou
+                each['restapi_password'] = hashlib.md5(force_bytes(each['restapi_password'])).hexdigest()
                 each['restapi_account'] = {'restapi_username': each['restapi_username'], 'restapi_password': each['restapi_password']}
                 del each['restapi_username']
                 del each['restapi_password']
