tss2_exportkey(1)
π tss2_exportkey(1) β like, the whole manual, bestie
okay so this is tss2_exportkey(1), straight out of the General Commands Manual section, and I'm gonna walk you through it like we're texting at 2am π«Ά
β¨ NAME β¨
tss2_exportkey(1) β that's it, that's the name. The OG page literally just leaves the description blank, iconic behavior honestly π
β¨ SYNOPSIS β¨
tss2_exportkey [OPTIONS]
that's the whole vibe. just the command and then whatever options you feel like sprinkling on top πΈ
π¦ SEE ALSO π¦
fapi-config(5)β go here to adjust Fapi parameters, like which cryptographic profile is being used, the TCTI, or the directories for the Fapi metadata storages. very "settings app" of it πfapi-profile(5)β go here to figure out the cryptographic algorithms and parameters for all keys and operations of a specific TPM interaction. that means the name hash algorithm, the asymmetric signature algorithm, scheme and parameters, and the PCR bank selection. yeah it's a lot, it's giving "options menu" β¨
π DESCRIPTION π
so tss2_exportkey(1) β the main character β duplicates a key and encrypts it using the public key of a new parent. yes bestie, it re-wraps the key π₯
the exported data contains the re-wrapped key that pathOfKeyToDuplicate points to, and then the JSON encoded policy after it. the encryption is done according to the TPM encryption schemes specified in the cryptographic profile (cf., fapi-profile(5)). so like, it's not freestyling the crypto β it's following the profile's rules π
π OPTIONS π
these are the available options, and yes we're doing all of them:
-e,--pathToPublicKeyOfNewParent=STRINGβ the path to the public key of the new parent πΌ this key MAY be in the public key hierarchy/ext. it's an optional parameter. if you omit it, only the public key gets exported. no cap.-f,--forceβ force overwriting the output file. respectfully, it will absolutely clobber what's there π-o,--exportedData=FILENAMEor-(for stdout) β returns the exported subtree. and yes,-means it goes straight to stdout, cute π-p,--pathOfKeyToDuplicate=STRINGβ the path to the root of the subtree to export π³
β COMMON OPTIONS β
this collection of options are common to all tss2 programs, and they provide information that many users may expect. like, the standard-issue stuff every tss2 tool comes with π
-h,--help [man|no-man]β display the tool's manpage. by default it attempts to invoke the manpager for the tool, but on failure it'll output a short tool summary instead. that's the same behavior you get if you pass themanoption argument β however, if explicitmanis requested, the tool will provide errors frommanon stderr. and if theno-manoption is specified, or the manpager fails, the short options get output to stdout. to successfully use the manpages feature you need the manpages installed or onMANPATH, seeman(1)for more details π-v,--versionβ display version information for this tool, the supported tctis, and exit. quick little vibe check then she's out π¦
π EXAMPLE π
tss2_exportkey --pathOfKeyToDuplicate=HS/SRK/myRSADecrypt --exportedData=exportedData.file
look at her go, ate and left no crumbs π
π§ RETURNS π§
0 on success or 1 on failure. binary queen, no in-between π
π BUGS π
Github Issues. that's literally the whole section. go file one if something's cursed π
π«Ά HELP π«Ά
See the Mailing List. the elders are there, they know things π
πΈ License πΈ
this work is licensed under the Creative Commons Attribution 4.0 International License (CC BY 4.0) β share responsibly bestie β¨
so that's the whole thing!! courtesy of tpm2-tools, dated APRIL 2019, and yeah the page footer still says tss2_exportkey(1) because she's consistent like that π ily, go export some keys π
π¦ where this page comes from
- arch rolling: tpm2-tools 5.8-1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms