daily pastebin goal
34%
SHARE
TWEET

Untitled

a guest Jun 14th, 2018 55 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import struct
  2. import io
  3. import binascii
  4. from trezorlib import messages, protobuf, mapping
  5.  
  6. message = messages.DebugLinkDecision(yes_no=True)
  7.  
  8. writer = io.BytesIO()
  9. protobuf.dump_message(writer, message)
  10. data = writer.getvalue()
  11. header = struct.pack(">HL", mapping.get_type(message), len(data))
  12.  
  13. total = header + data
  14.  
  15. print(binascii.hex
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top