Bug 1851294 (CVE-2020-12401)

Summary: CVE-2020-12401 nss: ECDSA timing attack mitigation bypass
Product: [Other] Security Response Reporter: Huzaifa S. Sidhpurwala <huzaifas>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: crypto-team, dueno, elio.maldonado.batiz, kdudka, kengert, nss-nspr-maint, rrelyea, security-response-team, vlatombe
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: nss 3.55 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in nss. Using the EM side-channel, it is possible to extract the position of zero and non-zero wNAF digits while nss-certutil tool performs scalar multiplication during the ECDSA signature generation, leaking partial information about the ECDSA nonce. Given a small number of ECDSA signatures, this information can be used to steal the private key. The highest threat from this vulnerability is to data confidentiality.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-09-30 03:57:14 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1862389, 1862390, 1862391, 1862393, 1905152    
Bug Blocks: 1826178    

Description Huzaifa S. Sidhpurwala 2020-06-26 04:17:32 UTC
A timing attacker against ECDSA signature generation is able to obtain information from the secret nonce measuring the time an ECDSA signature generation takes. Current NSS code path has a countermeasure to prevent this know attack since 2011. However it was found that said countermeasure could be completely bypassed. Different flaw from CVE-2020-6829.

Comment 1 Huzaifa S. Sidhpurwala 2020-06-26 04:17:36 UTC
Acknowledgments:

Name: the Mozilla Project
Upstream: Cesar Pereida Garcia and the Network and Information Security Group (NISEC)

Comment 3 Huzaifa S. Sidhpurwala 2020-07-31 08:11:03 UTC
External References:

https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_3.55_release_notes

Comment 4 Huzaifa S. Sidhpurwala 2020-07-31 10:08:33 UTC
Statement:

This is a side channel attack which can used to exact pirate keys when ECDSA signatures are being generated. This attack is only feasible when the attacker is local to the machine or in certain cross-VM scenarios where the signature is being generated. Attacks over the network or via the internet are not feasible.

Comment 5 Huzaifa S. Sidhpurwala 2020-07-31 10:08:38 UTC
Mitigation:

This is a side channel attack which can used to exact pirate keys when ECDSA signatures are being generated. This attack is only feasible when the attacker is local to the machine or in certain cross-VM scenarios where the signature is being generated. Attacks over the network or via the internet are not feasible.

Comment 7 Huzaifa S. Sidhpurwala 2020-07-31 10:26:31 UTC
Created nss tracking bugs for this issue:

Affects: fedora-all [bug 1862393]

Comment 10 errata-xmlrpc 2020-09-29 20:58:38 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2020:4076 https://access.redhat.com/errata/RHSA-2020:4076

Comment 11 Product Security DevOps Team 2020-09-30 03:57:14 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2020-12401

Comment 12 Vincent Latombe 2022-06-07 14:28:21 UTC
How come this has been addressed for RHEL 7 but not RHEL 8 ? The CVE page still indicates RHEL 8 is 'affected.

Comment 13 Mauro Matteo Cascella 2022-08-26 09:29:59 UTC
The CVE page is now updated, showing that nss in RHEL-8 was fixed via RHSA-2021:0538.