From 8edfc90fbe2479d7456710139efeab6dc65a9ba5 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Tue, 30 Dec 2008 03:39:43 +0100 Subject: skyped: use hashlib instead of sha (python2.6 warning) --- skype/skyped.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'skype') diff --git a/skype/skyped.py b/skype/skyped.py index 0347bcdc..4f274be7 100644 --- a/skype/skyped.py +++ b/skype/skyped.py @@ -29,7 +29,7 @@ import gobject import socket import getopt import Skype4Py -import sha +import hashlib from ConfigParser import ConfigParser, NoOptionError from traceback import print_exception @@ -122,7 +122,7 @@ def listener(sock, *args): if line.startswith("USERNAME") and line.split(' ')[1].strip() == options.config.username: ret += 1 line = options.conn.recv(1024) - if line.startswith("PASSWORD") and sha.sha(line.split(' ')[1].strip()).hexdigest() == options.config.password: + if line.startswith("PASSWORD") and hashlib.sha1(line.split(' ')[1].strip()).hexdigest() == options.config.password: ret += 1 except Exception, s: dprint("Warning, receiving 1024 bytes failed (%s)." % s) -- cgit v1.2.3