Specified content type is dropped on single step create secret

Bug #1254169 reported by John Vrbanac
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Barbican
Fix Released
Medium
Arvind Tiwari

Bug Description

Description: On single step creation of a secret, if you include a payload content type without a payload it creates the secret and just throws away the content type data. I would expect that this would throw an error as the content type has to have the payload to work.
Environment: Dev | Local
Test Specification: functional.secrets.SecretsAPI.test_create_secret_with_only_content_type

Steps to reproduce:
1. Create a secret
POST http://{{host}}/v1/{{tenant_id}}/secrets
{
  "payload_content_type": "text/plain"
}
Expected:
400 Bad Request

Actual Response:
201 Created
{
    "secret_ref": "http://localhost:9311/v1/test_tenant/secrets/1576d586-0c25-4f25-b165-36fba6f61872"
}

Tags: usability
Changed in barbican:
importance: Undecided → Medium
John Wood (john-wood-w)
Changed in barbican:
milestone: none → icehouse-1
John Wood (john-wood-w)
Changed in barbican:
milestone: icehouse-1 → icehouse-2
John Wood (john-wood-w)
Changed in barbican:
milestone: icehouse-2 → icehouse-3
Changed in barbican:
assignee: nobody → Arvind Tiwari (arvind-tiwari)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to barbican (master)

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

Changed in barbican:
status: Confirmed → In Progress
Revision history for this message
Arvind Tiwari (arvind-tiwari) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to barbican (master)

Reviewed: https://review.openstack.org/72190
Committed: https://git.openstack.org/cgit/stackforge/barbican/commit/?id=6df41d181921753fcd78aed477b4317bfb963291
Submitter: Jenkins
Branch: master

commit 6df41d181921753fcd78aed477b4317bfb963291
Author: Arvind Tiwari <email address hidden>
Date: Sun Feb 9 16:46:47 2014 -0700

    Specified content type is dropped
    on single step create secret

    Closes-Bug: #1254169

    Change-Id: Ibb8543186157ee67ac6020e729e7323155ed7a1d

Changed in barbican:
status: In Progress → Fix Committed
Changed in barbican:
status: Fix Committed → 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.