You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by pq...@apache.org on 2010/01/08 01:19:35 UTC

svn commit: r897062 - /incubator/libcloud/trunk/libcloud/drivers/gogrid.py

Author: pquerna
Date: Fri Jan  8 00:19:35 2010
New Revision: 897062

URL: http://svn.apache.org/viewvc?rev=897062&view=rev
Log:
Use hashlib instead of deprecated md5 library

Modified:
    incubator/libcloud/trunk/libcloud/drivers/gogrid.py

Modified: incubator/libcloud/trunk/libcloud/drivers/gogrid.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/drivers/gogrid.py?rev=897062&r1=897061&r2=897062&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/drivers/gogrid.py (original)
+++ incubator/libcloud/trunk/libcloud/drivers/gogrid.py Fri Jan  8 00:19:35 2010
@@ -23,7 +23,7 @@
 import httplib
 import time
 import urllib
-import md5, hashlib
+import hashlib
 
 # JSON is included in the standard library starting with Python 2.6.  For 2.5
 # and 2.4, there's a simplejson egg at: http://pypi.python.org/pypi/simplejson
@@ -106,7 +106,7 @@
         
     def get_signature(self, key, secret):
         """ create sig from md5 of key + secret + time """
-        m = md5.new(key+secret+str(int(time.time())))
+        m = hashlib.md5(key+secret+str(int(time.time())))
         return m.hexdigest()
 
 class GoGridNode(Node):