Lines Matching refs:struct

6 import struct
260 return struct.pack(fmt, self.session_handle, len(self.nonce),
266 return struct.calcsize(fmt)
278 return struct.pack(fmt, len(self.user_auth), self.user_auth,
283 return struct.calcsize(fmt)
311 return struct.pack(self.__fmt(),
322 return struct.calcsize(self.__fmt())
399 rc = struct.unpack('>I', rsp[6:10])[0]
401 cc = struct.unpack('>I', cmd[6:10])[0]
413 cmd = struct.pack(fmt,
415 struct.calcsize(fmt),
423 pcr_update_cnt, pcr_select_cnt = struct.unpack('>II', rsp[10:18])
427 alg2, pcrsel_len2 = struct.unpack('>HB', rsp[:3])
431 digest_cnt = struct.unpack('>I', rsp[:4])[0]
445 cmd = struct.pack(
448 struct.calcsize(fmt),
459 cmd = struct.pack(fmt,
461 struct.calcsize(fmt),
472 return struct.unpack('>I', self.send_cmd(cmd)[10:14])[0]
501 cmd = struct.pack(fmt,
503 struct.calcsize(fmt),
516 cmd = struct.pack(fmt,
518 struct.calcsize(fmt),
526 cmd = struct.pack(fmt,
528 struct.calcsize(fmt),
536 cmd = struct.pack(fmt,
538 struct.calcsize(fmt),
556 public_parms = struct.pack(
573 cmd = struct.pack(
576 struct.calcsize(fmt),
587 return struct.unpack('>I', self.send_cmd(cmd)[10:14])[0]
607 parameters=struct.pack('>H', TPM2_ALG_NULL))
611 cmd = struct.pack(
614 struct.calcsize(fmt),
630 private_len = struct.unpack('>H', blob[0:2])[0]
632 public_len = struct.unpack('>H', blob[public_start:public_start + 2])[0]
638 cmd = struct.pack(
641 struct.calcsize(fmt),
648 data_handle = struct.unpack('>I', self.send_cmd(cmd)[10:14])[0]
656 cmd = struct.pack(
659 struct.calcsize(fmt),
670 data_len = struct.unpack('>I', rsp[10:14])[0] - 2
678 cmd = struct.pack(
681 struct.calcsize(fmt),
693 cmd = struct.pack(fmt,
695 struct.calcsize(fmt),
700 more_data, cap, cnt = struct.unpack('>BII', rsp[:9])
704 handle = struct.unpack('>I', rsp[:4])[0]
726 cmd = struct.pack(fmt,
728 struct.calcsize(fmt),
732 _, _, cnt = struct.unpack('>BII', rsp[:9])
737 hash, sizeOfSelect = struct.unpack('>HB', rsp[:3])
742 pcrSelect, = struct.unpack('%ds' % sizeOfSelect,