Bug 858789 - Openshift provide public key form not adding a public key to account generates error
Summary: Openshift provide public key form not adding a public key to account generate...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OKD
Classification: Red Hat
Component: Containers
Version: 1.x
Hardware: Unspecified
OS: Windows
medium
medium
Target Milestone: ---
: ---
Assignee: Rob Millner
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-09-19 17:09 UTC by Nathan Davidoff
Modified: 2013-11-18 00:43 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-11-06 18:50:08 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
picture of the error in openshift console (234.02 KB, image/png)
2012-09-19 17:09 UTC, Nathan Davidoff
no flags Details
tried a new key still got same error not sure what error means. (59.35 KB, image/png)
2012-09-20 14:18 UTC, Nathan Davidoff
natedavidoff: review+
Details

Description Nathan Davidoff 2012-09-19 17:09:17 UTC
Created attachment 614483 [details]
picture of the error in openshift console

Description of problem:
Openshift Console, Paste the contents of your public key file (.pub)Window prints an error when trying to save my public key. 

Version-Release number of selected component (if applicable):


How reproducible:
Easy to reproduce

Steps to Reproduce:
1. generate public ssh key on local
2. paste the key into the window
3. click submit
  
Actual results:
No public key is added and error message is generated

Expected results:
public key gets added to my account page.

Additional info:
Attached a picture of the bug would like feedback to workaround.
Nate

Comment 1 joycezhang 2012-09-20 02:25:50 UTC
For this bug, it can't be reproduced on PROD and STG env. Could you please help confirm if we miss any steps to reproduce this bug or Could you provide more information for us to reproduce this bug? Thanks in advance!

Build version:
rhc-0.99.1.gem 
stg.openshift.redhat.com
openshift.redhat.com

Clients and Browser:
Windows7+IE9
Fedora17+Firefox12

Steps we tried:
1. Generate sshkey from clients:
# ssh-keygen 
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa): mykey1
Enter passphrase (empty for no passphrase): 
Enter same passphrase again: 
Your identification has been saved in mykey1.
Your public key has been saved in mykey1.pub.
The key fingerprint is:
53:6f:59:3a:cf:86:58:91:10:64:5d:76:ad:1e:43:bb root@joycezh
The key's randomart image is:
+--[ RSA 2048]----+
|         .=o .o o|
|         . ..o...|
|          . o..o |
|         . . ==  |
|        S   B. + |
|         . + =E  |
|          . . +  |
|             .   |
|                 |
+-----------------+

2. Cat and copy new generated public key
# cat ./mykey1.pub 
3. Log into openshift website by Browser->My account -> Add a new key
4. Paste the key which copied in step2 and click create.

Actual results:
Message "Your public key has been created" is shown.

Comment 2 Nathan Davidoff 2012-09-20 14:11:17 UTC
Can you include in the comments the public key that you are pasting into the openshift console? Here is the one I am using, try mine, and it doesn't work? Is the syntax of my public key incorrect, the window let me submit it with no problems and still failed to update.

ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAIEA6iWhReXoUdsP31JpI3JO1/GDuHNBvh6oQcsaWIapjA1JTTWfNEMSduW0XFAS0ICUdbJ7spefcTtZ49SGVPy89aTcIIzTuxxfiTqvqYcuz4lej5oNZI8GblL+s/cni9FudkxzxdiTyFgA9S7DAPATmByaVABUvdAR1EIYFgEAVck= nathan.davidoff

Comment 3 Nathan Davidoff 2012-09-20 14:16:52 UTC
What does that Error generated indicate is wrong with my input?
I tried this key also and it generated the same error:
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAIEAtMNmYnQ/V3KVaE5xF/MblnZAdiWxAyJIZuz010M6KbsNCB/Q7C6el4FW9LrcubzX0gfQsxNSRAk6XVHmT4bHt/yMfM9ji0fEmb6hjqey03CT+ufYaY3GkDehB5uWowLUpA7tPuxg4GQxfuunTaUa/eeo7vGbvmY32J4AW8Megr0= natedavidoff

Comment 4 Nathan Davidoff 2012-09-20 14:18:40 UTC
Created attachment 614943 [details]
tried a new key still got same error not sure what error means.

Comment 5 joycezhang 2012-09-21 06:44:11 UTC
Thank your for providing us the further information!I can add your public key successfully.

As our development team are investigating this problem, you can use following workaroud to try again. Sorry for the inconvenience and hope it's helpful for you:

1. Backup the app
#rhc app snapshot save -a appname -p xxx
2. Destroy the app
#rhc app destroy -a appname -p xxx
3. Create an app with same app name
4. Restore the app 
#rhc app snapshot restore -a appname -p xxx -f ./appname.tar.gz
5. Try to add sshkey again

And one more question: how about the result if you try to add sshkey by rhc command as below?
#rhc sshkey add keyname keypath

Any further progress will update to you here. Thanks.

Comment 6 Rob Millner 2012-09-27 18:25:32 UTC
This was due to an issue in production where the .ssh directories for a number of gears (including yours) were removed.  The problem has been resolved and we've verified that your gear now has an .ssh directory with appropriate permissions and SELinux attributes.

Please verify you can now install ssh keys and please let us know if there are additional issues.  Thanks!


Note You need to log in before you can comment on or make changes to this bug.