Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1058851 - [new relic] Invalid SSH key names can't be deleted, block app create/delete
Summary: [new relic] Invalid SSH key names can't be deleted, block app create/delete
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Pod
Version: 1.x
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: ---
Assignee: Abhishek Gupta
QA Contact: libra bugs
Depends On:
TreeView+ depends on / blocked
Reported: 2014-01-28 15:54 UTC by Jessica Forrester
Modified: 2014-02-26 19:10 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2014-02-26 19:10:38 UTC
Target Upstream Version:

Attachments (Terms of Use)

Description Jessica Forrester 2014-01-28 15:54:36 UTC
Description of problem:
The broker is returning 422 for a handful of apps on STG when they are being deleted.  The app delete originated from the mgmt console so we wouldn't expect the end user to be providing any input that would generate a 422.

Additional info:
Apps that failed delete with a 422:

Comment 3 Jordan Liggitt 2014-01-28 16:12:52 UTC
Looks like a validation error from the user is being returned when attempting to delete an app:

{"api_version":1.6,"data":null,"messages":[{"exit_code":null,"field":"ssh_keys","index":null,"severity":"error","text":"is invalid"}],"status":"unprocessable_entity","supported_api_versions":[1.0,1.1,1.2,1.3,1.4,1.5,1.6],"type":null,"version":"1.6"}

Not sure why the user is being modified/saved during an app delete. Did this just change, or was extra validation added this sprint?

Comment 4 Abhishek Gupta 2014-01-28 19:51:31 UTC
The code has had the validation in place for a while now we've confirmed that a new ssh key cannot be added that has a dot as its name. Also, the broken ssh key has been removed from the user document in mongo.

Comment 5 Yujie Zhang 2014-01-29 02:10:17 UTC
Tried on STG(devenv-stage_666) again, all the application of my account including above apps can be deleted successfully, so verify this bug, thanks.

Comment 6 Jordan Liggitt 2014-02-06 14:20:11 UTC
Reopening, this is affecting at least one user in PROD (me). Apparently we never swept for invalid key names after enforcing validation.

User (in PROD):

Comment 7 Jordan Liggitt 2014-02-06 14:24:29 UTC
Got around the issue by appending ".json" to the key url:

curl -X DELETE -H "authorization: Bearer ..." ""

curl -X DELETE -H "authorization: Bearer ..." ""

We should still sweep for invalid keys

Comment 8 Abhishek Gupta 2014-02-10 17:17:49 UTC
Had Ops do a sweep in production for invalid ssh keys -- actually just the ones with names like dot (.) and two-dots (..) -- and there are none.

Comment 9 Jianwei Hou 2014-02-11 05:10:00 UTC
This bug is not reproducible on devenv_4357 and according to comment 8, the invalid ssh keys are cleaned up. Mark as verified.

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