Allow SSH keys without a comment

Bug #1974474 reported by Larry Rosenman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
Low
Guruprasad

Bug Description

I tried to use both of the following public keys, and neither works.

ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQC83Cm0VEYdcy+bbLNvGGr7fW9lPGgB+wTaHawc0NK7CXmtdfLITLKRrkmwhgJURn1Fjv+cO/Zvjd9f4/LgamdGRNscfhdhp5zvFSgh7MTWcXAQhT2mBO32P7TG4IPGWitV3FkZ9P2oEqNn5ImV1PQpATPyDabNFg+zxMjnBFhRJodJpdY6qDqCT2TMhdO+ylhw2r3zxpb88yiukXxRivVxBR+NcUndyPmMzeE+ShUUFRR2P1E4aDt56MF8bYkcZCVMRaamD2W1pDiNB+cXY+XUvdZHqVzT8Zhg6jjp1816eXoDONNd0F178pkPwIrl3Lq+/XbDMtRHw6PLJFWiEWa/utyiAuYwVfDTul70MnXgbjEXdgnBsYPr9mkpJV7b24VNV/7ihk/3NMyf1z35ESRoxwrh2NGY94PJS1LwjKwTpP9b31uLarUgV0CgyVQ4dk/bE5WFRTP0PGl/aRWF0YG3OcS96pbRHMzWXlxUuRVr3kRyuJZMjg4ihmIcKeoDItIJ/hPYs1QJz/F+VvVVmGR249ZRf213mBlFdrs+zVzA9/4Q7LBiZAGSpb9otYlSJk0EAu9NRaC83BmoMuPR6EolVSP8Fy7op+gsYMBt64aRlhTi3/tuLGryV6Y4N5YgTeHoeTPa1/ClZwdR+xA/Eq7ePzJ892zW5cUNVoxX+9/YYQ==

ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHUGq9ycA/ImyXBjpx0gSUUifS9JT872oKMKiJ0cd4/t

You say ed25519 is usable, but the text says ssh-rsa.

the rsa key above is 4096 bits.

Related branches

Revision history for this message
Daniel Manrique (roadmr) wrote :

Hello,

Thank you for writing to us regarding this problem. We'd be grateful if you would provide a more complete description of the problem.

At a minimum, we need:
1. The specific steps or actions you took that caused you to encounter the problem.
2. The behavior you expected.
3. The behavior you actually encountered (in as much detail as possible, including exact error messages).

You can provide screenshots of the pages where you are observing problems or getting an error message that is confusing.

affects: canonical-identity-provider → launchpad
Revision history for this message
Larry Rosenman (lrosenman) wrote :
Revision history for this message
Larry Rosenman (lrosenman) wrote :
Revision history for this message
Larry Rosenman (lrosenman) wrote :

3 Screen shots attached.

Revision history for this message
Guruprasad (lgp171188) wrote :

Hi,

This appears to be a limitation of the SSH keys upload functionality on login.ubuntu.com. Can you try uploading your SSH keys directly to Launchpad at https://launchpad.net/~lrosenman/+editsshkeys and let us know if that worked?

Guruprasad (lgp171188)
Changed in launchpad:
status: New → Incomplete
Revision history for this message
Larry Rosenman (lrosenman) wrote : Re: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

Nope. Rejects both from that page as well. with "invalid key"

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: <email address hidden> <email address hidden> on behalf of Guruprasad <email address hidden>
Sent: Monday, May 23, 2022 1:19 AM
To: Larry Rosenman <email address hidden>
Subject: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

Hi,

This appears to be a limitation of the SSH keys upload functionality on
login.ubuntu.com<http://login.ubuntu.com>. Can you try uploading your SSH keys directly to
Launchpad at https://launchpad.net/~lrosenman/+editsshkeys<https://launchpad.net/~lrosenman/+editsshkeys> and let us
know if that worked?

--
You received this bug notification because you are subscribed to the bug
report.
https://bugs.launchpad.net/bugs/1974474<https://bugs.launchpad.net/bugs/1974474>

Title:
NONE of my ssh keys work on the ssh keys page

Status in Launchpad itself:
New

Bug description:
I tried to use both of the following public keys, and neither works.

ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAACAQC83Cm0VEYdcy+bbLNvGGr7fW9lPGgB+wTaHawc0NK7CXmtdfLITLKRrkmwhgJURn1Fjv+cO/Zvjd9f4/LgamdGRNscfhdhp5zvFSgh7MTWcXAQhT2mBO32P7TG4IPGWitV3FkZ9P2oEqNn5ImV1PQpATPyDabNFg+zxMjnBFhRJodJpdY6qDqCT2TMhdO+ylhw2r3zxpb88yiukXxRivVxBR+NcUndyPmMzeE+ShUUFRR2P1E4aDt56MF8bYkcZCVMRaamD2W1pDiNB+cXY+XUvdZHqVzT8Zhg6jjp1816eXoDONNd0F178pkPwIrl3Lq+/XbDMtRHw6PLJFWiEWa/utyiAuYwVfDTul70MnXgbjEXdgnBsYPr9mkpJV7b24VNV/7ihk/3NMyf1z35ESRoxwrh2NGY94PJS1LwjKwTpP9b31uLarUgV0CgyVQ4dk/bE5WFRTP0PGl/aRWF0YG3OcS96pbRHMzWXlxUuRVr3kRyuJZMjg4ihmIcKeoDItIJ/hPYs1QJz/F+VvVVmGR249ZRf213mBlFdrs+zVzA9/4Q7LBiZAGSpb9otYlSJk0EAu9NRaC83BmoMuPR6EolVSP8Fy7op+gsYMBt64aRlhTi3/tuLGryV6Y4N5YgTeHoeTPa1/ClZwdR+xA/Eq7ePzJ892zW5cUNVoxX+9/YYQ==

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIHUGq9ycA/ImyXBjpx0gSUUifS9JT872oKMKiJ0cd4/t

You say ed25519 is usable, but the text says ssh-rsa.

the rsa key above is 4096 bits.

To manage notifications about this bug go to:
https://bugs.launchpad.net/launchpad/+bug/1974474/+subscriptions<https://bugs.launchpad.net/launchpad/+bug/1974474/+subscriptions>

Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.

This email has been scanned for viruses and malware, and may have been automatically archived by Mimecast, a leader in email security and cyber resilience. Mimecast integrates email defenses with brand protection, security awareness training, web security, compliance and other essential capabilities. Mimecast helps protect large and small organizations from malicious activity, human error and technology failure; and to lead the movement toward building a more resilient world. To find out more, visit our website.

Revision history for this message
Colin Watson (cjwatson) wrote : Re: NONE of my ssh keys work on the ssh keys page

I spotted the problem. Launchpad currently requires that SSH keys have a comment. To illustrate, one of my own keys is the following:

  ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/ cjwatson@niejwein

You entered the equivalent of this instead, dropping the comment at the end:

  ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/

Now, it's true that the comment isn't required by OpenSSH, so Launchpad is arguably in the wrong here. (The restriction goes all the way back to when SSH key support was first added to Launchpad in 2004.) You can very easily work around it by adding a comment to the end of your public key, though; `ssh-keygen` defaults to `user@host` for whatever user and host generated the key, as you can see in my example.

Revision history for this message
Larry Rosenman (lrosenman) wrote : Re: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page
Download full text (4.1 KiB)

I'm using 1Password's SSH key storage, and when they paste the key, that's what they put out.
Can you look into loosening that requirement?

https://developer.1password.com/docs/ssh
[https://developer.1password.com/img/meta-og-image.png]<https://developer.1password.com/docs/ssh>
1Password for SSH & Git | 1Password Developer Documentation<https://developer.1password.com/docs/ssh>
Quick start Get started . If you're setting up SSH in 1Password for the first time, start here. Guides Manage SSH keys . Learn how to generate and import SSH keys, and how to copy or download your public key if you need to share it.
developer.1password.com

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: <email address hidden> <email address hidden> on behalf of Colin Watson <email address hidden>
Sent: Monday, May 23, 2022 6:02 PM
To: Larry Rosenman <email address hidden>
Subject: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

I spotted the problem. Launchpad currently requires that SSH keys have
a comment. To illustrate, one of my own keys is the following:

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/
cjwatson@niejwein

You entered the equivalent of this instead, dropping the comment at the
end:

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/

Now, it's true that the comment isn't required by OpenSSH, so Launchpad
is arguably in the wrong here. (The restriction goes all the way back
to when SSH key support was first added to Launchpad in 2004.) You can
very easily work around it by adding a comment to the end of your public
key, though; `ssh-keygen` defaults to `user@host` for whatever user and
host generated the key, as you can see in my example.

--
You received this bug notification because you are subscribed to the bug
report.
https://bugs.launchpad.net/bugs/1974474<https://bugs.launchpad.net/bugs/1974474>

Title:
NONE of my ssh keys work on the ssh keys page

Status in Launchpad itself:
Incomplete

Bug description:
I tried to use both of the following public keys, and neither works.

ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAACAQC83Cm0VEYdcy+bbLNvGGr7fW9lPGgB+wTaHawc0NK7CXmtdfLITLKRrkmwhgJURn1Fjv+cO/Zvjd9f4/LgamdGRNscfhdhp5zvFSgh7MTWcXAQhT2mBO32P7TG4IPGWitV3FkZ9P2oEqNn5ImV1PQpATPyDabNFg+zxMjnBFhRJodJpdY6qDqCT2TMhdO+ylhw2r3zxpb88yiukXxRivVxBR+NcUndyPmMzeE+ShUUFRR2P1E4aDt56MF8bYkcZCVMRaamD2W1pDiNB+cXY+XUvdZHqVzT8Zhg6jjp1816eXoDONNd0F178pkPwIrl3Lq+/XbDMtRHw6PLJFWiEWa/utyiAuYwVfDTul70MnXgbjEXdgnBsYPr9mkpJV7b24VNV/7ihk/3NMyf1z35ESRoxwrh2NGY94PJS1LwjKwTpP9b31uLarUgV0CgyVQ4dk/bE5WFRTP0PGl/aRWF0YG3OcS96pbRHMzWXlxUuRVr3kRyuJZMjg4ihmIcKeoDItIJ/hPYs1QJz/F+VvVVmGR249ZRf213mBlFdrs+zVzA9/4Q7LBiZAGSpb9otYlSJk0EAu9NRaC83BmoMuPR6EolVSP8Fy7op+gsYMBt64aRlhTi3/tuLGryV6Y4N5YgTeHoeTPa1/ClZwdR+xA/Eq7ePzJ892zW5cUNVoxX+9/YYQ==

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIHUGq9ycA/ImyXBjpx0gSUUifS9JT872oKMKiJ0cd4/t

You say ed25519 is usable, but the text says ssh-rsa.

the rsa key above is 4096 bits.

To manage notifications about this bug go to:
https://bugs.launchpad.net/launchpad/+bug/197...

Read more...

Revision history for this message
Larry Rosenman (lrosenman) wrote :
Download full text (4.5 KiB)

Also, it would be nice(tm) if the error message was better as well.

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: Larry Rosenman <email address hidden>
Sent: Monday, May 23, 2022 6:17 PM
To: Bug 1974474 <email address hidden>
Subject: Re: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

I'm using 1Password's SSH key storage, and when they paste the key, that's what they put out.
Can you look into loosening that requirement?

https://developer.1password.com/docs/ssh
[https://developer.1password.com/img/meta-og-image.png]<https://developer.1password.com/docs/ssh>
1Password for SSH & Git | 1Password Developer Documentation<https://developer.1password.com/docs/ssh>
Quick start Get started . If you're setting up SSH in 1Password for the first time, start here. Guides Manage SSH keys . Learn how to generate and import SSH keys, and how to copy or download your public key if you need to share it.
developer.1password.com

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: <email address hidden> <email address hidden> on behalf of Colin Watson <email address hidden>
Sent: Monday, May 23, 2022 6:02 PM
To: Larry Rosenman <email address hidden>
Subject: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

I spotted the problem. Launchpad currently requires that SSH keys have
a comment. To illustrate, one of my own keys is the following:

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/
cjwatson@niejwein

You entered the equivalent of this instead, dropping the comment at the
end:

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/

Now, it's true that the comment isn't required by OpenSSH, so Launchpad
is arguably in the wrong here. (The restriction goes all the way back
to when SSH key support was first added to Launchpad in 2004.) You can
very easily work around it by adding a comment to the end of your public
key, though; `ssh-keygen` defaults to `user@host` for whatever user and
host generated the key, as you can see in my example.

--
You received this bug notification because you are subscribed to the bug
report.
https://bugs.launchpad.net/bugs/1974474<https://bugs.launchpad.net/bugs/1974474>

Title:
NONE of my ssh keys work on the ssh keys page

Status in Launchpad itself:
Incomplete

Bug description:
I tried to use both of the following public keys, and neither works.

ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAACAQC83Cm0VEYdcy+bbLNvGGr7fW9lPGgB+wTaHawc0NK7CXmtdfLITLKRrkmwhgJURn1Fjv+cO/Zvjd9f4/LgamdGRNscfhdhp5zvFSgh7MTWcXAQhT2mBO32P7TG4IPGWitV3FkZ9P2oEqNn5ImV1PQpATPyDabNFg+zxMjnBFhRJodJpdY6qDqCT2TMhdO+ylhw2r3zxpb88yiukXxRivVxBR+NcUndyPmMzeE+ShUUFRR2P1E4aDt56MF8bYkcZCVMRaamD2W1pDiNB+cXY+XUvdZHqVzT8Zhg6jjp1816eXoDONNd0F178pkPwIrl3Lq+/XbDMtRHw6PLJFWiEWa/utyiAuYwVfDTul70MnXgbjEXdgnBsYPr9mkpJV7b24VNV/7ihk/3NMyf1z35ESRoxwrh2NGY94PJS1LwjKwTpP9b31uLarUgV0CgyVQ4dk/bE5WFRTP0PGl/aRWF0YG3OcS96pbRHMzWXlxUuRVr3kRyuJZMjg4ihmIcKeoDItIJ/hPY...

Read more...

Revision history for this message
Larry Rosenman (lrosenman) wrote :
Download full text (4.9 KiB)

Ok, so adding an email address works for the editkeys (below).

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: Larry Rosenman <email address hidden>
Sent: Monday, May 23, 2022 6:23 PM
To: Bug 1974474 <email address hidden>
Subject: Re: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

Also, it would be nice(tm) if the error message was better as well.

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: Larry Rosenman <email address hidden>
Sent: Monday, May 23, 2022 6:17 PM
To: Bug 1974474 <email address hidden>
Subject: Re: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

I'm using 1Password's SSH key storage, and when they paste the key, that's what they put out.
Can you look into loosening that requirement?

https://developer.1password.com/docs/ssh
[https://developer.1password.com/img/meta-og-image.png]<https://developer.1password.com/docs/ssh>
1Password for SSH & Git | 1Password Developer Documentation<https://developer.1password.com/docs/ssh>
Quick start Get started . If you're setting up SSH in 1Password for the first time, start here. Guides Manage SSH keys . Learn how to generate and import SSH keys, and how to copy or download your public key if you need to share it.
developer.1password.com

--

Larry Rosenman | Senior Site Reliability Engineer | +1 214 642 9640 | <email address hidden>

US/Central Time Zone | Austin, TX

________________________________
From: <email address hidden> <email address hidden> on behalf of Colin Watson <email address hidden>
Sent: Monday, May 23, 2022 6:02 PM
To: Larry Rosenman <email address hidden>
Subject: [Bug 1974474] Re: NONE of my ssh keys work on the ssh keys page

I spotted the problem. Launchpad currently requires that SSH keys have
a comment. To illustrate, one of my own keys is the following:

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/
cjwatson@niejwein

You entered the equivalent of this instead, dropping the comment at the
end:

ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIP/u4IYcSPn1cG1vVbfQHNcuAFddmhTHRgWmB9ouedm/

Now, it's true that the comment isn't required by OpenSSH, so Launchpad
is arguably in the wrong here. (The restriction goes all the way back
to when SSH key support was first added to Launchpad in 2004.) You can
very easily work around it by adding a comment to the end of your public
key, though; `ssh-keygen` defaults to `user@host` for whatever user and
host generated the key, as you can see in my example.

--
You received this bug notification because you are subscribed to the bug
report.
https://bugs.launchpad.net/bugs/1974474<https://bugs.launchpad.net/bugs/1974474>

Title:
NONE of my ssh keys work on the ssh keys page

Status in Launchpad itself:
Incomplete

Bug description:
I tried to use both of the following public keys, and neither works.

ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAACAQC83Cm0VEYdcy+bbLNvGGr7fW9lPGgB+wTaHawc0NK7CXmtdfLITLKRrkmwhgJURn1Fjv+cO/Zvjd9f4/LgamdGRNscfh...

Read more...

Colin Watson (cjwatson)
summary: - NONE of my ssh keys work on the ssh keys page
+ Allow SSH keys without a comment
Changed in launchpad:
status: Incomplete → Opinion
status: Opinion → Triaged
importance: Undecided → Low
Revision history for this message
Colin Watson (cjwatson) wrote :

You can now add SSH keys without a comment (though a comment is still useful, and is shown on your SSH keys page if it's present).

Changed in launchpad:
assignee: nobody → Guruprasad (lgp171188)
status: Triaged → Fix Released
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.