Azure data source cannot generate public ssh key

Bug #1603830 reported by Ian Duffy
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-init
Fix Released
Medium
Unassigned

Bug Description

Given the following code on a EL based distribution:

```
def crtfile_to_pubkey(fname):
    pipeline = ('openssl x509 -noout -pubkey < "$0" |'
                'ssh-keygen -i -m PKCS8 -f /dev/stdin')
    (out, _err) = util.subp(['sh', '-c', pipeline, fname], capture=True)
    return out.rstrip()
```

Cloud-init is unable to generate a ssh public-key from the azure PKCS8 certificate.
The version of ssh-keygen on EL distributions does not have a -m flag.

Changed in cloud-init:
milestone: none → 0.7.7
status: New → Confirmed
Scott Moser (smoser)
Changed in cloud-init:
importance: Undecided → Medium
Scott Moser (smoser)
Changed in cloud-init:
milestone: 0.7.7 → 0.7.8
Scott Moser (smoser)
Changed in cloud-init:
milestone: 0.7.8 → 0.7.9
Scott Moser (smoser)
Changed in cloud-init:
milestone: 0.7.9 → none
milestone: none → 0.7.10
Revision history for this message
Brett Holman (holmanb) wrote :

Modern supported "EL" derivatives appear to have this flag (tested on centos8-stream and centos9-stream).

If this is believed to still be an issue, please reopen.

Changed in cloud-init:
status: Confirmed → Fix Released
Revision history for this message
James Falcon (falcojr) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.