aboutsummaryrefslogtreecommitdiff
path: root/tests/functional_tests/test_framework/wallet.py
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-03-19 10:39:26 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-03-21 19:28:44 +0000
commit0becbd16123f05607fe6b759591c13fb05ac9d3d (patch)
tree0329441c81c700c2032a600d0e20a9cef97e9028 /tests/functional_tests/test_framework/wallet.py
parentfunctional_tests: add multisig and cold signing tests (diff)
downloadmonero-0becbd16123f05607fe6b759591c13fb05ac9d3d.tar.xz
functional_tests: add message signing/verification tests
Diffstat (limited to 'tests/functional_tests/test_framework/wallet.py')
-rw-r--r--tests/functional_tests/test_framework/wallet.py24
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/functional_tests/test_framework/wallet.py b/tests/functional_tests/test_framework/wallet.py
index 270c95f82..340eed179 100644
--- a/tests/functional_tests/test_framework/wallet.py
+++ b/tests/functional_tests/test_framework/wallet.py
@@ -482,3 +482,27 @@ class Wallet(object):
'id': '0'
}
return self.rpc.send_json_rpc_request(get_tx_key)
+
+ def sign(self, data):
+ sign = {
+ 'method': 'sign',
+ 'params' : {
+ 'data': data,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(sign)
+
+ def verify(self, data, address, signature):
+ verify = {
+ 'method': 'verify',
+ 'params' : {
+ 'data': data,
+ 'address': address,
+ 'signature': signature,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(verify)