aboutsummaryrefslogtreecommitdiffstats
path: root/mitmproxy/contrib
diff options
context:
space:
mode:
authorDavid Shaw <shawd@vmware.com>2017-03-06 17:30:40 -0500
committerDavid Shaw <shawd@vmware.com>2017-03-06 17:30:40 -0500
commit5d820682185aa8b0d82d5bec49b7c7e6a9818d23 (patch)
treead93c00aaee2f444f1cb4efa30da1538d88b5d51 /mitmproxy/contrib
parent22154dee5c4ecec5eb9ef0fb1a2ce98fd0d39ecd (diff)
downloadmitmproxy-5d820682185aa8b0d82d5bec49b7c7e6a9818d23.tar.gz
mitmproxy-5d820682185aa8b0d82d5bec49b7c7e6a9818d23.tar.bz2
mitmproxy-5d820682185aa8b0d82d5bec49b7c7e6a9818d23.zip
Updated for python 3
Diffstat (limited to 'mitmproxy/contrib')
-rw-r--r--mitmproxy/contrib/wbxml/ASCommandResponse.py2
-rw-r--r--mitmproxy/contrib/wbxml/ASWBXMLByteQueue.py2
-rw-r--r--mitmproxy/contrib/wbxml/ASWBXMLCodePage.py4
3 files changed, 4 insertions, 4 deletions
diff --git a/mitmproxy/contrib/wbxml/ASCommandResponse.py b/mitmproxy/contrib/wbxml/ASCommandResponse.py
index f5f62e85..4eea05a3 100644
--- a/mitmproxy/contrib/wbxml/ASCommandResponse.py
+++ b/mitmproxy/contrib/wbxml/ASCommandResponse.py
@@ -41,7 +41,7 @@ class ASCommandResponse:
raise ValueError("Empty WBXML body passed")
except Exception as e:
self.xmlString = None
- raise ValueError("Error: {0}".format(e.message))
+ raise ValueError("Error: {0}".format(e))
def getWBXMLBytes(self):
return self.wbxmlBytes
diff --git a/mitmproxy/contrib/wbxml/ASWBXMLByteQueue.py b/mitmproxy/contrib/wbxml/ASWBXMLByteQueue.py
index b616028c..0174eb4f 100644
--- a/mitmproxy/contrib/wbxml/ASWBXMLByteQueue.py
+++ b/mitmproxy/contrib/wbxml/ASWBXMLByteQueue.py
@@ -40,7 +40,7 @@ class ASWBXMLByteQueue(Queue):
Queue.__init__(self)
for byte in wbxmlBytes:
- self.put(ord(byte))
+ self.put(byte)
self.bytesEnqueued += 1
diff --git a/mitmproxy/contrib/wbxml/ASWBXMLCodePage.py b/mitmproxy/contrib/wbxml/ASWBXMLCodePage.py
index 1d00afd4..da84a85e 100644
--- a/mitmproxy/contrib/wbxml/ASWBXMLCodePage.py
+++ b/mitmproxy/contrib/wbxml/ASWBXMLCodePage.py
@@ -39,12 +39,12 @@ class ASWBXMLCodePage:
self.tagLookup[tag] = token
def getToken(self, tag):
- if self.tagLookup.has_key(tag):
+ if tag in self.tagLookup:
return self.tagLookup[tag]
return 0xFF
def getTag(self, token):
- if self.tokenLookup.has_key(token):
+ if token in self.tokenLookup:
return self.tokenLookup[token]
return None