fix spelling of TREZOR

This commit is contained in:
Pavol Rusnak 2016-02-10 16:46:58 +01:00
parent c665350a35
commit f3449fcbd7
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
13 changed files with 79 additions and 76 deletions

View File

@ -4,7 +4,7 @@ python-trezor
.. image:: https://travis-ci.org/trezor/python-trezor.svg?branch=master
:target: https://travis-ci.org/trezor/python-trezor
Client side implementation for Trezor-compatible Bitcoin hardware wallets.
Client side implementation for TREZOR-compatible Bitcoin hardware wallets.
See http://bitcointrezor.com for more information.

View File

@ -58,7 +58,7 @@ class TestZeroSig(common.TrezorTest):
(signatures, serialized_tx) = self.client.sign_tx('Bitcoin', [inp1, ], [out1, ])
siglen = ord(serialized_tx[44])
# Trezor must strip leading zero from signature
# TREZOR must strip leading zero from signature
self.assertEqual(siglen, 67)
def test_two_zero_signature(self):
@ -79,7 +79,7 @@ class TestZeroSig(common.TrezorTest):
(signatures, serialized_tx) = self.client.sign_tx('Bitcoin', [inp1, ], [out1, ])
siglen = ord(serialized_tx[44])
# Trezor must strip leading zero from signature
# TREZOR must strip leading zero from signature
self.assertEqual(siglen, 66)
if __name__ == '__main__':

View File

@ -1,7 +1,7 @@
#!/usr/bin/env python
'''
Use Trezor as a hardware key for opening EncFS filesystem!
Use TREZOR as a hardware key for opening EncFS filesystem!
Demo usage:
@ -20,7 +20,7 @@ from trezorlib.transport_hid import HidTransport
def wait_for_devices():
devices = HidTransport.enumerate()
while not len(devices):
sys.stderr.write("Please connect Trezor to computer and press Enter...")
sys.stderr.write("Please connect TREZOR to computer and press Enter...")
raw_input()
devices = HidTransport.enumerate()
@ -28,7 +28,7 @@ def wait_for_devices():
def choose_device(devices):
if not len(devices):
raise Exception("No Trezor connected!")
raise Exception("No TREZOR connected!")
if len(devices) == 1:
try:
@ -78,7 +78,7 @@ def main():
sys.stderr.write('Please provide label for new drive: ')
label = raw_input()
sys.stderr.write('Computer asked Trezor for new strong password.\n')
sys.stderr.write('Computer asked TREZOR for new strong password.\n')
sys.stderr.write('Please confirm action on your device.\n')
# 32 bytes, good for AES

View File

@ -10,7 +10,7 @@ import tempfile
from trezorlib.client import TrezorClient, TrezorClientDebug
def parse_args(commands):
parser = argparse.ArgumentParser(description='Commandline tool for Trezor devices.')
parser = argparse.ArgumentParser(description='Commandline tool for TREZOR devices.')
parser.add_argument('-v', '--verbose', dest='verbose', action='store_true', help='Prints communication to device')
parser.add_argument('-t', '--transport', dest='transport', choices=['usb', 'serial', 'pipe', 'socket', 'bridge'], default='usb', help="Transport used for talking with the device")
parser.add_argument('-p', '--path', dest='path', default='', help="Path used by the transport (usually serial port)")
@ -46,7 +46,7 @@ def get_transport(transport_string, path, **kwargs):
try:
path = list_usb()[0][0]
except IndexError:
raise Exception("No Trezor found on USB")
raise Exception("No TREZOR found on USB")
for d in HidTransport.enumerate():
# Two-tuple of (normal_interface, debug_interface)
@ -237,14 +237,14 @@ class Commands(object):
fp.seek(0)
if fp.read(4) != 'TRZR':
raise Exception("Trezor firmware header expected")
raise Exception("TREZOR firmware header expected")
print "Please confirm action on device..."
fp.seek(0)
return self.client.firmware_update(fp=fp)
list.help = 'List connected Trezor USB devices'
list.help = 'List connected TREZOR USB devices'
ping.help = 'Send ping message'
get_address.help = 'Get bitcoin address in base58 encoding'
get_entropy.help = 'Get example entropy'

View File

@ -105,6 +105,9 @@ class BaseClient(object):
self.transport = transport
super(BaseClient, self).__init__() # *args, **kwargs)
def cancel(self):
self.transport.write(proto.Cancel())
def call_raw(self, msg):
try:
self.transport.session_begin()

View File

@ -21,7 +21,7 @@ class PinMatrixWidget(QWidget):
'''
Displays widget with nine blank buttons and password box.
Encodes button clicks into sequence of numbers for passing
into PinAck messages of Trezor.
into PinAck messages of TREZOR.
show_strength=True may be useful for entering new PIN
'''

View File

@ -50,7 +50,7 @@ class BridgeTransport(Transport):
enum = r.json()
return enum;
return enum
def _open(self):

View File

@ -6,8 +6,8 @@ import platform
from transport import Transport, ConnectionError, NotImplementedException
DEVICE_IDS = [
# (0x10c4, 0xea80), # Shield
(0x534c, 0x0001), # Trezor
# (0x10c4, 0xea80), # TREZOR Shield
(0x534c, 0x0001), # TREZOR
(0x2b24, 0x0001), # KeepKey
]
@ -71,7 +71,7 @@ class HidTransport(Transport):
self.hid = hid.device()
self.hid.open_path(self.device)
self.hid.set_nonblocking(True)
# the following was needed just for Trezor Shield
# the following was needed just for TREZOR Shield
# self.hid.send_feature_report([0x41, 0x01]) # enable UART
# self.hid.send_feature_report([0x43, 0x03]) # purge TX/RX FIFOs