Bugfixes: Wrong number of arguments for function call and missing import

git-svn-id: https://vsmartcard.svn.sourceforge.net/svnroot/vsmartcard@474 96b47cad-a561-4643-ad3b-153ac7d7599c
This commit is contained in:
oepen
2011-08-01 12:59:25 +00:00
parent 25cf21afb2
commit e33544452f
2 changed files with 4 additions and 1 deletions

View File

@@ -124,7 +124,7 @@ def crypto_checksum(algo, key, data, iv=None, ssc=None):
raise ValueError, "Unknown Algorithm %s" % algo
if algo == "MAC":
checksum = calculate_MAC(key, data, 0x00, iv) #FIXME: IV?
checksum = calculate_MAC(key, data, iv)
elif algo == "HMAC":
hmac = HMAC.new(key, data)
checksum = hmac.hexdigest()

View File

@@ -16,6 +16,9 @@
# You should have received a copy of the GNU General Public License along with
# virtualsmartcard. If not, see <http://www.gnu.org/licenses/>.
#
from vsmartcard.utils import stringtoint
TAG = {}
TAG["FILECONTROLPARAMETERS"] = 0x62
TAG["FILEMANAGEMENTDATA"] = 0x64