tpm2_pcrallocate.1 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608
  1. .\" Automatically generated by Pandoc 1.19.2.4
  2. .\"
  3. .TH "tpm2_pcrallocate" "1" "" "tpm2\-tools" "General Commands Manual"
  4. .hy
  5. .SH NAME
  6. .PP
  7. \f[B]tpm2_pcrallocate\f[](1) \- Configure PCRs and bank algorithms.
  8. .SH SYNOPSIS
  9. .PP
  10. \f[B]tpm2_pcrallocate\f[] [\f[I]OPTIONS\f[]] [*ARGUMENT]
  11. .SH DESCRIPTION
  12. .PP
  13. \f[B]tpm2_pcrallocate\f[](1) \- Allow the user to specify a PCR
  14. allocation for the TPM.
  15. An allocation is the enabling or disabling of PCRs and it\[aq]s banks.
  16. A PCR can have multiple banks, where each bank is associated with a
  17. specific hashing algorithm.
  18. Allocation is specified in the argument.
  19. .PP
  20. If no allocation is given, then SHA1 and SHA256 banks with PCRs 0 \- 23
  21. are allocated.
  22. .PP
  23. Allocation is a list of banks and selected pcrs.
  24. The values should follow the pcr bank specifiers standards, see section
  25. "PCR Bank Specifiers".
  26. .PP
  27. The new allocations become effective after the next reboot.
  28. .PP
  29. \f[B]Note\f[]: This command requires platform authorization.
  30. .SH OPTIONS
  31. .IP \[bu] 2
  32. \f[B]\-P\f[], \f[B]\-\-auth\f[]=\f[I]AUTH\f[]:
  33. .RS 2
  34. .PP
  35. Optional authorization value.
  36. Authorization values should follow the "authorization formatting
  37. standards", see section "Authorization Formatting".
  38. .RE
  39. .IP \[bu] 2
  40. \f[B]ARGUMENT\f[] the command line argument specifies the PCR
  41. allocation.
  42. .SS References
  43. .SH Context Object Format
  44. .PP
  45. The type of a context object, whether it is a handle or file name, is
  46. determined according to the following logic \f[I]in\-order\f[]:
  47. .IP \[bu] 2
  48. If the argument is a file path, then the file is loaded as a restored
  49. TPM transient object.
  50. .IP \[bu] 2
  51. If the argument is a \f[I]prefix\f[] match on one of:
  52. .RS 2
  53. .IP \[bu] 2
  54. owner: the owner hierarchy
  55. .IP \[bu] 2
  56. platform: the platform hierarchy
  57. .IP \[bu] 2
  58. endorsement: the endorsement hierarchy
  59. .IP \[bu] 2
  60. lockout: the lockout control persistent object
  61. .RE
  62. .IP \[bu] 2
  63. If the argument argument can be loaded as a number it will be treat as a
  64. handle, e.g.
  65. 0x81010013 and used directly.\f[I]OBJECT\f[].
  66. .SH Authorization Formatting
  67. .PP
  68. Authorization for use of an object in TPM2.0 can come in 3 different
  69. forms: 1.
  70. Password 2.
  71. HMAC 3.
  72. Sessions
  73. .PP
  74. \f[B]NOTE:\f[] "Authorizations default to the \f[B]EMPTY PASSWORD\f[]
  75. when not specified".
  76. .SS Passwords
  77. .PP
  78. Passwords are interpreted in the following forms below using prefix
  79. identifiers.
  80. .PP
  81. \f[B]Note\f[]: By default passwords are assumed to be in the string form
  82. when they do not have a prefix.
  83. .SS String
  84. .PP
  85. A string password, specified by prefix "str:" or it\[aq]s absence (raw
  86. string without prefix) is not interpreted, and is directly used for
  87. authorization.
  88. .SS Examples
  89. .IP
  90. .nf
  91. \f[C]
  92. foobar
  93. str:foobar
  94. \f[]
  95. .fi
  96. .SS Hex\-string
  97. .PP
  98. A hex\-string password, specified by prefix "hex:" is converted from a
  99. hexidecimal form into a byte array form, thus allowing passwords with
  100. non\-printable and/or terminal un\-friendly characters.
  101. .SS Example
  102. .IP
  103. .nf
  104. \f[C]
  105. hex:0x1122334455667788
  106. \f[]
  107. .fi
  108. .SS File
  109. .PP
  110. A file based password, specified be prefix "file:" should be the path of
  111. a file containing the password to be read by the tool or a "\-" to use
  112. stdin.
  113. Storing passwords in files prevents information leakage, passwords
  114. passed as options can be read from the process list or common shell
  115. history features.
  116. .SS Examples
  117. .IP
  118. .nf
  119. \f[C]
  120. #\ to\ use\ stdin\ and\ be\ prompted
  121. file:\-
  122. #\ to\ use\ a\ file\ from\ a\ path
  123. file:path/to/password/file
  124. #\ to\ echo\ a\ password\ via\ stdin:
  125. echo\ foobar\ |\ tpm2_tool\ \-p\ file:\-
  126. #\ to\ use\ a\ bash\ here\-string\ via\ stdin:
  127. tpm2_tool\ \-p\ file:\-\ <<<\ foobar
  128. \f[]
  129. .fi
  130. .SS Sessions
  131. .PP
  132. When using a policy session to authorize the use of an object, prefix
  133. the option argument with the \f[I]session\f[] keyword.
  134. Then indicate a path to a session file that was created with
  135. tpm2_startauthsession(1).
  136. Optionally, if the session requires an auth value to be sent with the
  137. session handle (eg policy password), then append a + and a string as
  138. described in the \f[B]Passwords\f[] section.
  139. .SS Examples
  140. .PP
  141. To use a session context file called \f[I]session.ctx\f[].
  142. .IP
  143. .nf
  144. \f[C]
  145. session:session.ctx
  146. \f[]
  147. .fi
  148. .PP
  149. To use a session context file called \f[I]session.ctx\f[] \f[B]AND\f[]
  150. send the authvalue mypassword.
  151. .IP
  152. .nf
  153. \f[C]
  154. session:session.ctx+mypassword
  155. \f[]
  156. .fi
  157. .PP
  158. To use a session context file called \f[I]session.ctx\f[] \f[B]AND\f[]
  159. send the \f[I]HEX\f[] authvalue 0x11223344.
  160. .IP
  161. .nf
  162. \f[C]
  163. session:session.ctx+hex:11223344
  164. \f[]
  165. .fi
  166. .SS PCR Authorizations
  167. .PP
  168. You can satisfy a PCR policy using the "pcr:" prefix and the PCR
  169. minilanguage.
  170. The PCR minilanguage is as follows:
  171. \f[C]<pcr\-spec>=<raw\-pcr\-file>\f[]
  172. .PP
  173. The PCR spec is documented in in the section "PCR bank specifiers".
  174. .PP
  175. The \f[C]raw\-pcr\-file\f[] is an \f[B]optional\f[] the output of the
  176. raw PCR contents as returned by \f[I]tpm2_pcrread(1)\f[].
  177. .PP
  178. PCR bank specifiers (common/pcr.md)
  179. .SS Examples
  180. .PP
  181. To satisfy a PCR policy of sha256 on banks 0, 1, 2 and 3 use a specifier
  182. of:
  183. .IP
  184. .nf
  185. \f[C]
  186. pcr:sha256:0,1,2,3
  187. \f[]
  188. .fi
  189. .PP
  190. specifying \f[I]AUTH\f[].
  191. .SH Algorithm Specifiers
  192. .PP
  193. Options that take algorithms support "nice\-names".
  194. .PP
  195. There are two major algorithm specification string classes, simple and
  196. complex.
  197. Only certain algorithms will be accepted by the TPM, based on usage and
  198. conditions.
  199. .SS Simple specifiers
  200. .PP
  201. These are strings with no additional specification data.
  202. When creating objects, non\-specified portions of an object are assumed
  203. to defaults.
  204. You can find the list of known "Simple Specifiers Below".
  205. .SS Asymmetric
  206. .IP \[bu] 2
  207. rsa
  208. .IP \[bu] 2
  209. ecc
  210. .SS Symmetric
  211. .IP \[bu] 2
  212. aes
  213. .IP \[bu] 2
  214. camellia
  215. .SS Hashing Algorithms
  216. .IP \[bu] 2
  217. sha1
  218. .IP \[bu] 2
  219. sha256
  220. .IP \[bu] 2
  221. sha384
  222. .IP \[bu] 2
  223. sha512
  224. .IP \[bu] 2
  225. sm3_256
  226. .IP \[bu] 2
  227. sha3_256
  228. .IP \[bu] 2
  229. sha3_384
  230. .IP \[bu] 2
  231. sha3_512
  232. .SS Keyed Hash
  233. .IP \[bu] 2
  234. hmac
  235. .IP \[bu] 2
  236. xor
  237. .SS Signing Schemes
  238. .IP \[bu] 2
  239. rsassa
  240. .IP \[bu] 2
  241. rsapss
  242. .IP \[bu] 2
  243. ecdsa
  244. .IP \[bu] 2
  245. ecdaa
  246. .IP \[bu] 2
  247. ecschnorr
  248. .SS Asymmetric Encryption Schemes
  249. .IP \[bu] 2
  250. oaep
  251. .IP \[bu] 2
  252. rsaes
  253. .IP \[bu] 2
  254. ecdh
  255. .SS Modes
  256. .IP \[bu] 2
  257. ctr
  258. .IP \[bu] 2
  259. ofb
  260. .IP \[bu] 2
  261. cbc
  262. .IP \[bu] 2
  263. cfb
  264. .IP \[bu] 2
  265. ecb
  266. .SS Misc
  267. .IP \[bu] 2
  268. null
  269. .SS Complex Specifiers
  270. .PP
  271. Objects, when specified for creation by the TPM, have numerous
  272. algorithms to populate in the public data.
  273. Things like type, scheme and asymmetric details, key size, etc.
  274. Below is the general format for specifying this data:
  275. \f[C]<type>:<scheme>:<symmetric\-details>\f[]
  276. .SS Type Specifiers
  277. .PP
  278. This portion of the complex algorithm specifier is required.
  279. The remaining scheme and symmetric details will default based on the
  280. type specified and the type of the object being created.
  281. .IP \[bu] 2
  282. aes \- Default AES: aes128
  283. .IP \[bu] 2
  284. aes128\f[C]<mode>\f[] \- 128 bit AES with optional mode
  285. (\f[I]ctr\f[]|\f[I]ofb\f[]|\f[I]cbc\f[]|\f[I]cfb\f[]|\f[I]ecb\f[]).
  286. If mode is not specified, defaults to \f[I]null\f[].
  287. .IP \[bu] 2
  288. aes192\f[C]<mode>\f[] \- Same as aes128\f[C]<mode>\f[], except for a 192
  289. bit key size.
  290. .IP \[bu] 2
  291. aes256\f[C]<mode>\f[] \- Same as aes128\f[C]<mode>\f[], except for a 256
  292. bit key size.
  293. .IP \[bu] 2
  294. ecc \- Elliptical Curve, defaults to ecc256.
  295. .IP \[bu] 2
  296. ecc192 \- 192 bit ECC
  297. .IP \[bu] 2
  298. ecc224 \- 224 bit ECC
  299. .IP \[bu] 2
  300. ecc256 \- 256 bit ECC
  301. .IP \[bu] 2
  302. ecc384 \- 384 bit ECC
  303. .IP \[bu] 2
  304. ecc521 \- 521 bit ECC
  305. .IP \[bu] 2
  306. rsa \- Default RSA: rsa2048
  307. .IP \[bu] 2
  308. rsa1024 \- RSA with 1024 bit keysize.
  309. .IP \[bu] 2
  310. rsa2048 \- RSA with 2048 bit keysize.
  311. .IP \[bu] 2
  312. rsa4096 \- RSA with 4096 bit keysize.
  313. .SS Scheme Specifiers
  314. .PP
  315. Next, is an optional field, it can be skipped.
  316. .PP
  317. Schemes are usually \f[B]Signing Schemes\f[] or \f[B]Asymmetric
  318. Encryption Schemes\f[].
  319. Most signing schemes take a hash algorithm directly following the
  320. signing scheme.
  321. If the hash algorithm is missing, it defaults to \f[I]sha256\f[].
  322. Some take no arguments, and some take multiple arguments.
  323. .SS Hash Optional Scheme Specifiers
  324. .PP
  325. These scheme specifiers are followed by a dash and a valid hash
  326. algorithm, For example: \f[C]oaep\-sha256\f[].
  327. .IP \[bu] 2
  328. oaep
  329. .IP \[bu] 2
  330. ecdh
  331. .IP \[bu] 2
  332. rsassa
  333. .IP \[bu] 2
  334. rsapss
  335. .IP \[bu] 2
  336. ecdsa
  337. .IP \[bu] 2
  338. ecschnorr
  339. .SS Multiple Option Scheme Specifiers
  340. .PP
  341. This scheme specifier is followed by a count (max size UINT16) then
  342. followed by a dash(\-) and a valid hash algorithm.
  343. * ecdaa For example, ecdaa4\-sha256.
  344. If no count is specified, it defaults to 4.
  345. .SS No Option Scheme Specifiers
  346. .PP
  347. This scheme specifier takes NO arguments.
  348. * rsaes
  349. .SS Symmetric Details Specifiers
  350. .PP
  351. This field is optional, and defaults based on the \f[I]type\f[] of
  352. object being created and it\[aq]s attributes.
  353. Generally, any valid \f[B]Symmetric\f[] specifier from the \f[B]Type
  354. Specifiers\f[] list should work.
  355. If not specified, an asymmetric objects symmetric details defaults to
  356. \f[I]aes128cfb\f[].
  357. .SS Examples
  358. .SS Create an rsa2048 key with an rsaes asymmetric encryption scheme
  359. .PP
  360. \f[C]tpm2_create\ \-C\ parent.ctx\ \-G\ rsa2048:rsaes\ \-u\ key.pub\ \-r\ key.priv\f[]
  361. .SS Create an ecc256 key with an ecdaa signing scheme with a count of 4
  362. and sha384 hash
  363. .PP
  364. \f[C]/tpm2_create\ \-C\ parent.ctx\ \-G\ ecc256:ecdaa4\-sha384\ \-u\ key.pub\ \-r\ key.priv\f[]
  365. cryptographic algorithms \f[I]ALGORITHM\f[].
  366. .SH Object Attributes
  367. .PP
  368. Object Attributes are used to control various properties of created
  369. objects.
  370. When specified as an option, either the raw bitfield mask or
  371. "nice\-names" may be used.
  372. The values can be found in Table 31 Part 2 of the TPM2.0 specification,
  373. which can be found here:
  374. .PP
  375. <https://trustedcomputinggroup.org/wp-content/uploads/TPM-Rev-2.0-Part-2-Structures-01.38.pdf>
  376. .PP
  377. Nice names are calculated by taking the name field of table 31 and
  378. removing the prefix \f[B]TPMA_OBJECT_\f[] and lowercasing the result.
  379. Thus, \f[B]TPMA_OBJECT_FIXEDTPM\f[] becomes fixedtpm.
  380. Nice names can be joined using the bitwise or "|" symbol.
  381. .PP
  382. For instance, to set The fields \f[B]TPMA_OBJECT_FIXEDTPM\f[],
  383. \f[B]TPMA_OBJECT_NODA\f[], and \f[B]TPMA_OBJECT_SIGN_ENCRYPT\f[], the
  384. argument would be:
  385. .PP
  386. \f[B]fixedtpm|noda|sign\f[] specifying the object attributes
  387. \f[I]ATTRIBUTES\f[].
  388. .SH PCR Bank Specifiers
  389. .PP
  390. PCR Bank Selection lists follow the below specification:
  391. .IP
  392. .nf
  393. \f[C]
  394. <BANK>:<PCR>[,<PCR>]\ or\ <BANK>:all
  395. \f[]
  396. .fi
  397. .PP
  398. multiple banks may be separated by \[aq]+\[aq].
  399. .PP
  400. For example:
  401. .IP
  402. .nf
  403. \f[C]
  404. sha1:3,4+sha256:all
  405. \f[]
  406. .fi
  407. .PP
  408. will select PCRs 3 and 4 from the SHA1 bank and PCRs 0 to 23 from the
  409. SHA256 bank.
  410. .SS Note
  411. .PP
  412. PCR Selections allow for up to 5 hash to pcr selection mappings.
  413. This is a limitation in design in the single call to the tpm to get the
  414. pcr values.
  415. .SH COMMON OPTIONS
  416. .PP
  417. This collection of options are common to many programs and provide
  418. information that many users may expect.
  419. .IP \[bu] 2
  420. \f[B]\-h\f[], \f[B]\-\-help=[man|no\-man]\f[]: Display the tools
  421. manpage.
  422. By default, it attempts to invoke the manpager for the tool, however, on
  423. failure will output a short tool summary.
  424. This is the same behavior if the "man" option argument is specified,
  425. however if explicit "man" is requested, the tool will provide errors
  426. from man on stderr.
  427. If the "no\-man" option if specified, or the manpager fails, the short
  428. options will be output to stdout.
  429. .RS 2
  430. .PP
  431. To successfully use the manpages feature requires the manpages to be
  432. installed or on \f[I]MANPATH\f[], See man(1) for more details.
  433. .RE
  434. .IP \[bu] 2
  435. \f[B]\-v\f[], \f[B]\-\-version\f[]: Display version information for this
  436. tool, supported tctis and exit.
  437. .IP \[bu] 2
  438. \f[B]\-V\f[], \f[B]\-\-verbose\f[]: Increase the information that the
  439. tool prints to the console during its execution.
  440. When using this option the file and line number are printed.
  441. .IP \[bu] 2
  442. \f[B]\-Q\f[], \f[B]\-\-quiet\f[]: Silence normal tool output to stdout.
  443. .IP \[bu] 2
  444. \f[B]\-Z\f[], \f[B]\-\-enable\-errata\f[]: Enable the application of
  445. errata fixups.
  446. Useful if an errata fixup needs to be applied to commands sent to the
  447. TPM.
  448. Defining the environment TPM2TOOLS_ENABLE_ERRATA is equivalent.
  449. information many users may expect.
  450. .SH TCTI Configuration
  451. .PP
  452. The TCTI or "Transmission Interface" is the communication mechanism with
  453. the TPM.
  454. TCTIs can be changed for communication with TPMs across different
  455. mediums.
  456. .PP
  457. To control the TCTI, the tools respect:
  458. .IP "1." 3
  459. The command line option \f[B]\-T\f[] or \f[B]\-\-tcti\f[]
  460. .IP "2." 3
  461. The environment variable: \f[I]TPM2TOOLS_TCTI\f[].
  462. .PP
  463. \f[B]Note:\f[] The command line option always overrides the environment
  464. variable.
  465. .PP
  466. The current known TCTIs are:
  467. .IP \[bu] 2
  468. tabrmd \- The resource manager, called
  469. tabrmd (https://github.com/tpm2-software/tpm2-abrmd).
  470. Note that tabrmd and abrmd as a tcti name are synonymous.
  471. .IP \[bu] 2
  472. mssim \- Typically used for communicating to the TPM software simulator.
  473. .IP \[bu] 2
  474. device \- Used when talking directly to a TPM device file.
  475. .IP \[bu] 2
  476. none \- Do not initalize a connection with the TPM.
  477. Some tools allow for off\-tpm options and thus support not using a TCTI.
  478. Tools that do not support it will error when attempted to be used
  479. without a TCTI connection.
  480. Does not support \f[I]ANY\f[] options and \f[I]MUST BE\f[] presented as
  481. the exact text of "none".
  482. .PP
  483. The arguments to either the command line option or the environment
  484. variable are in the form:
  485. .PP
  486. \f[C]<tcti\-name>:<tcti\-option\-config>\f[]
  487. .PP
  488. Specifying an empty string for either the \f[C]<tcti\-name>\f[] or
  489. \f[C]<tcti\-option\-config>\f[] results in the default being used for
  490. that portion respectively.
  491. .SS TCTI Defaults
  492. .PP
  493. When a TCTI is not specified, the default TCTI is searched for using
  494. \f[I]dlopen(3)\f[] semantics.
  495. The tools will search for \f[I]tabrmd\f[], \f[I]device\f[] and
  496. \f[I]mssim\f[] TCTIs \f[B]IN THAT ORDER\f[] and \f[B]USE THE FIRST ONE
  497. FOUND\f[].
  498. You can query what TCTI will be chosen as the default by using the
  499. \f[B]\-v\f[] option to print the version information.
  500. The "default\-tcti" key\-value pair will indicate which of the
  501. aforementioned TCTIs is the default.
  502. .SS Custom TCTIs
  503. .PP
  504. Any TCTI that implements the dynamic TCTI interface can be loaded.
  505. The tools internally use \f[I]dlopen(3)\f[], and the raw
  506. \f[I]tcti\-name\f[] value is used for the lookup.
  507. Thus, this could be a path to the shared library, or a library name as
  508. understood by \f[I]dlopen(3)\f[] semantics.
  509. .SH TCTI OPTIONS
  510. .PP
  511. This collection of options are used to configure the various known TCTI
  512. modules available:
  513. .IP \[bu] 2
  514. \f[B]device\f[]: For the device TCTI, the TPM character device file for
  515. use by the device TCTI can be specified.
  516. The default is \f[I]/dev/tpm0\f[].
  517. .RS 2
  518. .PP
  519. Example: \f[B]\-T device:/dev/tpm0\f[] or \f[B]export
  520. \f[I]TPM2TOOLS_TCTI\f[]="device:/dev/tpm0"\f[]
  521. .RE
  522. .IP \[bu] 2
  523. \f[B]mssim\f[]: For the mssim TCTI, the domain name or IP address and
  524. port number used by the simulator can be specified.
  525. The default are 127.0.0.1 and 2321.
  526. .RS 2
  527. .PP
  528. Example: \f[B]\-T mssim:host=localhost,port=2321\f[] or \f[B]export
  529. \f[I]TPM2TOOLS_TCTI\f[]="mssim:host=localhost,port=2321"\f[]
  530. .RE
  531. .IP \[bu] 2
  532. \f[B]abrmd\f[]: For the abrmd TCTI, the configuration string format is a
  533. series of simple key value pairs separated by a \[aq],\[aq] character.
  534. Each key and value string are separated by a \[aq]=\[aq] character.
  535. .RS 2
  536. .IP \[bu] 2
  537. TCTI abrmd supports two keys:
  538. .RS 2
  539. .IP "1." 3
  540. \[aq]bus_name\[aq] : The name of the tabrmd service on the bus (a
  541. string).
  542. .IP "2." 3
  543. \[aq]bus_type\[aq] : The type of the dbus instance (a string) limited to
  544. \[aq]session\[aq] and \[aq]system\[aq].
  545. .RE
  546. .PP
  547. Specify the tabrmd tcti name and a config string of
  548. \f[C]bus_name=com.example.FooBar\f[]:
  549. .PP
  550. \f[C]\\\-\-tcti=tabrmd:bus_name=com.example.FooBar\f[]
  551. .PP
  552. Specify the default (abrmd) tcti and a config string of
  553. \f[C]bus_type=session\f[]:
  554. .PP
  555. \f[C]\\\-\-tcti:bus_type=session\f[]
  556. .PP
  557. \f[B]NOTE\f[]: abrmd and tabrmd are synonymous.
  558. the various known TCTI modules.
  559. .RE
  560. .SH EXAMPLES
  561. .SS To allocate the two default banks (SHA1 and SHA256)
  562. .IP
  563. .nf
  564. \f[C]
  565. tpm2_pcrallocate
  566. \f[]
  567. .fi
  568. .SS To make a custom allocation with a platform authorization
  569. .IP
  570. .nf
  571. \f[C]
  572. tpm2_pcrallocate\ \-P\ abc\ sha1:7,8,9,10,16,17,18,19+sha256:all
  573. \f[]
  574. .fi
  575. .SS To completly switch from SHA1 bank to SHA256 with a platform
  576. authorization
  577. .IP
  578. .nf
  579. \f[C]
  580. tpm2_pcrallocate\ \-P\ abc\ sha1:none+sha256:all
  581. \f[]
  582. .fi
  583. .SH Returns
  584. .PP
  585. Tools can return any of the following codes:
  586. .IP \[bu] 2
  587. 0 \- Success.
  588. .IP \[bu] 2
  589. 1 \- General non\-specific error.
  590. .IP \[bu] 2
  591. 2 \- Options handling error.
  592. .IP \[bu] 2
  593. 3 \- Authentication error.
  594. .IP \[bu] 2
  595. 4 \- TCTI related error.
  596. .IP \[bu] 2
  597. 5 \- Non supported scheme.
  598. Applicable to tpm2_testparams.
  599. .SH BUGS
  600. .PP
  601. Github Issues (https://github.com/tpm2-software/tpm2-tools/issues)
  602. .SH HELP
  603. .PP
  604. See the Mailing List (https://lists.01.org/mailman/listinfo/tpm2)