500 error on invalid pubkey with KeyPair API

Bug #902395 reported by Nachi Ueno
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Low
Brian Waldon

Bug Description

500 error on invalid pubkey with KeyPair API

This must be 400 Bad Request

https://servers.api.openstack.com/v1.1//{tenantId}/os-keypairs

Method:POST
API:Create Keypair

HTTP/1.1 500 Internal Server Error  {"cloudServersFault": {"message": "Unexpected error while running command.\nCommand: ssh-keygen -q -l -f /tmp/tmp88WylC/import.pub\nExit code: 1\nStdout: '/tmp/tmp88WylC/import.pub is not a public key file.\\n'\nStderr: 'line 1 too long: bad...\\r\\n'", "code": 500}}n

Thierry Carrez (ttx)
Changed in nova:
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.openstack.org/3530

Changed in nova:
assignee: nobody → Brian Waldon (bcwaldon)
status: Confirmed → In Progress
Brian Waldon (bcwaldon)
Changed in nova:
milestone: none → essex-4
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/3530
Committed: http://github.com/openstack/nova/commit/9fa7db58c22b3a4ba238d3cb9d39233968439cb1
Submitter: Jenkins
Branch: master

commit 9fa7db58c22b3a4ba238d3cb9d39233968439cb1
Author: Brian Waldon <email address hidden>
Date: Sat Jan 28 19:43:45 2012 -0800

    Raise 400 if bad kepair data is provided

    Fixes bug 902395

    Change-Id: If04a0bf432ad4828ac1fc68f6d33dff5f9f57e24

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: essex-4 → 2012.1
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.