# Revision history [back]

I was able to get formpost to work at the container level with ACLs using container keys.

I set the container level key with the "X-Container-Meta-Temp-URL-Key" marker.

Set the container level key

swift post -m "Temp-URL-Key:<random key>" <container name>


For more info see the formpost middleware docs regarding keys. These keys are scoped to their respective container/account. http://docs.openstack.org/developer/swift/api/temporary_url_middleware.html#secret-keys

note: This is only supported in the 2.3.0 (or higher) Kilo release (April 15th, 2015). 2.2.2 is part of Kilo but does not support it.

The following describes additional required steps for formpost to work at the account and container level which you may be aware of but I'm putting it here for reference for potential readers.

Make sure write ACL is set

swift post -w <tenantname>:<username> <container name>


To provide read access, do the following however it's not required to complete a form post AFAIK

swift post -r <tenantname>:<username> <container name>


CORS enabled

swift post -H "X-Container-Meta-Access-Control-Expose-Headers:Access-Control-Allow-Origin" -H "X-Container-Meta-Access-Control-Allow-Origin:<url you're posting from>" <container name>


Creating the form with a signature

Create the form according to the docs. A signature is created using the key set above. http://docs.openstack.org/developer/swift/api/form_post_middleware.html#hmac-sha1-signature-for-form-post