)]}'
{"swift/common/middleware/encrypter.py":[{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"5b2d3aa8fdf8ac8ce69f56383e651d0149ddb501","unresolved":false,"context_lines":[{"line_number":275,"context_line":"        self.conf \u003d conf"},{"line_number":276,"context_line":"        self.crypto \u003d Crypto(self.conf)"},{"line_number":277,"context_line":"        self.disable_encryption \u003d False"},{"line_number":278,"context_line":"        if conf.get(\u0027disable_encryption\u0027, \u0027false\u0027).lower() \u003d\u003d \u0027true\u0027:"},{"line_number":279,"context_line":"            self.disable_encryption \u003d True"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"    def __call__(self, env, start_response):"}],"source_content_type":"text/x-python","patch_set":2,"id":"dab17558_76c72164","line":278,"updated":"2016-05-17 08:57:09.000000000","message":"use swift/common/utils.py:config_true_value()","commit_id":"5818a46b83b24a86e67882480249f69c05045b8e"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"5b2d3aa8fdf8ac8ce69f56383e651d0149ddb501","unresolved":false,"context_lines":[{"line_number":291,"context_line":""},{"line_number":292,"context_line":"        if hasattr(EncrypterObjContext, req.method):"},{"line_number":293,"context_line":"            # handle only those request methods that may require keys"},{"line_number":294,"context_line":"            enc_context \u003d EncrypterObjContext("},{"line_number":295,"context_line":"                self, self.logger, self.disable_encryption)"},{"line_number":296,"context_line":"            try:"},{"line_number":297,"context_line":"                return getattr(enc_context, req.method)(req, start_response)"}],"source_content_type":"text/x-python","patch_set":2,"id":"dab17558_b662293c","line":294,"updated":"2016-05-17 08:57:09.000000000","message":"The hasattr(method) pattern was nice but I don\u0027t think it is serving us well if we have to instantiate an EncrypterObjContext object simply for it to do nothing but return the app resp.\n\nI think it would be better, and easier to follow the code, to now have after LINE 286:\n\n  if self.disable_encryption and req.method in (\u0027PUT\u0027, \u0027POST\u0027):\n      return self.app(env, start_response)","commit_id":"5818a46b83b24a86e67882480249f69c05045b8e"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"1f6dd1b0a99a5bdaa78ea3bec40793155b7b156f","unresolved":false,"context_lines":[{"line_number":265,"context_line":"        self.crypto \u003d Crypto(self.conf)"},{"line_number":266,"context_line":"        self.disable_encryption \u003d False"},{"line_number":267,"context_line":"        if config_true_value(conf.get(\u0027disable_encryption\u0027, \u0027false\u0027)):"},{"line_number":268,"context_line":"            self.disable_encryption \u003d True"},{"line_number":269,"context_line":""},{"line_number":270,"context_line":"    def __call__(self, env, start_response):"},{"line_number":271,"context_line":"        # If override is set in env, then just pass along"}],"source_content_type":"text/x-python","patch_set":4,"id":"bab6814e_c9c5325c","line":268,"updated":"2016-05-18 15:30:29.000000000","message":"simpler:\n\n  self.disable_encryption \u003d config_true_value(conf.get(\u0027disable_encryption\u0027, \u0027false\u0027))","commit_id":"1fd7f4f0d36610ee644fc700d73eaed7e0c53cd3"},{"author":{"_account_id":12261,"name":"Mahati","email":"mahati.chamarthy@gmail.com","username":"Mahati"},"change_message_id":"e2af96057a01898b7e23a7f5734f5562ad05e12f","unresolved":false,"context_lines":[{"line_number":265,"context_line":"        self.crypto \u003d Crypto(self.conf)"},{"line_number":266,"context_line":"        self.disable_encryption \u003d False"},{"line_number":267,"context_line":"        if config_true_value(conf.get(\u0027disable_encryption\u0027, \u0027false\u0027)):"},{"line_number":268,"context_line":"            self.disable_encryption \u003d True"},{"line_number":269,"context_line":""},{"line_number":270,"context_line":"    def __call__(self, env, start_response):"},{"line_number":271,"context_line":"        # If override is set in env, then just pass along"}],"source_content_type":"text/x-python","patch_set":4,"id":"bab6814e_f3815ffc","line":268,"in_reply_to":"bab6814e_c9c5325c","updated":"2016-05-22 19:25:24.000000000","message":"Then the test written for this becomes invalid. can modify to suit this, but is that what we want?\n\nI also will need to compare below in Line 277 with config_true_value. Just confirming.","commit_id":"1fd7f4f0d36610ee644fc700d73eaed7e0c53cd3"},{"author":{"_account_id":12261,"name":"Mahati","email":"mahati.chamarthy@gmail.com","username":"Mahati"},"change_message_id":"9cc7274e5446c7dce056908a9785a564d76f552d","unresolved":false,"context_lines":[{"line_number":265,"context_line":"        self.crypto \u003d Crypto(self.conf)"},{"line_number":266,"context_line":"        self.disable_encryption \u003d False"},{"line_number":267,"context_line":"        if config_true_value(conf.get(\u0027disable_encryption\u0027, \u0027false\u0027)):"},{"line_number":268,"context_line":"            self.disable_encryption \u003d True"},{"line_number":269,"context_line":""},{"line_number":270,"context_line":"    def __call__(self, env, start_response):"},{"line_number":271,"context_line":"        # If override is set in env, then just pass along"}],"source_content_type":"text/x-python","patch_set":4,"id":"bab6814e_11b494cf","line":268,"in_reply_to":"bab6814e_e336834f","updated":"2016-05-24 07:38:23.000000000","message":"uh oh. yes, sorry i misread config_true_value.","commit_id":"1fd7f4f0d36610ee644fc700d73eaed7e0c53cd3"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"ee658ecf5baabc62bad1a653f0a282d8e7624ad3","unresolved":false,"context_lines":[{"line_number":265,"context_line":"        self.crypto \u003d Crypto(self.conf)"},{"line_number":266,"context_line":"        self.disable_encryption \u003d False"},{"line_number":267,"context_line":"        if config_true_value(conf.get(\u0027disable_encryption\u0027, \u0027false\u0027)):"},{"line_number":268,"context_line":"            self.disable_encryption \u003d True"},{"line_number":269,"context_line":""},{"line_number":270,"context_line":"    def __call__(self, env, start_response):"},{"line_number":271,"context_line":"        # If override is set in env, then just pass along"}],"source_content_type":"text/x-python","patch_set":4,"id":"bab6814e_e336834f","line":268,"in_reply_to":"bab6814e_f3815ffc","updated":"2016-05-23 17:22:43.000000000","message":"test_config_true_value_on_disable_encryption seems to pass fine with the suggested change.\n\nI can\u0027t see what change would be needed at line 277. self.disable_encryption will either be True or False","commit_id":"1fd7f4f0d36610ee644fc700d73eaed7e0c53cd3"}],"swift/common/middleware/keymaster.py":[{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"5ab41fee545527cb305869e1a8434b95597232cc","unresolved":false,"context_lines":[{"line_number":181,"context_line":"        self.logger \u003d get_logger(conf, log_route\u003d\"keymaster\")"},{"line_number":182,"context_line":"        self.override \u003d False"},{"line_number":183,"context_line":"        if conf.get(\u0027disable_encryption\u0027, \u0027false\u0027).lower() \u003d\u003d \u0027true\u0027:"},{"line_number":184,"context_line":"            self.override \u003d True"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"        self.root_secret \u003d conf.get(\u0027encryption_root_secret\u0027, None)"},{"line_number":187,"context_line":"        if not self.root_secret:"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_17128fb4","line":184,"updated":"2016-05-13 12:48:42.000000000","message":"This it too indiscriminate - we need the encrypter to handle GETs even if encryption is disabled. So I think the disable_encryption option needs to be a property of the encrypter and apply only to PUTs and POSTs. i.e. ti does not set the override flag in environ.","commit_id":"69bfa901e3315c3c43b4d904c645227d8ce3d267"},{"author":{"_account_id":12261,"name":"Mahati","email":"mahati.chamarthy@gmail.com","username":"Mahati"},"change_message_id":"b4e12bace90867d1c3f3a665239342f8c95d9934","unresolved":false,"context_lines":[{"line_number":181,"context_line":"        self.logger \u003d get_logger(conf, log_route\u003d\"keymaster\")"},{"line_number":182,"context_line":"        self.override \u003d False"},{"line_number":183,"context_line":"        if conf.get(\u0027disable_encryption\u0027, \u0027false\u0027).lower() \u003d\u003d \u0027true\u0027:"},{"line_number":184,"context_line":"            self.override \u003d True"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"        self.root_secret \u003d conf.get(\u0027encryption_root_secret\u0027, None)"},{"line_number":187,"context_line":"        if not self.root_secret:"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_dfec74f5","line":184,"in_reply_to":"dab17558_17128fb4","updated":"2016-05-15 04:44:49.000000000","message":"oops, my bad. will fix it.","commit_id":"69bfa901e3315c3c43b4d904c645227d8ce3d267"}],"test/unit/common/middleware/test_encrypter.py":[{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"61f1a0db0b56fd540f89348b7be5dcdab2812562","unresolved":false,"context_lines":[{"line_number":555,"context_line":"        for val in (\u0027true\u0027, \u00271\u0027, \u0027yes\u0027, \u0027on\u0027, \u0027t\u0027, \u0027y\u0027):"},{"line_number":556,"context_line":"            app \u003d encrypter.Encrypter(app,"},{"line_number":557,"context_line":"                                      {\u0027disable_encryption\u0027: val})"},{"line_number":558,"context_line":"            self.assertEqual(True, app.disable_encryption)"},{"line_number":559,"context_line":""},{"line_number":560,"context_line":"    def test_filter(self):"},{"line_number":561,"context_line":"        factory \u003d encrypter.filter_factory({})"}],"source_content_type":"text/x-python","patch_set":5,"id":"bab6814e_02d44145","line":558,"updated":"2016-05-24 09:28:17.000000000","message":"use assertTrue","commit_id":"016d98709b17385ff2f1aeb91a9c24224b340a4f"},{"author":{"_account_id":12261,"name":"Mahati","email":"mahati.chamarthy@gmail.com","username":"Mahati"},"change_message_id":"3b2d26f4bdc435b8ff1bc05a6a71ad6181055046","unresolved":false,"context_lines":[{"line_number":552,"context_line":""},{"line_number":553,"context_line":"    def test_config_true_value_on_disable_encryption(self):"},{"line_number":554,"context_line":"        app \u003d FakeSwift()"},{"line_number":555,"context_line":"        self.assertFalse(encrypter.Encrypter(app, {}).disable_encryption)"},{"line_number":556,"context_line":"        for val in (\u0027true\u0027, \u00271\u0027, \u0027yes\u0027, \u0027on\u0027, \u0027t\u0027, \u0027y\u0027):"},{"line_number":557,"context_line":"            app \u003d encrypter.Encrypter(app,"},{"line_number":558,"context_line":"                                      {\u0027disable_encryption\u0027: val})"}],"source_content_type":"text/x-python","patch_set":6,"id":"bab6814e_0f638fde","line":555,"updated":"2016-05-25 08:18:14.000000000","message":"nice, thanks.","commit_id":"1a166b756e5d0ef88cf2957a87cba97da655bed9"}],"test/unit/common/middleware/test_encrypter_decrypter.py":[{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"5b2d3aa8fdf8ac8ce69f56383e651d0149ddb501","unresolved":false,"context_lines":[{"line_number":273,"context_line":"        self._check_listing(crypto_app, expect_mismatch\u003dFalse)"},{"line_number":274,"context_line":"        self._check_match_requests(\u0027GET\u0027, crypto_app)"},{"line_number":275,"context_line":"        self._check_match_requests(\u0027HEAD\u0027, crypto_app)"},{"line_number":276,"context_line":""},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"class TestCryptoPipelineChangesFastPost(TestCryptoPipelineChanges):"},{"line_number":279,"context_line":"    @classmethod"}],"source_content_type":"text/x-python","patch_set":2,"id":"dab17558_91528f11","line":276,"updated":"2016-05-17 08:57:09.000000000","message":"looks good","commit_id":"5818a46b83b24a86e67882480249f69c05045b8e"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"1f6dd1b0a99a5bdaa78ea3bec40793155b7b156f","unresolved":false,"context_lines":[{"line_number":239,"context_line":"        self._check_GET_and_HEAD_not_decrypted(self.proxy_app)"},{"line_number":240,"context_line":"        self._check_listing(self.proxy_app, expect_mismatch\u003dTrue)"},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"    def test_config_true_value_on_disable_encryption(self):"},{"line_number":243,"context_line":"        for val in (\u0027true\u0027, \u00271\u0027, \u0027yes\u0027, \u0027on\u0027, \u0027t\u0027, \u0027y\u0027):"},{"line_number":244,"context_line":"            app \u003d encrypter.Encrypter(self.proxy_app,"},{"line_number":245,"context_line":"                                      {\u0027disable_encryption\u0027: val})"}],"source_content_type":"text/x-python","patch_set":4,"id":"bab6814e_295e7ee9","line":242,"updated":"2016-05-18 15:30:29.000000000","message":"nit: I think this test would be better in test_encrypter.py since it does not rely on the test setup here","commit_id":"1fd7f4f0d36610ee644fc700d73eaed7e0c53cd3"},{"author":{"_account_id":12261,"name":"Mahati","email":"mahati.chamarthy@gmail.com","username":"Mahati"},"change_message_id":"9cc7274e5446c7dce056908a9785a564d76f552d","unresolved":false,"context_lines":[{"line_number":239,"context_line":"        self._check_GET_and_HEAD_not_decrypted(self.proxy_app)"},{"line_number":240,"context_line":"        self._check_listing(self.proxy_app, expect_mismatch\u003dTrue)"},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"    def test_config_true_value_on_disable_encryption(self):"},{"line_number":243,"context_line":"        for val in (\u0027true\u0027, \u00271\u0027, \u0027yes\u0027, \u0027on\u0027, \u0027t\u0027, \u0027y\u0027):"},{"line_number":244,"context_line":"            app \u003d encrypter.Encrypter(self.proxy_app,"},{"line_number":245,"context_line":"                                      {\u0027disable_encryption\u0027: val})"}],"source_content_type":"text/x-python","patch_set":4,"id":"bab6814e_11865413","line":242,"in_reply_to":"bab6814e_295e7ee9","updated":"2016-05-24 07:38:23.000000000","message":"Done","commit_id":"1fd7f4f0d36610ee644fc700d73eaed7e0c53cd3"}]}
