-Bugfix: Fixed incorrect indention
-Bugfix: Do not default to MD5 hashing git-svn-id: https://vsmartcard.svn.sourceforge.net/svnroot/vsmartcard@448 96b47cad-a561-4643-ad3b-153ac7d7599c
This commit is contained in:
@@ -530,11 +530,11 @@ class CryptoflexSAM(SAM):
|
|||||||
# return SW["WARN_NOINFO63"], ""
|
# return SW["WARN_NOINFO63"], ""
|
||||||
|
|
||||||
def internal_authenticate(self,p1,p2,data):
|
def internal_authenticate(self,p1,p2,data):
|
||||||
data = data[::-1] #Reverse Byte order
|
data = data[::-1] #Reverse Byte order
|
||||||
sw, data = SAM.internal_authenticate(self, p1, p2, data)
|
sw, data = SAM.internal_authenticate(self, p1, p2, data)
|
||||||
if data != "":
|
if data != "":
|
||||||
data = data[::-1]
|
data = data[::-1]
|
||||||
return sw, data
|
return sw, data
|
||||||
|
|
||||||
class Security_Environment(object):
|
class Security_Environment(object):
|
||||||
|
|
||||||
@@ -944,7 +944,7 @@ class Secure_Messaging(object):
|
|||||||
if algo == None:
|
if algo == None:
|
||||||
raise SwError(SW["ERR_CONDITIONNOTSATISFIED"])
|
raise SwError(SW["ERR_CONDITIONNOTSATISFIED"])
|
||||||
try:
|
try:
|
||||||
hash = virtualsmartcard.CryptoUtils.hash("MD5",data)
|
hash = virtualsmartcard.CryptoUtils.hash(algo,data)
|
||||||
except ValueError: #FIXME: Type of error
|
except ValueError: #FIXME: Type of error
|
||||||
raise SwError(SW["ERR_SECMESSNOTSUPPORTED"])
|
raise SwError(SW["ERR_SECMESSNOTSUPPORTED"])
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user