)]}'
{"keystonemiddleware/auth_token/__init__.py":[{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"b051c9a8cd67ac1bf1c0098f7e1c59672e6b93d6","unresolved":false,"context_lines":[{"line_number":849,"context_line":"            self.log.debug(\u0027Unexpected exception on token validation.\u0027,"},{"line_number":850,"context_line":"                           exc_info\u003dTrue)"},{"line_number":851,"context_line":"            self.log.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":852,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":853,"context_line":""},{"line_number":854,"context_line":"        return data"},{"line_number":855,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_7117f3ed","line":852,"updated":"2015-08-26 20:11:58.000000000","message":"This still raises an InvalidToken exception even though we know that the token isn\u0027t invalid? It seems like we should be raising something else here because it would still be misleading to the end user.","commit_id":"236e67c3fce26939a2750199ddaf3af6ed158b91"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"e9a4cad529be1ce27716d5c1c2f21671b58c9c9b","unresolved":false,"context_lines":[{"line_number":849,"context_line":"            self.log.debug(\u0027Unexpected exception on token validation.\u0027,"},{"line_number":850,"context_line":"                           exc_info\u003dTrue)"},{"line_number":851,"context_line":"            self.log.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":852,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":853,"context_line":""},{"line_number":854,"context_line":"        return data"},{"line_number":855,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_0c745a9a","line":852,"in_reply_to":"da20952f_7117f3ed","updated":"2015-08-26 20:37:26.000000000","message":"I hear you. But at least 3 questions before we go that route: 1) The same logic would apply for the ConnectionRefused and RequestTimeout cases, then, right? Reraise those instead of InvalidToken? 2) Users may break if we start throwing exceptions that were not possible here before. How concerned should we be about that? 3) We may run a greater risk of exposing information that should not have been exposed about why token validation failed. How concerned should we be about that?","commit_id":"236e67c3fce26939a2750199ddaf3af6ed158b91"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"a4d8522b8d569fdf55f09182b99a4e6fd283e092","unresolved":false,"context_lines":[{"line_number":501,"context_line":""},{"line_number":502,"context_line":"        :raises exc.InvalidToken: if token is rejected"},{"line_number":503,"context_line":"        \"\"\""},{"line_number":504,"context_line":"        # 0 seconds of validity means it is invalid right now"},{"line_number":505,"context_line":"        if auth_ref.will_expire_soon(stale_duration\u003d0):"},{"line_number":506,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":507,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_43ade92f","line":504,"updated":"2015-09-15 20:10:33.000000000","message":"put this in a separate commit since it\u0027s unrelated.","commit_id":"753477a383e12a427b479933dd9b76b5ff27050f"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"a4d8522b8d569fdf55f09182b99a4e6fd283e092","unresolved":false,"context_lines":[{"line_number":822,"context_line":"                data \u003d cached"},{"line_number":823,"context_line":""},{"line_number":824,"context_line":"                if self._check_revocations_for_cached:"},{"line_number":825,"context_line":"                    # A token might have been revoked, regardless of initial"},{"line_number":826,"context_line":"                    # mechanism used to validate it, and needs to be checked."},{"line_number":827,"context_line":"                    self._revocations.check(token_hashes)"},{"line_number":828,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_437409ce","line":825,"updated":"2015-09-15 20:10:33.000000000","message":"this clarification could also be done in a separate commit.","commit_id":"753477a383e12a427b479933dd9b76b5ff27050f"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"324cbb6ca5049679c3049be7d691029a1cb6388e","unresolved":false,"context_lines":[{"line_number":859,"context_line":"                self._token_cache.store_invalid(token_hashes[0])"},{"line_number":860,"context_line":"            self.log.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":861,"context_line":"            raise"},{"line_number":862,"context_line":"        except Exception:"},{"line_number":863,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token\u0027), exc_info\u003dTrue)"},{"line_number":864,"context_line":"            raise webob.exc.HTTPInternalServerError()"},{"line_number":865,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_719f9650","line":862,"updated":"2015-09-22 15:08:29.000000000","message":"This isn\u0027t tested at all.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"38f25efa984d9d1d145662ddb7e4b9252e0b002f","unresolved":false,"context_lines":[{"line_number":859,"context_line":"                self._token_cache.store_invalid(token_hashes[0])"},{"line_number":860,"context_line":"            self.log.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":861,"context_line":"            raise"},{"line_number":862,"context_line":"        except Exception:"},{"line_number":863,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token\u0027), exc_info\u003dTrue)"},{"line_number":864,"context_line":"            raise webob.exc.HTTPInternalServerError()"},{"line_number":865,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_a6889323","line":862,"in_reply_to":"ba15a1d1_719f9650","updated":"2015-09-22 16:11:13.000000000","message":"oh, but it is... see test_cached_revoked_error","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"5d633ad8d54b849a38e01a08ad798a79c6da48d4","unresolved":false,"context_lines":[{"line_number":859,"context_line":"                self._token_cache.store_invalid(token_hashes[0])"},{"line_number":860,"context_line":"            self.log.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":861,"context_line":"            raise"},{"line_number":862,"context_line":"        except Exception:"},{"line_number":863,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token\u0027), exc_info\u003dTrue)"},{"line_number":864,"context_line":"            raise webob.exc.HTTPInternalServerError()"},{"line_number":865,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_81f0abfe","line":862,"in_reply_to":"ba15a1d1_a6889323","updated":"2015-09-23 13:17:38.000000000","message":"Not according to the coverage report.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"f9ccfc6181dd4c01761d0eca070ee4641f6cddd6","unresolved":false,"context_lines":[{"line_number":859,"context_line":"                self._token_cache.store_invalid(token_hashes[0])"},{"line_number":860,"context_line":"            self.log.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":861,"context_line":"            raise"},{"line_number":862,"context_line":"        except Exception:"},{"line_number":863,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token\u0027), exc_info\u003dTrue)"},{"line_number":864,"context_line":"            raise webob.exc.HTTPInternalServerError()"},{"line_number":865,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_81798b84","line":862,"in_reply_to":"ba15a1d1_a6889323","updated":"2015-09-23 13:16:58.000000000","message":"nevermind... that results in RevocationListError, which I thought this block handled, but now I see/remember that that is handled in another block above. So I\u0027ll add a test for this.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"324cbb6ca5049679c3049be7d691029a1cb6388e","unresolved":false,"context_lines":[{"line_number":942,"context_line":"            return verified"},{"line_number":943,"context_line":"        # TypeError If the signed_text is not zlib compressed"},{"line_number":944,"context_line":"        # binascii.Error if signed_text has incorrect base64 padding (py34)"},{"line_number":945,"context_line":"        except (TypeError, binascii.Error):"},{"line_number":946,"context_line":"            raise exc.InvalidToken(signed_text)"},{"line_number":947,"context_line":""},{"line_number":948,"context_line":"    def _fetch_signing_cert(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_d1c78210","line":945,"updated":"2015-09-22 15:08:29.000000000","message":"This isn\u0027t tested.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"5d633ad8d54b849a38e01a08ad798a79c6da48d4","unresolved":false,"context_lines":[{"line_number":942,"context_line":"            return verified"},{"line_number":943,"context_line":"        # TypeError If the signed_text is not zlib compressed"},{"line_number":944,"context_line":"        # binascii.Error if signed_text has incorrect base64 padding (py34)"},{"line_number":945,"context_line":"        except (TypeError, binascii.Error):"},{"line_number":946,"context_line":"            raise exc.InvalidToken(signed_text)"},{"line_number":947,"context_line":""},{"line_number":948,"context_line":"    def _fetch_signing_cert(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_81c74b97","line":945,"in_reply_to":"ba15a1d1_9c127eb3","updated":"2015-09-23 13:17:38.000000000","message":"Ah, this only breaks on 3.4. Fair enough.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"38f25efa984d9d1d145662ddb7e4b9252e0b002f","unresolved":false,"context_lines":[{"line_number":942,"context_line":"            return verified"},{"line_number":943,"context_line":"        # TypeError If the signed_text is not zlib compressed"},{"line_number":944,"context_line":"        # binascii.Error if signed_text has incorrect base64 padding (py34)"},{"line_number":945,"context_line":"        except (TypeError, binascii.Error):"},{"line_number":946,"context_line":"            raise exc.InvalidToken(signed_text)"},{"line_number":947,"context_line":""},{"line_number":948,"context_line":"    def _fetch_signing_cert(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_9c127eb3","line":945,"in_reply_to":"ba15a1d1_d1c78210","updated":"2015-09-22 16:11:13.000000000","message":"actually it is. That\u0027s how I found that this was needed... test_request_invalid_signed_pkiz_token failed on py34 until I made this change.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"52e0837dda24ac85191839d1cc757625027d974e","unresolved":false,"context_lines":[{"line_number":852,"context_line":"        except (exceptions.ConnectionRefused, exceptions.RequestTimeout,"},{"line_number":853,"context_line":"                exc.RevocationListError, exc.ServiceError) as e:"},{"line_number":854,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token: %s\u0027), e)"},{"line_number":855,"context_line":"            raise webob.exc.HTTPServiceUnavailable()"},{"line_number":856,"context_line":"        except exc.InvalidToken:"},{"line_number":857,"context_line":"            self.log.debug(\u0027Token validation failure.\u0027, exc_info\u003dTrue)"},{"line_number":858,"context_line":"            if token_hashes:"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_8877ec01","line":855,"updated":"2015-09-25 00:12:52.000000000","message":"If anything i\u0027d love to see these moved to _identity where they might be raised, but not a problem for now.","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"c32a757e6211016345c258dcc872a68c763db905","unresolved":false,"context_lines":[{"line_number":852,"context_line":"        except (exceptions.ConnectionRefused, exceptions.RequestTimeout,"},{"line_number":853,"context_line":"                exc.RevocationListError, exc.ServiceError) as e:"},{"line_number":854,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token: %s\u0027), e)"},{"line_number":855,"context_line":"            raise webob.exc.HTTPServiceUnavailable()"},{"line_number":856,"context_line":"        except exc.InvalidToken:"},{"line_number":857,"context_line":"            self.log.debug(\u0027Token validation failure.\u0027, exc_info\u003dTrue)"},{"line_number":858,"context_line":"            if token_hashes:"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_c67e23ae","line":855,"in_reply_to":"9a1a9d01_8877ec01","updated":"2015-09-25 14:16:53.000000000","message":"ConnectionRefused and RequestTimeout could come from anywhere we try to talk to keystone, so while we could move this to _identity it would have to be duplicated there in numerous places, and there would be greater risk of missing a case.","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"52e0837dda24ac85191839d1cc757625027d974e","unresolved":false,"context_lines":[{"line_number":861,"context_line":"            raise"},{"line_number":862,"context_line":"        except Exception:"},{"line_number":863,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token\u0027), exc_info\u003dTrue)"},{"line_number":864,"context_line":"            raise webob.exc.HTTPInternalServerError()"},{"line_number":865,"context_line":""},{"line_number":866,"context_line":"        return data"},{"line_number":867,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_c8264416","line":864,"updated":"2015-09-25 00:12:52.000000000","message":"Let\u0027s remove this block.\n\nAny exception that makes it all the way to the top is going to cause a 500 error to be returned but also give us a useful traceback. Can we just let this fall through?","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"c32a757e6211016345c258dcc872a68c763db905","unresolved":false,"context_lines":[{"line_number":861,"context_line":"            raise"},{"line_number":862,"context_line":"        except Exception:"},{"line_number":863,"context_line":"            self.log.critical(_LC(\u0027Unable to validate token\u0027), exc_info\u003dTrue)"},{"line_number":864,"context_line":"            raise webob.exc.HTTPInternalServerError()"},{"line_number":865,"context_line":""},{"line_number":866,"context_line":"        return data"},{"line_number":867,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_4640d356","line":864,"in_reply_to":"9a1a9d01_c8264416","updated":"2015-09-25 14:16:53.000000000","message":"I tried removing this, and the UT wouldn\u0027t pass as currently written, because rather than see a 500 it just sees the exception. I assume call_middleware (used in the UT) happens at a lower level than where an exception would get turned into a 500. Not having delved into the higher levels of the callstack to see what else might go wrong to prevent that exception from turning into a 500, I kinda like that the UT is able to confirm the result is a 500, rather than change it to just check that an exception is raised. But I can remove this and then make the UT check for a specific exception getting through (e.g. ValueError) if others think that is best.","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"52e0837dda24ac85191839d1cc757625027d974e","unresolved":false,"context_lines":[{"line_number":942,"context_line":"            return verified"},{"line_number":943,"context_line":"        # TypeError If the signed_text is not zlib compressed"},{"line_number":944,"context_line":"        # binascii.Error if signed_text has incorrect base64 padding (py34)"},{"line_number":945,"context_line":"        except (TypeError, binascii.Error):"},{"line_number":946,"context_line":"            raise exc.InvalidToken(signed_text)"},{"line_number":947,"context_line":""},{"line_number":948,"context_line":"    def _fetch_signing_cert(self):"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_4860f435","line":945,"updated":"2015-09-25 00:12:52.000000000","message":"This is something we should fix on the keystoneclient side.","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"c32a757e6211016345c258dcc872a68c763db905","unresolved":false,"context_lines":[{"line_number":942,"context_line":"            return verified"},{"line_number":943,"context_line":"        # TypeError If the signed_text is not zlib compressed"},{"line_number":944,"context_line":"        # binascii.Error if signed_text has incorrect base64 padding (py34)"},{"line_number":945,"context_line":"        except (TypeError, binascii.Error):"},{"line_number":946,"context_line":"            raise exc.InvalidToken(signed_text)"},{"line_number":947,"context_line":""},{"line_number":948,"context_line":"    def _fetch_signing_cert(self):"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_c1312dee","line":945,"in_reply_to":"9a1a9d01_4860f435","updated":"2015-09-25 14:16:53.000000000","message":"And have it return a ValueError (or some new keystoneclient exception?) for both of these, rather than separate TypeError and binascii.Error? FYI, if anyone wants to see the full trace that caused me to add this, it\u0027s in the py34 jenkins results for patch set 4.","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"}],"keystonemiddleware/auth_token/_identity.py":[{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"a4d8522b8d569fdf55f09182b99a4e6fd283e092","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        try:"},{"line_number":213,"context_line":"            auth_ref \u003d self._request_strategy.verify_token(user_token)"},{"line_number":214,"context_line":"        except exceptions.NotFound as e:"},{"line_number":215,"context_line":"            self._LOG.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":216,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":217,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":218,"context_line":"        except exceptions.Unauthorized as e:"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_46ac17ed","line":215,"updated":"2015-09-15 20:10:33.000000000","message":"changing warn to warning is unrelated to the bug and should be in a separate commit.","commit_id":"753477a383e12a427b479933dd9b76b5ff27050f"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"324cbb6ca5049679c3049be7d691029a1cb6388e","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        try:"},{"line_number":213,"context_line":"            auth_ref \u003d self._request_strategy.verify_token(user_token)"},{"line_number":214,"context_line":"        except exceptions.NotFound as e:"},{"line_number":215,"context_line":"            self._LOG.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":216,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":217,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":218,"context_line":"        except exceptions.Unauthorized as e:"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_919fca02","line":215,"updated":"2015-09-22 15:08:29.000000000","message":"Unrelated changes?","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"38f25efa984d9d1d145662ddb7e4b9252e0b002f","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        try:"},{"line_number":213,"context_line":"            auth_ref \u003d self._request_strategy.verify_token(user_token)"},{"line_number":214,"context_line":"        except exceptions.NotFound as e:"},{"line_number":215,"context_line":"            self._LOG.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":216,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":217,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":218,"context_line":"        except exceptions.Unauthorized as e:"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_a63733af","line":215,"in_reply_to":"ba15a1d1_919fca02","updated":"2015-09-22 16:11:13.000000000","message":"No... see the commit message","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"5d633ad8d54b849a38e01a08ad798a79c6da48d4","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        try:"},{"line_number":213,"context_line":"            auth_ref \u003d self._request_strategy.verify_token(user_token)"},{"line_number":214,"context_line":"        except exceptions.NotFound as e:"},{"line_number":215,"context_line":"            self._LOG.warning(_LW(\u0027Authorization failed for token\u0027))"},{"line_number":216,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":217,"context_line":"            raise exc.InvalidToken(_(\u0027Token authorization failed\u0027))"},{"line_number":218,"context_line":"        except exceptions.Unauthorized as e:"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_61955785","line":215,"in_reply_to":"ba15a1d1_a63733af","updated":"2015-09-23 13:17:38.000000000","message":"It\u0027s still unrelated to the bug being fixed.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"324cbb6ca5049679c3049be7d691029a1cb6388e","unresolved":false,"context_lines":[{"line_number":220,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":221,"context_line":"            if retry:"},{"line_number":222,"context_line":"                self._LOG.info(_LI(\u0027Retrying validation\u0027))"},{"line_number":223,"context_line":"                return self.verify_token(user_token, False)"},{"line_number":224,"context_line":"        except exceptions.HttpError as e:"},{"line_number":225,"context_line":"            self._LOG.error("},{"line_number":226,"context_line":"                _LE(\u0027Bad response code while validating token: %s\u0027),"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_913b4aeb","line":223,"updated":"2015-09-22 15:08:29.000000000","message":"Should this be an invalid token too since the request is unauthorized and we won\u0027t retry it?","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"38f25efa984d9d1d145662ddb7e4b9252e0b002f","unresolved":false,"context_lines":[{"line_number":220,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":221,"context_line":"            if retry:"},{"line_number":222,"context_line":"                self._LOG.info(_LI(\u0027Retrying validation\u0027))"},{"line_number":223,"context_line":"                return self.verify_token(user_token, False)"},{"line_number":224,"context_line":"        except exceptions.HttpError as e:"},{"line_number":225,"context_line":"            self._LOG.error("},{"line_number":226,"context_line":"                _LE(\u0027Bad response code while validating token: %s\u0027),"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_e603ebb6","line":223,"in_reply_to":"ba15a1d1_639fcd03","updated":"2015-09-22 16:11:13.000000000","message":"right... failure to authenticate to keystone doesn\u0027t mean the token that I wanted to validate is invalid... I didn\u0027t get far enough to determine that.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"002b2290ec37663b2c67e6bb8a010135764390a4","unresolved":false,"context_lines":[{"line_number":220,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":221,"context_line":"            if retry:"},{"line_number":222,"context_line":"                self._LOG.info(_LI(\u0027Retrying validation\u0027))"},{"line_number":223,"context_line":"                return self.verify_token(user_token, False)"},{"line_number":224,"context_line":"        except exceptions.HttpError as e:"},{"line_number":225,"context_line":"            self._LOG.error("},{"line_number":226,"context_line":"                _LE(\u0027Bad response code while validating token: %s\u0027),"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_639fcd03","line":223,"in_reply_to":"ba15a1d1_913b4aeb","updated":"2015-09-22 15:20:45.000000000","message":"Just because keystone rejected the request due to bad password this time doesn\u0027t mean it\u0027s going to continue to reject it in the future. Maybe the password gets changed back or I update the password in auth_token.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"5d633ad8d54b849a38e01a08ad798a79c6da48d4","unresolved":false,"context_lines":[{"line_number":220,"context_line":"            self._LOG.warning(_LW(\u0027Identity response: %s\u0027), e.response.text)"},{"line_number":221,"context_line":"            if retry:"},{"line_number":222,"context_line":"                self._LOG.info(_LI(\u0027Retrying validation\u0027))"},{"line_number":223,"context_line":"                return self.verify_token(user_token, False)"},{"line_number":224,"context_line":"        except exceptions.HttpError as e:"},{"line_number":225,"context_line":"            self._LOG.error("},{"line_number":226,"context_line":"                _LE(\u0027Bad response code while validating token: %s\u0027),"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_c1754398","line":223,"in_reply_to":"ba15a1d1_e603ebb6","updated":"2015-09-23 13:17:38.000000000","message":"So it\u0027s a ServiceError?","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"324cbb6ca5049679c3049be7d691029a1cb6388e","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        else:"},{"line_number":230,"context_line":"            return auth_ref"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"        msg \u003d _(\u0027Failed to fetch token data from identity server\u0027)"},{"line_number":233,"context_line":"        raise exc.ServiceError(msg)"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def fetch_revocation_list(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_e3343ddf","line":232,"updated":"2015-09-22 15:08:29.000000000","message":"Maybe move these two lines up to 228?","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"92b7c9ff8bbecd26192454233cefda500fd8455c","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        else:"},{"line_number":230,"context_line":"            return auth_ref"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"        msg \u003d _(\u0027Failed to fetch token data from identity server\u0027)"},{"line_number":233,"context_line":"        raise exc.ServiceError(msg)"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def fetch_revocation_list(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_21ed1fb7","line":232,"in_reply_to":"ba15a1d1_21b43f33","updated":"2015-09-23 13:24:18.000000000","message":"I think some of the confusion is that this error message isn\u0027t great. For the Unauthorized case, it\u0027s really for the HttpError case.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"5d633ad8d54b849a38e01a08ad798a79c6da48d4","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        else:"},{"line_number":230,"context_line":"            return auth_ref"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"        msg \u003d _(\u0027Failed to fetch token data from identity server\u0027)"},{"line_number":233,"context_line":"        raise exc.ServiceError(msg)"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def fetch_revocation_list(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_21b43f33","line":232,"in_reply_to":"ba15a1d1_66dd9b41","updated":"2015-09-23 13:17:38.000000000","message":"There are only 2 that don\u0027t have an exit and if you really want the Unauthorized block to raise a SerivceError I\u0027d rather see it there too anyway. To me this looks like it\u0027s unintentionally falling through.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"38f25efa984d9d1d145662ddb7e4b9252e0b002f","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        else:"},{"line_number":230,"context_line":"            return auth_ref"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"        msg \u003d _(\u0027Failed to fetch token data from identity server\u0027)"},{"line_number":233,"context_line":"        raise exc.ServiceError(msg)"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def fetch_revocation_list(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba15a1d1_66dd9b41","line":232,"in_reply_to":"ba15a1d1_e3343ddf","updated":"2015-09-22 16:11:13.000000000","message":"No, because then they would need to be added to each except block, not just at 228. And were it desired, that would be cleanup unrelated to this bug.","commit_id":"7890e45d8b9904b8b2429daa1d49e6bf5b8fbaa2"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1c4621fb89e2ee52ea5575b254948aefc4ec6f14","unresolved":false,"context_lines":[{"line_number":221,"context_line":"            if retry:"},{"line_number":222,"context_line":"                self._LOG.info(_LI(\u0027Retrying validation\u0027))"},{"line_number":223,"context_line":"                return self.verify_token(user_token, False)"},{"line_number":224,"context_line":"            msg \u003d _(\u0027Identity server rejected authorization necessary to fetch\u0027"},{"line_number":225,"context_line":"                    \u0027token data\u0027)"},{"line_number":226,"context_line":"            raise exc.ServiceError(msg)"},{"line_number":227,"context_line":"        except exceptions.HttpError as e:"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_0ac84ba7","line":224,"updated":"2015-09-28 21:18:10.000000000","message":"there\u0027s a space missing between \"fetch\" and \"token\".","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"7070c156eb51c7eaba0fd16db28c46d616ac97d5","unresolved":false,"context_lines":[{"line_number":221,"context_line":"            if retry:"},{"line_number":222,"context_line":"                self._LOG.info(_LI(\u0027Retrying validation\u0027))"},{"line_number":223,"context_line":"                return self.verify_token(user_token, False)"},{"line_number":224,"context_line":"            msg \u003d _(\u0027Identity server rejected authorization necessary to fetch\u0027"},{"line_number":225,"context_line":"                    \u0027token data\u0027)"},{"line_number":226,"context_line":"            raise exc.ServiceError(msg)"},{"line_number":227,"context_line":"        except exceptions.HttpError as e:"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_aaecbff3","line":224,"in_reply_to":"9a1a9d01_0ac84ba7","updated":"2015-09-28 21:20:29.000000000","message":"Done","commit_id":"0ad2a56ef8812f5766787c5d16fc25b6bc1651a9"}],"keystonemiddleware/tests/unit/auth_token/test_auth_token_middleware.py":[{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"f9be3fa66f1b11d71ea97df523fbeda5eddba542","unresolved":false,"context_lines":[{"line_number":1541,"context_line":""},{"line_number":1542,"context_line":""},{"line_number":1543,"context_line":"def network_error_response(request, context):"},{"line_number":1544,"context_line":"    raise exceptions.ConnectionRefused(\"Network connection refused.\")"},{"line_number":1545,"context_line":""},{"line_number":1546,"context_line":""},{"line_number":1547,"context_line":"class v2AuthTokenMiddlewareTest(BaseAuthTokenMiddlewareTest,"}],"source_content_type":"text/x-python","patch_set":4,"id":"da20952f_3b17df55","line":1544,"updated":"2015-09-09 16:25:51.000000000","message":"this might have some conflict depending on the revert here - \nhttps://review.openstack.org/#/c/221855/","commit_id":"4457936d3ffd87c4f51944fbc38fe8d687b75d45"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"a4d8522b8d569fdf55f09182b99a4e6fd283e092","unresolved":false,"context_lines":[{"line_number":789,"context_line":"        # Cause the revocation list fetch to raise an error"},{"line_number":790,"context_line":"        def _fetch_with_error():"},{"line_number":791,"context_line":"            raise exc.RevocationListError()"},{"line_number":792,"context_line":"        self.middleware._revocations._fetch \u003d _fetch_with_error"},{"line_number":793,"context_line":""},{"line_number":794,"context_line":"        resp \u003d self.call_middleware(headers\u003d{\u0027X-Auth-Token\u0027: token})"},{"line_number":795,"context_line":"        self.assertEqual(503, resp.status_int)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_06529fdd","line":792,"updated":"2015-09-15 20:10:33.000000000","message":"using mock.patch.object would make this a little easier to follow.","commit_id":"753477a383e12a427b479933dd9b76b5ff27050f"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"a4d8522b8d569fdf55f09182b99a4e6fd283e092","unresolved":false,"context_lines":[{"line_number":2106,"context_line":"        }"},{"line_number":2107,"context_line":"        self.update_expected_env(expected_env)"},{"line_number":2108,"context_line":""},{"line_number":2109,"context_line":"        token \u003d \u0027invalid-token\u0027"},{"line_number":2110,"context_line":"        service_token \u003d \u0027invalid-service-token\u0027"},{"line_number":2111,"context_line":"        resp \u003d self.call_middleware(headers\u003d{\u0027X-Auth-Token\u0027: token,"},{"line_number":2112,"context_line":"                                             \u0027X-Service-Token\u0027: service_token})"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_e66d2b99","line":2109,"updated":"2015-09-15 20:10:33.000000000","message":"why was this changed? the reason for this change should be mentioned in the commit message.","commit_id":"753477a383e12a427b479933dd9b76b5ff27050f"}]}
