)]}'
{"keystone/credential/providers/core.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"f839c84f88d2842308d7aef131edc776cafdebec","unresolved":false,"context_lines":[{"line_number":24,"context_line":"        \"\"\"Encrypt a credential."},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"        :param str credential: credential to encrypt"},{"line_number":27,"context_line":"        :returns: encrypted credential str"},{"line_number":28,"context_line":"        \"\"\""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    @abc.abstractmethod"}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_f11e816e","line":27,"updated":"2016-08-17 19:09:06.000000000","message":"I was about to say this was ciphertext, but I guess it\u0027s more than that.\n\nBut this should also document raises keystone.exception.CredentialEncryptionError","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"d185d270e9187d17e53d1137eadd54fa7701a6a1","unresolved":false,"context_lines":[{"line_number":24,"context_line":"        \"\"\"Encrypt a credential."},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"        :param str credential: credential to encrypt"},{"line_number":27,"context_line":"        :returns: encrypted credential str"},{"line_number":28,"context_line":"        \"\"\""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    @abc.abstractmethod"}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_dc1a3c7c","line":27,"in_reply_to":"3ac371cc_f11e816e","updated":"2016-08-18 16:12:54.000000000","message":"Good catch, thanks!","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"90dd87b4e1eb57ed03d4db75d369599537cafc1d","unresolved":false,"context_lines":[{"line_number":32,"context_line":"        \"\"\"Decrypt a credential."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"        :param str credential: credential to decrypt"},{"line_number":35,"context_line":"        :returns: credential str as plaintext"},{"line_number":36,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_2dfd4ab4","line":35,"updated":"2016-08-18 04:56:01.000000000","message":"same as above, this can also raise CredentialEncryptionError","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"d185d270e9187d17e53d1137eadd54fa7701a6a1","unresolved":false,"context_lines":[{"line_number":32,"context_line":"        \"\"\"Decrypt a credential."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"        :param str credential: credential to decrypt"},{"line_number":35,"context_line":"        :returns: credential str as plaintext"},{"line_number":36,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_bc1dc074","line":35,"in_reply_to":"3ac371cc_2dfd4ab4","updated":"2016-08-18 16:12:54.000000000","message":"Done","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"bd93a0a7b5a346bb3fe3d604acadf8042caa012a","unresolved":false,"context_lines":[{"line_number":25,"context_line":""},{"line_number":26,"context_line":"        :param str credential: credential to encrypt"},{"line_number":27,"context_line":"        :returns: encrypted credential str"},{"line_number":28,"context_line":"        :raises: keystone.exception.CredentialEncryptionError"},{"line_number":29,"context_line":"        \"\"\""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    @abc.abstractmethod"}],"source_content_type":"text/x-python","patch_set":8,"id":"3ac371cc_9fc38438","line":28,"updated":"2016-08-18 20:52:17.000000000","message":"++","commit_id":"e10811cffd4738d9ef239492f020cf281018b7fa"}],"keystone/credential/providers/fernet/core.py":[{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"4e877a793f3ce6fa46b69295ef791c37fe68edd5","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                msg \u003d _(\u0027Credential could not be encrypted. Please contact the\u0027"},{"line_number":54,"context_line":"                        \u0027 administrator\u0027)"},{"line_number":55,"context_line":"                LOG.error(msg)"},{"line_number":56,"context_line":"                raise exception.CredentialEncryptionError(msg)"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def decrypt(self, credential):"},{"line_number":59,"context_line":"        \"\"\"Attempt to decrypt a credential."}],"source_content_type":"text/x-python","patch_set":1,"id":"9ad45d7e_a6cd8c5f","line":56,"range":{"start_line":56,"start_character":16,"end_line":56,"end_character":62},"updated":"2016-08-12 17:31:08.000000000","message":"I don\u0027t think this will work, there\u0027s no parameter for a passed in value here; https://review.openstack.org/#/c/354494/1/keystone/exception.py\n\nwe probably need to test the exceptions are raised","commit_id":"1bd7123d78ac206d35baa21f657382525f46937e"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"65938f44fe1ac06c7140729a839ff15acdef215a","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                msg \u003d _(\u0027Credential could not be encrypted. Please contact the\u0027"},{"line_number":54,"context_line":"                        \u0027 administrator\u0027)"},{"line_number":55,"context_line":"                LOG.error(msg)"},{"line_number":56,"context_line":"                raise exception.CredentialEncryptionError(msg)"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def decrypt(self, credential):"},{"line_number":59,"context_line":"        \"\"\"Attempt to decrypt a credential."}],"source_content_type":"text/x-python","patch_set":1,"id":"7ac969e8_293a29ce","line":56,"in_reply_to":"9ad45d7e_a6cd8c5f","updated":"2016-08-12 21:18:26.000000000","message":"The exceptions are tested here - https://review.openstack.org/#/c/354496/1/keystone/tests/unit/credential/test_fernet_provider.py","commit_id":"1bd7123d78ac206d35baa21f657382525f46937e"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"4e877a793f3ce6fa46b69295ef791c37fe68edd5","unresolved":false,"context_lines":[{"line_number":67,"context_line":"            if CONF.credential.allow_plaintext:"},{"line_number":68,"context_line":"                return credential"},{"line_number":69,"context_line":"            else:"},{"line_number":70,"context_line":"                msg \u003d _(\u0027Credential could not be decrypted. Please contact the\u0027"},{"line_number":71,"context_line":"                        \u0027 administrator\u0027)"},{"line_number":72,"context_line":"                LOG.error(msg)"},{"line_number":73,"context_line":"                raise exception.CredentialEncryptionError(msg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"9ad45d7e_a6d74cbe","line":71,"range":{"start_line":70,"start_character":0,"end_line":71,"end_character":41},"updated":"2016-08-12 17:31:08.000000000","message":"suggest going back to https://review.openstack.org/#/c/354494/1/keystone/exception.py and creating 2 specific exceptions here, and just raising them, forget passing in messages.","commit_id":"1bd7123d78ac206d35baa21f657382525f46937e"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"65938f44fe1ac06c7140729a839ff15acdef215a","unresolved":false,"context_lines":[{"line_number":68,"context_line":"                return credential"},{"line_number":69,"context_line":"            else:"},{"line_number":70,"context_line":"                msg \u003d _(\u0027Credential could not be decrypted. Please contact the\u0027"},{"line_number":71,"context_line":"                        \u0027 administrator\u0027)"},{"line_number":72,"context_line":"                LOG.error(msg)"},{"line_number":73,"context_line":"                raise exception.CredentialEncryptionError(msg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"7ac969e8_493165ec","line":71,"in_reply_to":"9ad45d7e_a6d74cbe","updated":"2016-08-12 21:18:26.000000000","message":"What about logging through? Do we do that in the exception class?","commit_id":"1bd7123d78ac206d35baa21f657382525f46937e"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"f839c84f88d2842308d7aef131edc776cafdebec","unresolved":false,"context_lines":[{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    def _get_encryption_keys(self):"},{"line_number":35,"context_line":"        self.key_utils \u003d fernet_utils.FernetUtils("},{"line_number":36,"context_line":"            CONF.credential.key_repository, 3"},{"line_number":37,"context_line":"        )"},{"line_number":38,"context_line":"        return self.key_utils.load_keys()"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_74671fe9","line":36,"updated":"2016-08-17 19:09:06.000000000","message":"3?\n\nThe rule of thumb for all arbitrary constants, especially numbers, is that if they\u0027re not 0 or 1, then they should come from a GLOBAL_CONSTANT with some documentation explaining why the chosen value is correct.","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"d185d270e9187d17e53d1137eadd54fa7701a6a1","unresolved":false,"context_lines":[{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    def _get_encryption_keys(self):"},{"line_number":35,"context_line":"        self.key_utils \u003d fernet_utils.FernetUtils("},{"line_number":36,"context_line":"            CONF.credential.key_repository, 3"},{"line_number":37,"context_line":"        )"},{"line_number":38,"context_line":"        return self.key_utils.load_keys()"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_f2847fd3","line":36,"in_reply_to":"3ac371cc_6d6c629c","updated":"2016-08-18 16:12:54.000000000","message":"Done","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"90dd87b4e1eb57ed03d4db75d369599537cafc1d","unresolved":false,"context_lines":[{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    def _get_encryption_keys(self):"},{"line_number":35,"context_line":"        self.key_utils \u003d fernet_utils.FernetUtils("},{"line_number":36,"context_line":"            CONF.credential.key_repository, 3"},{"line_number":37,"context_line":"        )"},{"line_number":38,"context_line":"        return self.key_utils.load_keys()"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_6d6c629c","line":36,"in_reply_to":"3ac371cc_74671fe9","updated":"2016-08-18 04:56:01.000000000","message":"++","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"}],"keystone/tests/unit/credential/test_fernet_provider.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"f839c84f88d2842308d7aef131edc776cafdebec","unresolved":false,"context_lines":[{"line_number":32,"context_line":"            ksfixtures.KeyRepository("},{"line_number":33,"context_line":"                self.config_fixture,"},{"line_number":34,"context_line":"                \u0027credential\u0027,"},{"line_number":35,"context_line":"                3"},{"line_number":36,"context_line":"            )"},{"line_number":37,"context_line":"        )"},{"line_number":38,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_f432efa5","line":35,"updated":"2016-08-17 19:09:06.000000000","message":"Should use the same GLOBAL_CONSTANT, I suppose.","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"d185d270e9187d17e53d1137eadd54fa7701a6a1","unresolved":false,"context_lines":[{"line_number":32,"context_line":"            ksfixtures.KeyRepository("},{"line_number":33,"context_line":"                self.config_fixture,"},{"line_number":34,"context_line":"                \u0027credential\u0027,"},{"line_number":35,"context_line":"                3"},{"line_number":36,"context_line":"            )"},{"line_number":37,"context_line":"        )"},{"line_number":38,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3ac371cc_9276eb03","line":35,"in_reply_to":"3ac371cc_f432efa5","updated":"2016-08-18 16:12:54.000000000","message":"Done","commit_id":"deeb8081e3063dfc42ba99539d7006587aed4278"}]}
