lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <794ef635-de91-9207-f28b-ab6805fd95c9@linux.ibm.com>
Date:   Tue, 20 Apr 2021 17:02:44 -0400
From:   Stefan Berger <stefanb@...ux.ibm.com>
To:     Jessica Yu <jeyu@...nel.org>
Cc:     keyrings@...r.kernel.org, dhowells@...hat.com, zohar@...ux.ibm.com,
        jarkko@...nel.org, nayna@...ux.ibm.com,
        linux-integrity@...r.kernel.org,
        linux-security-module@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 2/2] certs: Add support for using elliptic curve keys
 for signing modules


On 4/20/21 10:03 AM, Jessica Yu wrote:
> +++ Stefan Berger [08/04/21 11:24 -0400]:
>>
>> diff --git a/crypto/asymmetric_keys/pkcs7_parser.c 
>> b/crypto/asymmetric_keys/pkcs7_parser.c
>> index 967329e0a07b..2546ec6a0505 100644
>> --- a/crypto/asymmetric_keys/pkcs7_parser.c
>> +++ b/crypto/asymmetric_keys/pkcs7_parser.c
>> @@ -269,6 +269,10 @@ int pkcs7_sig_note_pkey_algo(void *context, 
>> size_t hdrlen,
>>         ctx->sinfo->sig->pkey_algo = "rsa";
>>         ctx->sinfo->sig->encoding = "pkcs1";
>>         break;
>> +    case OID_id_ecdsa_with_sha256:
>> +        ctx->sinfo->sig->pkey_algo = "ecdsa";
>> +        ctx->sinfo->sig->encoding = "x962";
>> +        break;
>
> Hi Stefan,
>
> Does CONFIG_MODULE_SIG_KEY_TYPE_ECDSA have a dependency on 
> MODULE_SIG_SHA256?

You are right, per the code above it does have a dependency on SHA256. 
ECDSA is using NIST p384 (secp384r1) for signing and per my tests it can 
be paired with all the sha hashes once the code above is extended. Now 
when it comes to module signing, should we pair it with a particular 
hash? I am not currently aware of a guidance document on this but sha256 
and sha384 seem to be good choices these days, so maybe selecting ECDSA 
module signing should have a 'depends on' on these?

   Stefan


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ