summaryrefslogtreecommitdiff
path: root/lib/dnspython/dns/dnssec.py
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2011-08-27 16:07:52 +0200
committerJelmer Vernooij <jelmer@samba.org>2011-08-27 17:40:39 +0200
commit8bd71350abe48fdcfc0125e48fa97abdf31e1270 (patch)
tree2873d7fc77f9ec1992e24886a9feae80b48ffaef /lib/dnspython/dns/dnssec.py
parentbd01a8e79faa3d657f01529c063cd0e09d711880 (diff)
downloadsamba-8bd71350abe48fdcfc0125e48fa97abdf31e1270.tar.gz
samba-8bd71350abe48fdcfc0125e48fa97abdf31e1270.tar.bz2
samba-8bd71350abe48fdcfc0125e48fa97abdf31e1270.zip
dnspython: Update to latest upstream snapshot.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sat Aug 27 17:40:39 CEST 2011 on sn-devel-104
Diffstat (limited to 'lib/dnspython/dns/dnssec.py')
-rw-r--r--lib/dnspython/dns/dnssec.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/dnspython/dns/dnssec.py b/lib/dnspython/dns/dnssec.py
index a595fd4478..dd6a27a536 100644
--- a/lib/dnspython/dns/dnssec.py
+++ b/lib/dnspython/dns/dnssec.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2003-2007, 2009 Nominum, Inc.
+# Copyright (C) 2003-2007, 2009, 2011 Nominum, Inc.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose with or without fee is hereby granted,
@@ -99,7 +99,7 @@ def key_id(key, origin=None):
return (ord(rdata[-3]) << 8) + ord(rdata[-2])
else:
total = 0
- for i in range(len(rdata) / 2):
+ for i in range(len(rdata) // 2):
total += (ord(rdata[2 * i]) << 8) + ord(rdata[2 * i + 1])
if len(rdata) % 2 != 0:
total += ord(rdata[len(rdata) - 1]) << 8
@@ -299,7 +299,7 @@ def _validate_rrsig(rrset, rrsig, keys, origin=None, now=None):
if _is_rsa(rrsig.algorithm):
# PKCS1 algorithm identifier goop
digest = _make_algorithm_id(rrsig.algorithm) + digest
- padlen = keylen / 8 - len(digest) - 3
+ padlen = keylen // 8 - len(digest) - 3
digest = chr(0) + chr(1) + chr(0xFF) * padlen + chr(0) + digest
elif _is_dsa(rrsig.algorithm):
pass