INNER CODE UNIT · Python
AddKeyCommand
tpm2-software/tpm2-pkcs11 · tools/tpm2_pkcs11/commandlets_keys.py:273
class AddKeyCommand(NewKeyCommandBase):
'''
Adds a key to a token within a tpm2-pkcs11 store.
'''
# adhere to an interface
# pylint: disable=no-self-use
def generate_options(self, group_parser):
super(AddKeyCommand, self).generate_options(group_parser)
group_parser.add_argument(
'--algorithm',
help='The type of the key.\n',
choices=Tpm2.ALGS,
required=True)
# Creates a new key
def new_key_create(self, pobj, objauth, hierarchyauth, tpm2, alg, privkey, passin, d):