(self, hash, privateKey)
| 3889 | return '0x' + self.hash(self.binary_concat(prefix, binaryMessage), 'keccak', 'hex') |
| 3890 | |
| 3891 | def sign_hash(self, hash, privateKey): |
| 3892 | self.check_required_credentials() |
| 3893 | signature = self.ecdsa(hash[-64:], privateKey[-64:], 'secp256k1', None) |
| 3894 | r = signature['r'] |
| 3895 | s = signature['s'] |
| 3896 | v = self.int_to_base16(self.sum(27, signature['v'])) |
| 3897 | return '0x' + r.rjust(64, '0') + s.rjust(64, '0') + v |
| 3898 | |
| 3899 | def sign(self, path, api: Any = 'public', method='GET', params={}, headers: dict = None, body: Any = None): |
| 3900 | url = self.urls['api'][api] + '/' + path |
no test coverage detected