Bug 1798728 (CVE-2020-8632)

Summary: CVE-2020-8632 cloud-init: Too short random password length in cc_set_password in config/cc_set_passwords.py
Product: [Other] Security Response Reporter: Pedro Sampaio <psampaio>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: adimania, apevec, dustymabe, eterrell, gholms, jgreguske, mhayden, rmccabe, rschiron, shardy, sisharma, s, virt-maint
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: cloud-init 20.1 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in cloud-init, where it uses short passwords when generating a random password in new instances. Depending on the instance configuration, a remote or local attacker may abuse this vulnerability to guess the password of the victim user.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-09-29 21:59:39 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: 1798729, 1798730, 1812170, 1812171    
Bug Blocks: 1798734    

Description Pedro Sampaio 2020-02-05 21:12:40 UTC
In cloud-init through 19.4, rand_user_password in cloudinit/config/cc_set_passwords.py has a small default pwlen value, which makes it easier for attackers to guess passwords.

Upstream patch:

https://github.com/canonical/cloud-init/pull/189
https://github.com/canonical/cloud-init/commit/42788bf24a1a0a5421a2d00a7f59b59e38ba1a14

References:

https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1860795

Comment 1 Pedro Sampaio 2020-02-05 21:13:18 UTC
Created cloud-init tracking bugs for this issue:

Affects: epel-6 [bug 1798730]
Affects: fedora-all [bug 1798729]

Comment 2 Riccardo Schirone 2020-03-10 16:56:27 UTC
As cc_set_passwords module could be used to set ssh password authentication as well, the Attack Vector is set to Network.
Confidentiality, Integrity and Availability set to High because the direct impact of the flaw is the control of the user in the instance configured by cloud-init.

Comment 4 errata-xmlrpc 2020-09-29 19:40:50 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

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

Comment 5 Product Security DevOps Team 2020-09-29 21:59:39 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-8632

Comment 6 errata-xmlrpc 2020-11-04 02:40:37 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

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