Skip to content

crypto, keys: add ECDSA signature support to key retention service

Ignat Korchagin keyrings linux-crypto 3 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest posting 2/24 patches 0 repliesNew
  2. v2 posting 1/24 patches 0 repliesSuperseded
  3. v14 patches 3 repliesSuperseded

Changes in v2 from the cover letter

* fixed code format

Patches in v2 posting 2/2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4crypto: add ECDSA signature generation supportcrypto/Kconfig crypto/Makefile crypto/ecc.c +3 more+398 -170 replies
2/4crypto: add ECDSA test vectors from RFC 6979crypto/testmgr.c crypto/testmgr.h+351 -00 replies
3/4crypto: pkcs8 parser support ECDSA private keyscrypto/asymmetric_keys/pkcs8.asn1 crypto/asymmetric_keys/pkcs8_parser.c+43 -40 replies
4/4crypto: remove unused field in pkcs8_parse_contextcrypto/asymmetric_keys/pkcs8_parser.c+0 -10 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [RESEND PATCH v2 0/4] crypto, keys: add ECDSA signature support to key retention service

Changes from v1:
* fixed code format

Kernel Key Retention Service[1] is a useful building block to build secure production key management systems. One of its interesting features is support for asymmetric keys: we can allow a process to use a certain key (decrypt or sign data) without actually allowing the process to read the cryptographic key material. By doing so we protect our code from certain type of attacks, where a process memory memory leak actually leaks a potentially highly sensitive cryptographic material.

But unfortunately only RSA algorithm was supported until now, because in-kernel ECDSA implementation supported signature verifications only.

This patchset implements in-kernel ECDSA signature generation and adds support for ECDSA signing in the key retention service. The key retention service support was taken out of a previous unmerged patchset from Lei He[2]

[1]: https://www.kernel.org/doc/html/latest/security/keys/core.html
[2]: https://patchwork.kernel.org/project/linux-crypto/list/?series=653034&state=*

Original posting: https://patchwork.kernel.org/project/keyrings/cover/[email protected]/

Ignat Korchagin (2):
crypto: add ECDSA signature generation support
crypto: add ECDSA test vectors from RFC 6979

lei he (2):
crypto: pkcs8 parser support ECDSA private keys
crypto: remove unused field in pkcs8_parse_context

 crypto/Kconfig                        |   3 +-
 crypto/Makefile                       |   4 +-
 crypto/asymmetric_keys/pkcs8.asn1     |   2 +-
 crypto/asymmetric_keys/pkcs8_parser.c |  46 +++-
 crypto/ecc.c                          |  19 +-
 crypto/ecdsa.c                        | 373 +++++++++++++++++++++++++-
 crypto/ecprivkey.asn1                 |   6 +
 crypto/testmgr.c                      |  18 ++
 crypto/testmgr.h                      | 333 +++++++++++++++++++++++
 include/crypto/internal/ecc.h         |  10 +
 10 files changed, 792 insertions(+), 22 deletions(-)
 create mode 100644 crypto/ecprivkey.asn1
Signature · 1 line
2.30.2