Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1310923 > unrolled thread
| Started by | David Howells <dhowells@redhat.com> |
|---|---|
| First post | 2016-01-16 12:00 +0100 |
| Last post | 2016-01-16 12:00 +0100 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH v2] crypto: AF_ALG - add support for keys/asymmetric-type David Howells <dhowells@redhat.com> - 2016-01-16 12:00 +0100
| From | David Howells <dhowells@redhat.com> |
|---|---|
| Date | 2016-01-16 12:00 +0100 |
| Subject | Re: [PATCH v2] crypto: AF_ALG - add support for keys/asymmetric-type |
| Message-ID | <qRwKl-3em-1@gated-at.bofh.it> |
Tadeusz Struk <tadeusz.struk@intel.com> wrote: > I think the coupling of an algorithm to its key is the problem here. > Usually an algorithm should be able to work with any (valid) key. A key stored in hardware and used through that hardware won't necessarily support all crypto operations - it may be restricted to just signing or just encrypting for example. > The solution to this can be implemented on the crypto API. > If the TMP driver would register its supported algorithms on the crypto API > and in the setkey function it would check if a key is a real key or this > "something" (probably a ptr to TMP dev instance?) then in the first > case it would fallback to an implementation that takes a key data. > In the second case it can do its thing whatever it is. From what Herbert has said, he won't go for that since the TPM keys are restricted in the operations one can use the key for. I think the crypto API is what we use when the key data is available to us in the kernel - but it should be driven through the asymmetric key API. You ask the asymmetric key API to verify a key, say, then that will switch to the TPM driver or to the software public key implementation. The latter will then load the appropriate crypto layer akcipher algorithm (eg. RSA) and use that - where the akcipher implementation will either be a software one or will get offloaded to some hardware that can do it - but that doesn't itself securely hold the key. David
Back to top | Article view | linux.kernel
csiph-web