aboutsummaryrefslogtreecommitdiffstats
path: root/pathod
diff options
context:
space:
mode:
authorAldo Cortesi <aldo@nullcube.com>2016-10-17 17:11:21 +1300
committerAldo Cortesi <aldo@nullcube.com>2016-10-17 17:37:08 +1300
commitfb22f2ff4f75783ba786935c93b75f372ede21f5 (patch)
treea7055ebd090e11b163efa81b86086b7f88ca89e6 /pathod
parent666c59cbfbcbd28062c201c3cb5d6cb928e90aee (diff)
downloadmitmproxy-fb22f2ff4f75783ba786935c93b75f372ede21f5.tar.gz
mitmproxy-fb22f2ff4f75783ba786935c93b75f372ede21f5.tar.bz2
mitmproxy-fb22f2ff4f75783ba786935c93b75f372ede21f5.zip
Zap object base class
Diffstat (limited to 'pathod')
-rw-r--r--pathod/language/base.py4
-rw-r--r--pathod/language/generators.py6
-rw-r--r--pathod/language/http.py2
-rw-r--r--pathod/language/http2.py2
-rw-r--r--pathod/language/message.py2
-rw-r--r--pathod/log.py2
-rw-r--r--pathod/pathoc.py2
-rw-r--r--pathod/pathod.py2
-rw-r--r--pathod/protocols/http.py2
-rw-r--r--pathod/protocols/http2.py6
-rw-r--r--pathod/utils.py2
11 files changed, 16 insertions, 16 deletions
diff --git a/pathod/language/base.py b/pathod/language/base.py
index bdcc6d2f..4483c3df 100644
--- a/pathod/language/base.py
+++ b/pathod/language/base.py
@@ -10,7 +10,7 @@ from netlib import human
from . import generators, exceptions
-class Settings(object):
+class Settings():
def __init__(
self,
@@ -60,7 +60,7 @@ v_naked_literal = pp.MatchFirst(
)
-class Token(object):
+class Token():
"""
A token in the specification language. Tokens are immutable. The token
diff --git a/pathod/language/generators.py b/pathod/language/generators.py
index 4040e099..6a543907 100644
--- a/pathod/language/generators.py
+++ b/pathod/language/generators.py
@@ -18,7 +18,7 @@ DATATYPES = dict(
)
-class TransformGenerator(object):
+class TransformGenerator():
"""
Perform a byte-by-byte transform another generator - that is, for each
@@ -54,7 +54,7 @@ def rand_byte(chars):
return bytes([random.choice(chars)])
-class RandomGenerator(object):
+class RandomGenerator():
def __init__(self, dtype, length):
self.dtype = dtype
@@ -73,7 +73,7 @@ class RandomGenerator(object):
return "%s random from %s" % (self.length, self.dtype)
-class FileGenerator(object):
+class FileGenerator():
def __init__(self, path):
self.path = path
diff --git a/pathod/language/http.py b/pathod/language/http.py
index 46027ca3..1f1a3db3 100644
--- a/pathod/language/http.py
+++ b/pathod/language/http.py
@@ -53,7 +53,7 @@ class Method(base.OptionsOrValue):
]
-class _HeaderMixin(object):
+class _HeaderMixin():
unique_name = None
def format_header(self, key, value):
diff --git a/pathod/language/http2.py b/pathod/language/http2.py
index 519ee699..7cb82916 100644
--- a/pathod/language/http2.py
+++ b/pathod/language/http2.py
@@ -40,7 +40,7 @@ def get_header(val, headers):
return None
-class _HeaderMixin(object):
+class _HeaderMixin():
unique_name = None
def values(self, settings):
diff --git a/pathod/language/message.py b/pathod/language/message.py
index fea4f4de..7a8594d6 100644
--- a/pathod/language/message.py
+++ b/pathod/language/message.py
@@ -5,7 +5,7 @@ from netlib import strutils
LOG_TRUNCATE = 1024
-class Message(object):
+class Message():
__metaclass__ = abc.ABCMeta
logattrs = []
diff --git a/pathod/log.py b/pathod/log.py
index 1a709dc6..05934fd3 100644
--- a/pathod/log.py
+++ b/pathod/log.py
@@ -13,7 +13,7 @@ def write_raw(fp, lines, timestamp=True):
fp.flush()
-class LogCtx(object):
+class LogCtx():
def __init__(self, fp, hex, timestamp, rfile, wfile):
self.lines = []
diff --git a/pathod/pathoc.py b/pathod/pathoc.py
index f122c14f..008308ca 100644
--- a/pathod/pathoc.py
+++ b/pathod/pathoc.py
@@ -34,7 +34,7 @@ class PathocError(Exception):
pass
-class SSLInfo(object):
+class SSLInfo():
def __init__(self, certchain, cipher, alp):
self.certchain, self.cipher, self.alp = certchain, cipher, alp
diff --git a/pathod/pathod.py b/pathod/pathod.py
index e882b73e..f67ad04e 100644
--- a/pathod/pathod.py
+++ b/pathod/pathod.py
@@ -30,7 +30,7 @@ class PathodError(Exception):
pass
-class SSLOptions(object):
+class SSLOptions():
def __init__(
self,
confdir=CONFDIR,
diff --git a/pathod/protocols/http.py b/pathod/protocols/http.py
index 2ede2591..5ac8516f 100644
--- a/pathod/protocols/http.py
+++ b/pathod/protocols/http.py
@@ -4,7 +4,7 @@ from netlib.http import http1
from .. import language
-class HTTPProtocol(object):
+class HTTPProtocol():
def __init__(self, pathod_handler):
self.pathod_handler = pathod_handler
diff --git a/pathod/protocols/http2.py b/pathod/protocols/http2.py
index 78fe6111..42f1a1a0 100644
--- a/pathod/protocols/http2.py
+++ b/pathod/protocols/http2.py
@@ -15,14 +15,14 @@ import netlib.http.request
from .. import language
-class TCPHandler(object):
+class TCPHandler():
def __init__(self, rfile, wfile=None):
self.rfile = rfile
self.wfile = wfile
-class HTTP2StateProtocol(object):
+class HTTP2StateProtocol():
ERROR_CODES = utils.BiDi(
NO_ERROR=0x0,
@@ -403,7 +403,7 @@ class HTTP2StateProtocol(object):
return stream_id, headers, body
-class HTTP2Protocol(object):
+class HTTP2Protocol():
def __init__(self, pathod_handler):
self.pathod_handler = pathod_handler
diff --git a/pathod/utils.py b/pathod/utils.py
index 9b220e9a..07b6933e 100644
--- a/pathod/utils.py
+++ b/pathod/utils.py
@@ -3,7 +3,7 @@ import sys
import netlib.utils
-class MemBool(object):
+class MemBool():
"""
Truth-checking with a memory, for use in chained if statements.