1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-03 22:56:33 +02:00
gnupg/agent
James Bottomley 1a4a4a8f5f
agent: plumb in TPM handling
* agent/divert-tpm2.c: New.
* Makefile.am (gpg_agent_SOURCES): Add it.
* agent/command.c (do_one_keyinfo): Fake serialno for TPM.
(cmd_keytotpm): New.
(register_commands): Register KEYTOTPM command.
* agent/pkdecrypt.c (agent_pkdecrypt): Divert to TPM.
* agent/pksign.c (agent_pksign_do): Divert to TPM.

--
This code installs diversions for pksign and pkdecrypt to do the
operations via the TPM if a TPM shadowed key is present.  It also adds
an extra assuan command KEYTOTPM which moves an existing private key
to a TPM shadowed key.

The way TPM shadowing works is that the public and private key parts
are fed in to the TPM command TPM2_Import.  The output of this command
is a TPM specific public and private key data where the private key
data is symmetrically encrypted using a TPM internal key.  If this
physical TPM is ever lost or cleared, that TPM internal key will
likewise be lost and nothing will ever be able to read the private
key.  Once the import is done, the shadow information for the key is
updated to be a three part list consisting of the parent key (hard
coded to 81000001 which is the Microsoft preferred RSA incarnation of
the storage seed) and the public and private TPM data blobs.

Now when a TPM shadowed key is used, the data blobs must be loaded
into the TPM with TPM2_Load before any operation can be performed.

Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>

- Added ChangeLog entries

Signed-off-by: Werner Koch <wk@gnupg.org>
2018-03-09 10:01:59 +01:00
..
agent.h agent: plumb in TPM handling 2018-03-09 10:01:59 +01:00
all-tests.scm tests: Make it possible to run all tests using our infrastructure. 2017-05-11 18:12:37 +02:00
cache.c agent: Also evict cached items via a timer. 2018-03-06 16:22:42 +01:00
call-pinentry.c agent: Clean up pinentry access locking. 2017-10-27 14:15:58 +02:00
call-scd.c agent: Fix cancellation handling for scdaemon. 2017-09-20 10:42:28 +09:00
ChangeLog-2011 Fix typos 2015-10-28 10:20:17 +01:00
command-ssh.c agent: Fix sending connecting process uid to pinentry. 2018-01-26 10:52:56 +09:00
command.c agent: plumb in TPM handling 2018-03-09 10:01:59 +01:00
cvt-openpgp.c Use the gpgrt log functions if possible. 2017-11-27 15:00:25 +01:00
cvt-openpgp.h Change all http://www.gnu.org in license notices to https:// 2016-11-05 12:02:19 +01:00
divert-scd.c Use the gpgrt log functions if possible. 2017-11-27 15:00:25 +01:00
divert-tpm2.c agent: plumb in TPM handling 2018-03-09 10:01:59 +01:00
findkey.c agent: expose shadow key type 2018-03-09 08:31:17 +01:00
genkey.c agent: Use MAX_PASSPHRASE_LEN (255) also for the loopback. 2017-07-05 11:54:45 +02:00
gpg-agent-w32info.rc w32: Add icons and version information. 2013-05-07 21:35:48 +02:00
gpg-agent.c agent: Also evict cached items via a timer. 2018-03-06 16:22:42 +01:00
keyformat.txt doc: Fix Dijkstra 2017-12-08 07:40:06 +01:00
learncard.c agent: Fix returning GPG_ERR_NOT_FOUND wrongly. 2017-11-02 17:04:03 +01:00
Makefile.am agent: plumb in TPM handling 2018-03-09 10:01:59 +01:00
pkdecrypt.c agent: plumb in TPM handling 2018-03-09 10:01:59 +01:00
pksign.c agent: plumb in TPM handling 2018-03-09 10:01:59 +01:00
preset-passphrase.c Fix usage of ARGPARSE_OPTS. 2017-07-19 13:41:18 +09:00
protect-tool.c agent: Resolve conflict of util.h. 2017-03-07 19:22:48 +09:00
protect.c agent: expose shadow key type 2018-03-09 08:31:17 +01:00
t-protect.c agent: Fix description of shadow format. 2017-12-08 09:19:50 +09:00
tpm2.c agent: add tpm specific functions 2018-03-09 09:02:01 +01:00
tpm2.h agent: add tpm specific functions 2018-03-09 09:02:01 +01:00
trans.c Change all http://www.gnu.org in license notices to https:// 2016-11-05 12:02:19 +01:00
trustlist.c Spelling fixes in docs and comments. 2017-04-28 10:06:33 +09:00
w32main.c agent: Resolve conflict of util.h. 2017-03-07 19:22:48 +09:00
w32main.h Change all http://www.gnu.org in license notices to https:// 2016-11-05 12:02:19 +01:00