aboutsummaryrefslogtreecommitdiff
path: root/utils/python-rpc
diff options
context:
space:
mode:
authorLee Clagett <code@leeclagett.com>2020-03-26 12:24:11 +0000
committerLee Clagett <code@leeclagett.com>2020-03-30 17:52:42 +0000
commitbabf25d2ec133833dcad0b42121a187463ecccb0 (patch)
tree98181887cd6dc015f7e44ab718d8f9b9631458fd /utils/python-rpc
parentMerge pull request #6314 (diff)
downloadmonero-babf25d2ec133833dcad0b42121a187463ecccb0.tar.xz
Allow unrestricted rpc calls to get full txpool info
Diffstat (limited to 'utils/python-rpc')
-rw-r--r--utils/python-rpc/framework/daemon.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/utils/python-rpc/framework/daemon.py b/utils/python-rpc/framework/daemon.py
index 749d9ed88..074f8de37 100644
--- a/utils/python-rpc/framework/daemon.py
+++ b/utils/python-rpc/framework/daemon.py
@@ -32,10 +32,11 @@ from .rpc import JSONRPC
class Daemon(object):
- def __init__(self, protocol='http', host='127.0.0.1', port=0, idx=0):
+ def __init__(self, protocol='http', host='127.0.0.1', port=0, idx=0, restricted_rpc = False):
+ base = 18480 if restricted_rpc else 18180
self.host = host
self.port = port
- self.rpc = JSONRPC('{protocol}://{host}:{port}'.format(protocol=protocol, host=host, port=port if port else 18180+idx))
+ self.rpc = JSONRPC('{protocol}://{host}:{port}'.format(protocol=protocol, host=host, port=port if port else base+idx))
def getblocktemplate(self, address, prev_block = "", client = ""):
getblocktemplate = {