)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     John McKenzie \u003cjmckind@gmail.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-14 10:41:18 -0500"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add support for modifying Generic Containers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This adds POST and DELETE support for a \u0027secrets\u0027 sub-resource on the"},{"line_number":10,"context_line":"containers resource. This will allow a user to add or remove secret references"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_7e6fa492","line":7,"updated":"2016-06-22 01:54:42.000000000","message":"Just nit picking here, but some of the lines are too long.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     John McKenzie \u003cjmckind@gmail.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-14 10:41:18 -0500"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add support for modifying Generic Containers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This adds POST and DELETE support for a \u0027secrets\u0027 sub-resource on the"},{"line_number":10,"context_line":"containers resource. This will allow a user to add or remove secret references"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_12e13aff","line":7,"in_reply_to":"3aaa91ec_7e6fa492","updated":"2016-06-27 17:09:31.000000000","message":"Updated the commit message to be in compliance. ;)","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"}],"barbican/api/controllers/containers.py":[{"author":{"_account_id":7789,"name":"John Wood","email":"john.wood@rackspace.com","username":"woodster"},"change_message_id":"b29ff8410245f0bb5acda6261f5e06c54a7c8faa","unresolved":false,"context_lines":[{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        if found_container_secrets:"},{"line_number":265,"context_line":"            pecan.abort(409,"},{"line_number":266,"context_line":"                        u._(\u0027Conflict. Secret in request is already in the \u0027"},{"line_number":267,"context_line":"                            \u0027container\u0027))"},{"line_number":268,"context_line":""},{"line_number":269,"context_line":"        LOG.debug(\u0027Start container secret on_post...%s\u0027, secret_ref)"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_f69f4263","line":266,"updated":"2016-06-09 16:13:47.000000000","message":"We could say \u0027your secret is already in this castle\u0027? :)\n\n We could say \u0027your secret is already in this castle\u0027? :)\n\nI think it\u0027s allowed for a generic container to have the same secret repeated within a container instance. The delete step would remove all such duplicated secrets. We probably just have to document this behavior I think.","commit_id":"e8f684f7409179feebf2e4611458728c3b810db4"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"a5badad3f37fd01a010c468147e8c907c069545b","unresolved":false,"context_lines":[{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        if found_container_secrets:"},{"line_number":265,"context_line":"            pecan.abort(409,"},{"line_number":266,"context_line":"                        u._(\u0027Conflict. Secret in request is already in the \u0027"},{"line_number":267,"context_line":"                            \u0027container\u0027))"},{"line_number":268,"context_line":""},{"line_number":269,"context_line":"        LOG.debug(\u0027Start container secret on_post...%s\u0027, secret_ref)"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_5798cd6a","line":266,"in_reply_to":"7aa08908_f69f4263","updated":"2016-06-09 17:09:51.000000000","message":"If I remember correctly, there is a unique constraint applied that includes the container_id, secret_id and name. So I think as long as the name is different, you can have the same secret_ref in the container. I\u0027ll test it out and resubmit the patch if that is the case.","commit_id":"e8f684f7409179feebf2e4611458728c3b810db4"},{"author":{"_account_id":7789,"name":"John Wood","email":"john.wood@rackspace.com","username":"woodster"},"change_message_id":"d334d918c5bed0c4cd8d724b3288a28c9af151f3","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            pecan.abort(404, u._(\"Secret provided doesn\u0027t exist.\"))"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        found_container_secrets \u003d filter(lambda cs: cs.secret_id \u003d\u003d secret_id"},{"line_number":259,"context_line":"                                         and cs.name \u003d\u003d name,"},{"line_number":260,"context_line":"                                         self.container.container_secrets)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        if found_container_secrets:"}],"source_content_type":"text/x-python","patch_set":4,"id":"7aa08908_8e556c1f","line":259,"updated":"2016-06-13 20:24:51.000000000","message":"I think to make the post and delete consistent (and consistent with docs), this \u0027and\u0027 clause needs to be after line #302 below as well.","commit_id":"3e49989711b9c7831daf2b78505670ca0083f110"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"cc4d8256ad8455c14d5c78bb2d170fb0fa657cf9","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            pecan.abort(404, u._(\"Secret provided doesn\u0027t exist.\"))"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        found_container_secrets \u003d filter(lambda cs: cs.secret_id \u003d\u003d secret_id"},{"line_number":259,"context_line":"                                         and cs.name \u003d\u003d name,"},{"line_number":260,"context_line":"                                         self.container.container_secrets)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        if found_container_secrets:"}],"source_content_type":"text/x-python","patch_set":4,"id":"7aa08908_aef11e03","line":259,"in_reply_to":"7aa08908_8e556c1f","updated":"2016-06-14 14:18:41.000000000","message":"Ahh, good catch!","commit_id":"3e49989711b9c7831daf2b78505670ca0083f110"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":122,"context_line":"        if not container:"},{"line_number":123,"context_line":"            container_not_found()"},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"        if len(remainder) \u003e\u003d 1 and remainder[0] \u003d\u003d \u0027secrets\u0027:"},{"line_number":126,"context_line":"            return ContainersSecretsController(container), ()"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        return ContainerController(container), remainder"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_9e69bb8e","line":125,"updated":"2016-06-22 01:54:42.000000000","message":"remainder should\u0027t exceed 1. If it does we throw a 405.\n\nSee http://paste.openstack.org/show/521018/","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"4c1988f93fd1ac94997c991e581186206498b5f9","unresolved":false,"context_lines":[{"line_number":122,"context_line":"        if not container:"},{"line_number":123,"context_line":"            container_not_found()"},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"        if len(remainder) \u003e\u003d 1 and remainder[0] \u003d\u003d \u0027secrets\u0027:"},{"line_number":126,"context_line":"            return ContainersSecretsController(container), ()"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        return ContainerController(container), remainder"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_d2ad79ea","line":125,"in_reply_to":"3aaa91ec_41af767d","updated":"2016-06-29 15:21:59.000000000","message":"I would still like a 405 since that route will never exist. Like https://github.com/openstack/barbican/blob/master/barbican/api/controllers/secrets.py#L95-L97\n\nBut thats a simple addition we can discuss at the midcycle.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":122,"context_line":"        if not container:"},{"line_number":123,"context_line":"            container_not_found()"},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"        if len(remainder) \u003e\u003d 1 and remainder[0] \u003d\u003d \u0027secrets\u0027:"},{"line_number":126,"context_line":"            return ContainersSecretsController(container), ()"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        return ContainerController(container), remainder"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_41af767d","line":125,"in_reply_to":"3aaa91ec_9e69bb8e","updated":"2016-06-27 17:09:31.000000000","message":"Changed this behavior to just check for what we are expecting. Otherwise, the standard logic is maintained of returning a 404 for a route that doesn\u0027t exist.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":237,"context_line":"    @controllers.enforce_rbac(\u0027container_secret:post\u0027)"},{"line_number":238,"context_line":"    @controllers.enforce_content_types([\u0027application/json\u0027])"},{"line_number":239,"context_line":"    def on_post(self, external_project_id, **kwargs):"},{"line_number":240,"context_line":"        \"\"\"Handles creation of a container secret.\"\"\""},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"        if self.container.type !\u003d \u0027generic\u0027:"},{"line_number":243,"context_line":"            pecan.abort(400, u._(\"Only \u0027generic\u0027 containers can be modified.\"))"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_5e8633ba","line":240,"updated":"2016-06-22 01:54:42.000000000","message":"Adds an existing secret to a container. Maybe add a note like that to let developer know we are not actually creating a secret","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":237,"context_line":"    @controllers.enforce_rbac(\u0027container_secret:post\u0027)"},{"line_number":238,"context_line":"    @controllers.enforce_content_types([\u0027application/json\u0027])"},{"line_number":239,"context_line":"    def on_post(self, external_project_id, **kwargs):"},{"line_number":240,"context_line":"        \"\"\"Handles creation of a container secret.\"\"\""},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"        if self.container.type !\u003d \u0027generic\u0027:"},{"line_number":243,"context_line":"            pecan.abort(400, u._(\"Only \u0027generic\u0027 containers can be modified.\"))"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_e1bdc2d8","line":240,"in_reply_to":"3aaa91ec_5e8633ba","updated":"2016-06-27 17:09:31.000000000","message":"Updated the comment to be more clear.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            pecan.abort(404, u._(\"Secret provided doesn\u0027t exist.\"))"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        found_container_secrets \u003d filter(lambda cs: cs.secret_id \u003d\u003d secret_id"},{"line_number":259,"context_line":"                                         and cs.name \u003d\u003d name,"},{"line_number":260,"context_line":"                                         self.container.container_secrets)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        if found_container_secrets:"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_5e22b3ba","line":259,"updated":"2016-06-22 01:54:42.000000000","message":"We can have the same name for different secrets[1]. Is this expected behavior?\n\n[1]http://paste.openstack.org/show/521017/","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            pecan.abort(404, u._(\"Secret provided doesn\u0027t exist.\"))"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        found_container_secrets \u003d filter(lambda cs: cs.secret_id \u003d\u003d secret_id"},{"line_number":259,"context_line":"                                         and cs.name \u003d\u003d name,"},{"line_number":260,"context_line":"                                         self.container.container_secrets)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        if found_container_secrets:"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_015d6eec","line":259,"in_reply_to":"3aaa91ec_5e22b3ba","updated":"2016-06-27 17:09:31.000000000","message":"The name/secret_ref combination must be unique. The check here is done to provide a useful error message. Otherwise the DB constraint check causes a 500 to be thrown.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":260,"context_line":"                                         self.container.container_secrets)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        if found_container_secrets:"},{"line_number":263,"context_line":"            pecan.abort(409, u._(\u0027Conflict. \u0027"},{"line_number":264,"context_line":"                                 \u0027Your secret is already in this castle.\u0027))"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"        LOG.debug(\u0027Start container secret on_post...%s\u0027, secret_ref)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_9e7edbac","line":263,"updated":"2016-06-22 01:54:42.000000000","message":"Still a Misleading message. I would change it to something along the lines of \"A secret with this name and id is already in this container\". Then say that same secrets are allowed with different names.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":260,"context_line":"                                         self.container.container_secrets)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        if found_container_secrets:"},{"line_number":263,"context_line":"            pecan.abort(409, u._(\u0027Conflict. \u0027"},{"line_number":264,"context_line":"                                 \u0027Your secret is already in this castle.\u0027))"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"        LOG.debug(\u0027Start container secret on_post...%s\u0027, secret_ref)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_41dc9646","line":263,"in_reply_to":"3aaa91ec_9e7edbac","updated":"2016-06-27 17:09:31.000000000","message":"Updated the message we return.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":305,"context_line":"                                         self.container.container_secrets)"},{"line_number":306,"context_line":""},{"line_number":307,"context_line":"        if not found_container_secrets:"},{"line_number":308,"context_line":"            pecan.abort(404, u._(\u0027Secret provided is not in the container\u0027))"},{"line_number":309,"context_line":""},{"line_number":310,"context_line":"        for container_secret in found_container_secrets:"},{"line_number":311,"context_line":"            self.container_secret_repo.delete_entity_by_id("}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_be9c6c6a","line":308,"updated":"2016-06-22 01:54:42.000000000","message":"\"Container Secret\" since can include name. Also maybe you can pass the actual Container Secret name and secret_ref.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":305,"context_line":"                                         self.container.container_secrets)"},{"line_number":306,"context_line":""},{"line_number":307,"context_line":"        if not found_container_secrets:"},{"line_number":308,"context_line":"            pecan.abort(404, u._(\u0027Secret provided is not in the container\u0027))"},{"line_number":309,"context_line":""},{"line_number":310,"context_line":"        for container_secret in found_container_secrets:"},{"line_number":311,"context_line":"            self.container_secret_repo.delete_entity_by_id("}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_04fe1c05","line":308,"in_reply_to":"3aaa91ec_be9c6c6a","updated":"2016-06-27 17:09:31.000000000","message":"Updated the error message to include the name and secret_ref.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"}],"barbican/model/models.py":[{"author":{"_account_id":7789,"name":"John Wood","email":"john.wood@rackspace.com","username":"woodster"},"change_message_id":"b29ff8410245f0bb5acda6261f5e06c54a7c8faa","unresolved":false,"context_lines":[{"line_number":231,"context_line":"    container \u003d orm.relationship("},{"line_number":232,"context_line":"        \u0027Container\u0027,"},{"line_number":233,"context_line":"        backref\u003dorm.backref(\u0027container_secrets\u0027, lazy\u003dFalse,"},{"line_number":234,"context_line":"                            primaryjoin\u003d\"and_(ContainerSecret.container_id \u003d\u003d \""},{"line_number":235,"context_line":"                            \"Container.id, ContainerSecret.deleted!\u003d1)\"))"},{"line_number":236,"context_line":"    secrets \u003d orm.relationship("},{"line_number":237,"context_line":"        \u0027Secret\u0027,"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_43b493d0","line":234,"updated":"2016-06-09 16:13:47.000000000","message":"I thought the FK relationships handled the primary join, but the not deleted clause probably wasn\u0027t being properly handled that way?","commit_id":"e8f684f7409179feebf2e4611458728c3b810db4"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"a5badad3f37fd01a010c468147e8c907c069545b","unresolved":false,"context_lines":[{"line_number":231,"context_line":"    container \u003d orm.relationship("},{"line_number":232,"context_line":"        \u0027Container\u0027,"},{"line_number":233,"context_line":"        backref\u003dorm.backref(\u0027container_secrets\u0027, lazy\u003dFalse,"},{"line_number":234,"context_line":"                            primaryjoin\u003d\"and_(ContainerSecret.container_id \u003d\u003d \""},{"line_number":235,"context_line":"                            \"Container.id, ContainerSecret.deleted!\u003d1)\"))"},{"line_number":236,"context_line":"    secrets \u003d orm.relationship("},{"line_number":237,"context_line":"        \u0027Secret\u0027,"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_bce1189d","line":234,"in_reply_to":"7aa08908_43b493d0","updated":"2016-06-09 17:09:51.000000000","message":"Yeah, the relationship doesn\u0027t take into account the deleted column. I did this here because I wanted to ensure that any reference to a Container object would not provide the deleted container secrets and not just the do that for dict fields returned in the method below.\n\nMy understanding of the sqlalchemy relationship and backref objects is that if you override the primaryjoin argument, you must specify the complete join condition, thus including the FK relationship.\n\nThere is also a secondaryjoin argument that can be used, but the docs state that it\u0027s for relationships with other tables, so I\u0027m not sure if it will allow additional conditions on the primary table. I can try it out though and see if that will work. I think that would tend to make things a little less redundant feeling.","commit_id":"e8f684f7409179feebf2e4611458728c3b810db4"},{"author":{"_account_id":7789,"name":"John Wood","email":"john.wood@rackspace.com","username":"woodster"},"change_message_id":"b29ff8410245f0bb5acda6261f5e06c54a7c8faa","unresolved":false,"context_lines":[{"line_number":776,"context_line":"                        \u0027name\u0027: container_secret.name"},{"line_number":777,"context_line":"                        if hasattr(container_secret, \u0027name\u0027) else None"},{"line_number":778,"context_line":"                    } for container_secret in self.container_secrets"},{"line_number":779,"context_line":"                    if not container_secret.deleted],"},{"line_number":780,"context_line":"                \u0027consumers\u0027: ["},{"line_number":781,"context_line":"                    {"},{"line_number":782,"context_line":"                        \u0027name\u0027: consumer.name,"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_b1766404","line":779,"updated":"2016-06-09 16:13:47.000000000","message":"Wow, I would have expected that to come up as an issue a long time ago!","commit_id":"e8f684f7409179feebf2e4611458728c3b810db4"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"a5badad3f37fd01a010c468147e8c907c069545b","unresolved":false,"context_lines":[{"line_number":776,"context_line":"                        \u0027name\u0027: container_secret.name"},{"line_number":777,"context_line":"                        if hasattr(container_secret, \u0027name\u0027) else None"},{"line_number":778,"context_line":"                    } for container_secret in self.container_secrets"},{"line_number":779,"context_line":"                    if not container_secret.deleted],"},{"line_number":780,"context_line":"                \u0027consumers\u0027: ["},{"line_number":781,"context_line":"                    {"},{"line_number":782,"context_line":"                        \u0027name\u0027: consumer.name,"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_7736a9e8","line":779,"in_reply_to":"7aa08908_b1766404","updated":"2016-06-09 17:09:51.000000000","message":"This might actually not really be needed with the change above now that I think about it. I put this code in place before the primaryjoin argument above.","commit_id":"e8f684f7409179feebf2e4611458728c3b810db4"}],"barbican/tests/api/controllers/test_containers.py":[{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":306,"context_line":"        container \u003d containers_repo.get(container_uuid, self.project_id)"},{"line_number":307,"context_line":"        self.assertEqual(1, len(container.container_secrets))"},{"line_number":308,"context_line":""},{"line_number":309,"context_line":"    def test_should_add_container_secret_without_name(self):"},{"line_number":310,"context_line":"        container_name \u003d \u0027test container name\u0027"},{"line_number":311,"context_line":"        container_type \u003d \u0027generic\u0027"},{"line_number":312,"context_line":"        resp, container_uuid \u003d create_container("}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_67da827a","line":309,"updated":"2016-06-22 01:54:42.000000000","message":"Add a test for \"should_fail_at_add_container_secret_with_same_name\" if needed. Just waiting to see if expected behavior.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":306,"context_line":"        container \u003d containers_repo.get(container_uuid, self.project_id)"},{"line_number":307,"context_line":"        self.assertEqual(1, len(container.container_secrets))"},{"line_number":308,"context_line":""},{"line_number":309,"context_line":"    def test_should_add_container_secret_without_name(self):"},{"line_number":310,"context_line":"        container_name \u003d \u0027test container name\u0027"},{"line_number":311,"context_line":"        container_type \u003d \u0027generic\u0027"},{"line_number":312,"context_line":"        resp, container_uuid \u003d create_container("}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_07b9feec","line":309,"in_reply_to":"3aaa91ec_67da827a","updated":"2016-06-27 17:09:31.000000000","message":"Added another test to verify that two secret_refs cannot be added to a container with the same name.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":21797,"name":"Jeremy Liu","display_name":"Jeremy Liu","username":"liujiong"},"change_message_id":"722f4c1e2da978e18a69aa0249158035a6c06bb0","unresolved":false,"context_lines":[{"line_number":494,"context_line":""},{"line_number":495,"context_line":"        resp, updated_container_uuid \u003d create_container_secret("},{"line_number":496,"context_line":"            self.app,"},{"line_number":497,"context_line":"            container_id\u003dcontainer_uuid,"},{"line_number":498,"context_line":"            secret_ref\u003dsecret_ref,"},{"line_number":499,"context_line":"            name\u003dcontainer_secret_name,"},{"line_number":500,"context_line":"            expect_errors\u003dTrue"}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_1ea2b54b","line":497,"range":{"start_line":497,"start_character":25,"end_line":497,"end_character":39},"updated":"2016-06-28 13:23:50.000000000","message":"should this be updated_container_uuid? cause you call \"create_container_secret\" function to create a secret and this should be ok, so the container_uuid should have already updated.","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"a6dd40eb98fd59f269305db7a9e7a5ad75e6f2e4","unresolved":false,"context_lines":[{"line_number":494,"context_line":""},{"line_number":495,"context_line":"        resp, updated_container_uuid \u003d create_container_secret("},{"line_number":496,"context_line":"            self.app,"},{"line_number":497,"context_line":"            container_id\u003dcontainer_uuid,"},{"line_number":498,"context_line":"            secret_ref\u003dsecret_ref,"},{"line_number":499,"context_line":"            name\u003dcontainer_secret_name,"},{"line_number":500,"context_line":"            expect_errors\u003dTrue"}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_b01bc5c9","line":497,"range":{"start_line":497,"start_character":25,"end_line":497,"end_character":39},"in_reply_to":"3aaa91ec_1ea2b54b","updated":"2016-06-28 15:57:11.000000000","message":"It really doesn\u0027t matter, as this test is working with the same container and both IDs are the same. I thought it would more confusing to someone reading it later to have the return value update the \"container_uuid\" variable.","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"},{"author":{"_account_id":21797,"name":"Jeremy Liu","display_name":"Jeremy Liu","username":"liujiong"},"change_message_id":"722f4c1e2da978e18a69aa0249158035a6c06bb0","unresolved":false,"context_lines":[{"line_number":558,"context_line":""},{"line_number":559,"context_line":"        self.assertEqual(400, resp.status_int)"},{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    def test_should_not_allow_add_secret_when_exists_in_container(self):"},{"line_number":562,"context_line":"        container_name \u003d \u0027test container name\u0027"},{"line_number":563,"context_line":"        container_type \u003d \u0027generic\u0027"},{"line_number":564,"context_line":"        resp, container_uuid \u003d create_container("}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_7913135d","line":561,"range":{"start_line":561,"start_character":8,"end_line":561,"end_character":65},"updated":"2016-06-28 13:23:50.000000000","message":"Is this a duplicate testcase with \"test_should_not_add_container_secret_with_duplicate_name\" ?","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"a6dd40eb98fd59f269305db7a9e7a5ad75e6f2e4","unresolved":false,"context_lines":[{"line_number":558,"context_line":""},{"line_number":559,"context_line":"        self.assertEqual(400, resp.status_int)"},{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    def test_should_not_allow_add_secret_when_exists_in_container(self):"},{"line_number":562,"context_line":"        container_name \u003d \u0027test container name\u0027"},{"line_number":563,"context_line":"        container_type \u003d \u0027generic\u0027"},{"line_number":564,"context_line":"        resp, container_uuid \u003d create_container("}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_f97b7979","line":561,"range":{"start_line":561,"start_character":8,"end_line":561,"end_character":65},"in_reply_to":"3aaa91ec_7913135d","updated":"2016-06-28 15:57:11.000000000","message":"I have modified and renamed the \"test_should_not_add_container_secret_with_duplicate_name\" test to better verify the behavior that I intended to demonstrate.\n\nWhat the test points out, highlights Fernando\u0027s comment about different secret_refs stored in a container with the same name. While this seems like something we should not allow, it is the existing behavior and I wanted to preserve that for now so that we could have a discussion about it.\n\nI am interested in people\u0027s thoughts on that current behavior where one can store multiple different secret_refs in a container with the same name. Should we really allow that?","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"c14d239768bfde04891f48a206b0bc10d8033eb7","unresolved":false,"context_lines":[{"line_number":558,"context_line":""},{"line_number":559,"context_line":"        self.assertEqual(400, resp.status_int)"},{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    def test_should_not_allow_add_secret_when_exists_in_container(self):"},{"line_number":562,"context_line":"        container_name \u003d \u0027test container name\u0027"},{"line_number":563,"context_line":"        container_type \u003d \u0027generic\u0027"},{"line_number":564,"context_line":"        resp, container_uuid \u003d create_container("}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_d700cb36","line":561,"range":{"start_line":561,"start_character":8,"end_line":561,"end_character":65},"in_reply_to":"3aaa91ec_f97b7979","updated":"2016-06-29 15:22:09.000000000","message":"Looks good for now, but we should talk about this during the midcycle. I think duplicate names add some confusion.","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"},{"author":{"_account_id":21797,"name":"Jeremy Liu","display_name":"Jeremy Liu","username":"liujiong"},"change_message_id":"722f4c1e2da978e18a69aa0249158035a6c06bb0","unresolved":false,"context_lines":[{"line_number":886,"context_line":"                       if val is not None}"},{"line_number":887,"context_line":""},{"line_number":888,"context_line":"    resp \u003d app.delete_json("},{"line_number":889,"context_line":"        \u0027/containers/{container_id}/secrets\u0027.format(container_id\u003dcontainer_id),"},{"line_number":890,"context_line":"        cleaned_request,"},{"line_number":891,"context_line":"        expect_errors\u003dexpect_errors,"},{"line_number":892,"context_line":"        headers\u003dheaders"}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_5e0efd32","line":889,"range":{"start_line":889,"start_character":7,"end_line":889,"end_character":78},"updated":"2016-06-28 13:23:50.000000000","message":"looks like it will delete all the secrets in the container, not just the specified one.","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"a6dd40eb98fd59f269305db7a9e7a5ad75e6f2e4","unresolved":false,"context_lines":[{"line_number":886,"context_line":"                       if val is not None}"},{"line_number":887,"context_line":""},{"line_number":888,"context_line":"    resp \u003d app.delete_json("},{"line_number":889,"context_line":"        \u0027/containers/{container_id}/secrets\u0027.format(container_id\u003dcontainer_id),"},{"line_number":890,"context_line":"        cleaned_request,"},{"line_number":891,"context_line":"        expect_errors\u003dexpect_errors,"},{"line_number":892,"context_line":"        headers\u003dheaders"}],"source_content_type":"text/x-python","patch_set":6,"id":"3aaa91ec_96bcc2dc","line":889,"range":{"start_line":889,"start_character":7,"end_line":889,"end_character":78},"in_reply_to":"3aaa91ec_5e0efd32","updated":"2016-06-28 15:57:11.000000000","message":"The body of the request specifies the name/secret_ref to delete.\n\nThe on_delete method of the controller checks for the name and secret_ref and deletes any that are found. The database constraints should never allow more than one secret_ref with the same name but I added the loop to delete all occurrences of secret_ref with the specified name just in case.","commit_id":"3a0340858f0775482f8d63e48707e810385e7e07"}],"doc/source/api/reference/containers.rst":[{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":276,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":277,"context_line":"| 404  | Container not found or unavailable                                          |"},{"line_number":278,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":279,"context_line":""},{"line_number":280,"context_line":"POST /v1/containers/{container_uuid}/secrets"},{"line_number":281,"context_line":"############################################"},{"line_number":282,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_0163ae1b","line":279,"updated":"2016-06-22 01:54:42.000000000","message":"Maybe we can add a reference in http://developer.openstack.org/api-guide/key-manager/containers.html#generic-containers for generic containers.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":276,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":277,"context_line":"| 404  | Container not found or unavailable                                          |"},{"line_number":278,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":279,"context_line":""},{"line_number":280,"context_line":"POST /v1/containers/{container_uuid}/secrets"},{"line_number":281,"context_line":"############################################"},{"line_number":282,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_12d5bab8","line":279,"in_reply_to":"3aaa91ec_0163ae1b","updated":"2016-06-27 17:09:31.000000000","message":"I can do that in a separate patch.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"4c1988f93fd1ac94997c991e581186206498b5f9","unresolved":false,"context_lines":[{"line_number":276,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":277,"context_line":"| 404  | Container not found or unavailable                                          |"},{"line_number":278,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":279,"context_line":""},{"line_number":280,"context_line":"POST /v1/containers/{container_uuid}/secrets"},{"line_number":281,"context_line":"############################################"},{"line_number":282,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_d2f739d1","line":279,"in_reply_to":"3aaa91ec_12d5bab8","updated":"2016-06-29 15:21:59.000000000","message":"Sounds Good!","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":336,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":337,"context_line":"| 400  | Missing secret_ref                                                          |"},{"line_number":338,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":339,"context_line":"| 401  | Invalid X-Auth-Token or the token doesn\u0027t have permissions to this resource |"},{"line_number":340,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":341,"context_line":""},{"line_number":342,"context_line":"DELETE /v1/containers/{container_uuid}/secrets"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_470f86e1","line":339,"updated":"2016-06-22 01:54:42.000000000","message":"We can add 403, but no biggie.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":336,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":337,"context_line":"| 400  | Missing secret_ref                                                          |"},{"line_number":338,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":339,"context_line":"| 401  | Invalid X-Auth-Token or the token doesn\u0027t have permissions to this resource |"},{"line_number":340,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":341,"context_line":""},{"line_number":342,"context_line":"DELETE /v1/containers/{container_uuid}/secrets"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_f2774e06","line":339,"in_reply_to":"3aaa91ec_470f86e1","updated":"2016-06-27 17:09:31.000000000","message":"Added the 403 status code description.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":389,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":390,"context_line":"| 400  | Missing secret_ref                                                          |"},{"line_number":391,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":392,"context_line":"| 401  | Invalid X-Auth-Token or the token doesn\u0027t have permissions to this resource |"},{"line_number":393,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":394,"context_line":"| 404  | Specified secret_ref is not found in the container.                         |"},{"line_number":395,"context_line":"+------+-----------------------------------------------------------------------------+"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_67f602d9","line":392,"updated":"2016-06-22 01:54:42.000000000","message":"We can add 403, but no biggie.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":389,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":390,"context_line":"| 400  | Missing secret_ref                                                          |"},{"line_number":391,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":392,"context_line":"| 401  | Invalid X-Auth-Token or the token doesn\u0027t have permissions to this resource |"},{"line_number":393,"context_line":"+------+-----------------------------------------------------------------------------+"},{"line_number":394,"context_line":"| 404  | Specified secret_ref is not found in the container.                         |"},{"line_number":395,"context_line":"+------+-----------------------------------------------------------------------------+"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3aaa91ec_921c0ac3","line":392,"in_reply_to":"3aaa91ec_67f602d9","updated":"2016-06-27 17:09:31.000000000","message":"Added the 403 status code description.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"}],"etc/barbican/policy.json":[{"author":{"_account_id":16046,"name":"Fernando Diaz","email":"diazjf@us.ibm.com","username":"diazjf"},"change_message_id":"99b8da48bf82682262b69d6d076ef2683e911ee3","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    \"container:get\": \"rule:container_non_private_read or rule:container_project_creator or rule:container_project_admin or rule:container_acl_read\","},{"line_number":48,"context_line":"    \"container:delete\": \"rule:admin\","},{"line_number":49,"context_line":"    \"container_secret:post\": \"rule:admin_or_creator\","},{"line_number":50,"context_line":"    \"container_secret:delete\": \"rule:admin_or_creator\","},{"line_number":51,"context_line":"    \"transport_key:get\": \"rule:all_users\","},{"line_number":52,"context_line":"    \"transport_key:delete\": \"rule:admin\","},{"line_number":53,"context_line":"    \"transport_keys:get\": \"rule:all_users\","}],"source_content_type":"application/json","patch_set":5,"id":"3aaa91ec_deed0327","line":50,"updated":"2016-06-22 01:54:42.000000000","message":"maybe this should be \"admin\" since we don\u0027t want a creator deleting something another \"creator\" created.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"},{"author":{"_account_id":780,"name":"John McKenzie","email":"jmckind@gmail.com","username":"jmckind"},"change_message_id":"4633008ceab7312f3f8ffba8bc0516da90031557","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    \"container:get\": \"rule:container_non_private_read or rule:container_project_creator or rule:container_project_admin or rule:container_acl_read\","},{"line_number":48,"context_line":"    \"container:delete\": \"rule:admin\","},{"line_number":49,"context_line":"    \"container_secret:post\": \"rule:admin_or_creator\","},{"line_number":50,"context_line":"    \"container_secret:delete\": \"rule:admin_or_creator\","},{"line_number":51,"context_line":"    \"transport_key:get\": \"rule:all_users\","},{"line_number":52,"context_line":"    \"transport_key:delete\": \"rule:admin\","},{"line_number":53,"context_line":"    \"transport_keys:get\": \"rule:all_users\","}],"source_content_type":"application/json","patch_set":5,"id":"3aaa91ec_446ca408","line":50,"in_reply_to":"3aaa91ec_deed0327","updated":"2016-06-27 17:09:31.000000000","message":"Changed the policy to admins only.","commit_id":"85792294fa11a4cc621f7b24bb367705ab4293eb"}]}
