)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"85f36815fd23689510ab662638e6710053ed84b4","unresolved":false,"context_lines":[{"line_number":18,"context_line":"the global target is not defined in policy.json, per Oslo.policy, the \"default\""},{"line_number":19,"context_line":"rule will be used."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"bp/endpoint_enforcement"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Change-Id: Ic46395ae163ce322f288202dd7355bb68290d8ca"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":27,"id":"da20952f_b129a68b","line":21,"updated":"2015-09-03 14:03:25.000000000","message":"implements: bp endpoint-enforcement","commit_id":"6bee3ee639635eb817e84da3f06698cde43ff6c6"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"ebe4dfef9dbf6530a0798f79afcb11b37714737e","unresolved":false,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"The \"endpoint_url\" is configured in the auth_token middleware section. If"},{"line_number":18,"context_line":"the global target is not defined in policy.json, per Oslo.policy, the \"default\""},{"line_number":19,"context_line":"rule will be used."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"implements: bp endpoint-enforcement"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":28,"id":"9a1a9d01_2a3c34e1","line":19,"updated":"2015-09-28 19:38:59.000000000","message":"why is it ok to use the default policy? This doesn\u0027t seem safe. I wouldn\u0027t trust the services to have sane default policies, especially something that will work with this.","commit_id":"1a00d13dda4c0cfebd144ca238cba144e14f5db4"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f7753af7f2c61081aee2165d1e0be702228f14e9","unresolved":false,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"The \"endpoint_url\" is configured in the auth_token middleware section. If"},{"line_number":18,"context_line":"the global target is not defined in policy.json, per Oslo.policy, the \"default\""},{"line_number":19,"context_line":"rule will be used."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"implements: bp endpoint-enforcement"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":28,"id":"7a2fa921_d4a471a7","line":19,"in_reply_to":"9a1a9d01_2a3c34e1","updated":"2015-10-07 00:47:22.000000000","message":"That\u0027s how oslo.policy works today. If the target doesn\u0027t exist, the default rule kicks in.","commit_id":"1a00d13dda4c0cfebd144ca238cba144e14f5db4"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"543e6eab3c76fb488f6244a6bbbff727748adac8","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Enforce endpoint constraint based on a specific (oslo.policy) rule."},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"implements: bp endpoint-enforcement"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: Ic46395ae163ce322f288202dd7355bb68290d8ca"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":33,"id":"fa69d971_bb0d58ea","line":11,"range":{"start_line":11,"start_character":12,"end_line":11,"end_character":35},"updated":"2016-01-07 15:24:09.000000000","message":"This doesn\u0027t point to an existing blueprint.","commit_id":"db0f1646f9f43ade1df3911f103384fcbae75613"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"86d0dba48c256bd6d287930d79d86fc656f1b863","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Enforce endpoint constraint based on a specific (oslo.policy) rule."},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"implements: bp endpoint-enforcement"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: Ic46395ae163ce322f288202dd7355bb68290d8ca"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":33,"id":"fa69d971_a442693c","line":11,"range":{"start_line":11,"start_character":12,"end_line":11,"end_character":35},"in_reply_to":"fa69d971_bb0d58ea","updated":"2016-01-11 18:09:51.000000000","message":"good point! The spec was submitted awhile back.\n\nhttps://github.com/openstack/keystone-specs/blob/master/specs/keystonemiddleware/endpoint-enforcement-middleware.rst\n\nMaybe I need to create a BP as well?","commit_id":"db0f1646f9f43ade1df3911f103384fcbae75613"}],"keystonemiddleware/auth_token/__init__.py":[{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"c9d9a8375549303e23431431e0ef42d13c79663e","unresolved":false,"context_lines":[{"line_number":364,"context_line":"                \u0027 endpoint constraints.\u0027),"},{"line_number":365,"context_line":"    cfg.StrOpt(\u0027global_target_name\u0027, default\u003d\u0027global\u0027,"},{"line_number":366,"context_line":"               help\u003d\u0027The global target name to enforce. It may contain rules\u0027"},{"line_number":367,"context_line":"               \u0027 such as endpoint constraint.\u0027),"},{"line_number":368,"context_line":"    cfg.StrOpt(\u0027endpoint_id\u0027, default\u003dNone,"},{"line_number":369,"context_line":"               help\u003d\u0027The ID of the endpoint used for endpoint constraint\u0027"},{"line_number":370,"context_line":"               \u0027 enforcement.\u0027),"}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_93279fc9","line":367,"updated":"2015-06-09 22:40:35.000000000","message":"i don\u0027t like calling this global, it doesn\u0027t indicate where it\u0027s used. Prefer it called like keystonemiddleware.auth_token, maybe we just hardcode this instead of making it configurable?","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"9a9ba3a0c1ba8bf9940c7e98f24fcb1f0e0a5d85","unresolved":false,"context_lines":[{"line_number":364,"context_line":"                \u0027 endpoint constraints.\u0027),"},{"line_number":365,"context_line":"    cfg.StrOpt(\u0027global_target_name\u0027, default\u003d\u0027global\u0027,"},{"line_number":366,"context_line":"               help\u003d\u0027The global target name to enforce. It may contain rules\u0027"},{"line_number":367,"context_line":"               \u0027 such as endpoint constraint.\u0027),"},{"line_number":368,"context_line":"    cfg.StrOpt(\u0027endpoint_id\u0027, default\u003dNone,"},{"line_number":369,"context_line":"               help\u003d\u0027The ID of the endpoint used for endpoint constraint\u0027"},{"line_number":370,"context_line":"               \u0027 enforcement.\u0027),"}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_ff38a6d4","line":367,"in_reply_to":"3afb71cf_93279fc9","updated":"2015-06-10 20:15:55.000000000","message":"I originally had this as \"endpoint_constraint\", ayoung and morganfainberg want it to be more generic because we can expend it to include other policies as well. i.e.\n\n  \"global\": \"rule:endpoint_constraing and rule:kerberos_binding\",","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"c9d9a8375549303e23431431e0ef42d13c79663e","unresolved":false,"context_lines":[{"line_number":367,"context_line":"               \u0027 such as endpoint constraint.\u0027),"},{"line_number":368,"context_line":"    cfg.StrOpt(\u0027endpoint_id\u0027, default\u003dNone,"},{"line_number":369,"context_line":"               help\u003d\u0027The ID of the endpoint used for endpoint constraint\u0027"},{"line_number":370,"context_line":"               \u0027 enforcement.\u0027),"},{"line_number":371,"context_line":"]"},{"line_number":372,"context_line":""},{"line_number":373,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_b3a17b48","line":370,"updated":"2015-06-09 22:40:35.000000000","message":"i thought the point was to get endpoint_id and service_id out of the config options and use policy insted? Why wouldn\u0027t we just do it the old way if we have endpoint_id in config options. \n\nAt very least this needs to be called enforce_endpoint_id as before","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"9a9ba3a0c1ba8bf9940c7e98f24fcb1f0e0a5d85","unresolved":false,"context_lines":[{"line_number":367,"context_line":"               \u0027 such as endpoint constraint.\u0027),"},{"line_number":368,"context_line":"    cfg.StrOpt(\u0027endpoint_id\u0027, default\u003dNone,"},{"line_number":369,"context_line":"               help\u003d\u0027The ID of the endpoint used for endpoint constraint\u0027"},{"line_number":370,"context_line":"               \u0027 enforcement.\u0027),"},{"line_number":371,"context_line":"]"},{"line_number":372,"context_line":""},{"line_number":373,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_9fec122b","line":370,"in_reply_to":"3afb71cf_b3a17b48","updated":"2015-06-10 20:15:55.000000000","message":"endpoint_id can be specified in both ways. Directly in the rule itself or having it as a placeholder. We allow it here so that we can define a generic policy for multiple endpoints.","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"c9d9a8375549303e23431431e0ef42d13c79663e","unresolved":false,"context_lines":[{"line_number":562,"context_line":"            if not self._global_target_name:"},{"line_number":563,"context_line":"                msg \u003d _(\u0027global_target_name must be specified if \u0027"},{"line_number":564,"context_line":"                        \u0027enforce_global_target is set to True.\u0027)"},{"line_number":565,"context_line":"                raise exc.ConfigurationError(msg)"},{"line_number":566,"context_line":"            self._global_enforcer \u003d _global_target_enforcer.Enforcer("},{"line_number":567,"context_line":"                self._LOG, self._global_target_name)"},{"line_number":568,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_f3e373d7","line":565,"updated":"2015-06-09 22:40:35.000000000","message":"so what\u0027s the point of having two config options? why wouldn\u0027t this be enabled based on the presence of the global_target_name or endpoint_id or just always run it and if there is no rule defined we will fall through.","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"9a9ba3a0c1ba8bf9940c7e98f24fcb1f0e0a5d85","unresolved":false,"context_lines":[{"line_number":562,"context_line":"            if not self._global_target_name:"},{"line_number":563,"context_line":"                msg \u003d _(\u0027global_target_name must be specified if \u0027"},{"line_number":564,"context_line":"                        \u0027enforce_global_target is set to True.\u0027)"},{"line_number":565,"context_line":"                raise exc.ConfigurationError(msg)"},{"line_number":566,"context_line":"            self._global_enforcer \u003d _global_target_enforcer.Enforcer("},{"line_number":567,"context_line":"                self._LOG, self._global_target_name)"},{"line_number":568,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_9fe092ce","line":565,"in_reply_to":"3afb71cf_f3e373d7","updated":"2015-06-10 20:15:55.000000000","message":"Won\u0027t fall through because oslo.policy\u0027s default is to denied all. We want it to be explicit because bootstrap may be a multi-step process.\n\n  1. install the service bits, that includes policy.json\n  2. create the endpoint in keystone and lookup its id\n  3. reconfigure the service to enable global target enforcement\n\nAlso, with dynamic policy, a same policy may be shared by multiple endpoints and some endpoints (internal) may not need global target enforcement at all.\n\nTherefore, this feature should be independent of policies.","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"c9d9a8375549303e23431431e0ef42d13c79663e","unresolved":false,"context_lines":[{"line_number":834,"context_line":"            if self._enforce_global_target:"},{"line_number":835,"context_line":"                # enforce global target"},{"line_number":836,"context_line":"                target_dict \u003d {}"},{"line_number":837,"context_line":"                endpoint_id \u003d self._conf_get(\u0027endpoint_id\u0027)"},{"line_number":838,"context_line":"                if endpoint_id:"},{"line_number":839,"context_line":"                    target_dict \u003d {\u0027endpoint_id\u0027: endpoint_id}"},{"line_number":840,"context_line":"                self._global_enforcer.enforce(data,"}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_13be0f65","line":837,"updated":"2015-06-09 22:40:35.000000000","message":"you\u0027ve already fetched this in __init__, remove one or the other","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"9a9ba3a0c1ba8bf9940c7e98f24fcb1f0e0a5d85","unresolved":false,"context_lines":[{"line_number":834,"context_line":"            if self._enforce_global_target:"},{"line_number":835,"context_line":"                # enforce global target"},{"line_number":836,"context_line":"                target_dict \u003d {}"},{"line_number":837,"context_line":"                endpoint_id \u003d self._conf_get(\u0027endpoint_id\u0027)"},{"line_number":838,"context_line":"                if endpoint_id:"},{"line_number":839,"context_line":"                    target_dict \u003d {\u0027endpoint_id\u0027: endpoint_id}"},{"line_number":840,"context_line":"                self._global_enforcer.enforce(data,"}],"source_content_type":"text/x-python","patch_set":14,"id":"3afb71cf_dff16a96","line":837,"in_reply_to":"3afb71cf_13be0f65","updated":"2015-06-10 20:15:55.000000000","message":"ah, good one, I\u0027ll remove the global one.","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"4a806f74fc3379019cfd1708af3c431f806b961c","unresolved":false,"context_lines":[{"line_number":443,"context_line":"                 app,"},{"line_number":444,"context_line":"                 log\u003d_LOG,"},{"line_number":445,"context_line":"                 enforce_token_bind\u003d_BIND_MODE.PERMISSIVE,"},{"line_number":446,"context_line":"                 enforce_global_target\u003dFalse):"},{"line_number":447,"context_line":"        self.log \u003d log"},{"line_number":448,"context_line":"        self._app \u003d app"},{"line_number":449,"context_line":"        self._enforce_token_bind \u003d enforce_token_bind"}],"source_content_type":"text/x-python","patch_set":28,"id":"9a1a9d01_92fbf7c0","line":446,"updated":"2015-09-30 01:53:44.000000000","message":"I don\u0027t think we want this on base - at least not yet.","commit_id":"1a00d13dda4c0cfebd144ca238cba144e14f5db4"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"39ca0951549db2d3474a85ff107db2d313a2fd34","unresolved":false,"context_lines":[{"line_number":443,"context_line":"                 app,"},{"line_number":444,"context_line":"                 log\u003d_LOG,"},{"line_number":445,"context_line":"                 enforce_token_bind\u003d_BIND_MODE.PERMISSIVE,"},{"line_number":446,"context_line":"                 enforce_global_target\u003dFalse):"},{"line_number":447,"context_line":"        self.log \u003d log"},{"line_number":448,"context_line":"        self._app \u003d app"},{"line_number":449,"context_line":"        self._enforce_token_bind \u003d enforce_token_bind"}],"source_content_type":"text/x-python","patch_set":28,"id":"5a2ca52d_1bca3aa2","line":446,"in_reply_to":"7a2fa921_f49f2d4e","updated":"2015-10-14 01:52:43.000000000","message":"by that line of thinking shouldn\u0027t enforce_token_bind be in AuthProtocol as well?","commit_id":"1a00d13dda4c0cfebd144ca238cba144e14f5db4"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f7753af7f2c61081aee2165d1e0be702228f14e9","unresolved":false,"context_lines":[{"line_number":443,"context_line":"                 app,"},{"line_number":444,"context_line":"                 log\u003d_LOG,"},{"line_number":445,"context_line":"                 enforce_token_bind\u003d_BIND_MODE.PERMISSIVE,"},{"line_number":446,"context_line":"                 enforce_global_target\u003dFalse):"},{"line_number":447,"context_line":"        self.log \u003d log"},{"line_number":448,"context_line":"        self._app \u003d app"},{"line_number":449,"context_line":"        self._enforce_token_bind \u003d enforce_token_bind"}],"source_content_type":"text/x-python","patch_set":28,"id":"7a2fa921_f49f2d4e","line":446,"in_reply_to":"9a1a9d01_92fbf7c0","updated":"2015-10-07 00:47:22.000000000","message":"sure boss","commit_id":"1a00d13dda4c0cfebd144ca238cba144e14f5db4"},{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"727c9650214f8c50e3abe3e445d8794ac899826f","unresolved":false,"context_lines":[{"line_number":369,"context_line":"                \u0027 only while migrating from a less secure algorithm to a more\u0027"},{"line_number":370,"context_line":"                \u0027 secure one. Once all the old tokens are expired this option\u0027"},{"line_number":371,"context_line":"                \u0027 should be set to a single value for better performance.\u0027),"},{"line_number":372,"context_line":"    cfg.BoolOpt(\u0027enforce_endpoint_constraint\u0027, default\u003dFalse,"},{"line_number":373,"context_line":"                help\u003d\u0027If true, middleware will enforce endpoint constraint\u0027"},{"line_number":374,"context_line":"                \u0027 based on the configured (Oslo Policy) rule. Endpoint\u0027"},{"line_number":375,"context_line":"                \u0027 constraint rule is specified in the endpoint_constraint_rule\u0027"}],"source_content_type":"text/x-python","patch_set":30,"id":"da85f559_90a8f28e","line":372,"updated":"2015-11-10 19:46:35.000000000","message":"I don\u0027t know if we need a specific boolean here:  if there are not cosntraints, don\u0027t enforce anything?","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"af24d1d8bbb7fa8f80e0e4dad86cff6cc38c3efe","unresolved":false,"context_lines":[{"line_number":369,"context_line":"                \u0027 only while migrating from a less secure algorithm to a more\u0027"},{"line_number":370,"context_line":"                \u0027 secure one. Once all the old tokens are expired this option\u0027"},{"line_number":371,"context_line":"                \u0027 should be set to a single value for better performance.\u0027),"},{"line_number":372,"context_line":"    cfg.BoolOpt(\u0027enforce_endpoint_constraint\u0027, default\u003dFalse,"},{"line_number":373,"context_line":"                help\u003d\u0027If true, middleware will enforce endpoint constraint\u0027"},{"line_number":374,"context_line":"                \u0027 based on the configured (Oslo Policy) rule. Endpoint\u0027"},{"line_number":375,"context_line":"                \u0027 constraint rule is specified in the endpoint_constraint_rule\u0027"}],"source_content_type":"text/x-python","patch_set":30,"id":"7a740942_8763f519","line":372,"in_reply_to":"da85f559_90a8f28e","updated":"2015-12-12 00:01:27.000000000","message":"I agree. If the rule is not configured, that means endpoint constraint enforcement is disabled.","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"543e6eab3c76fb488f6244a6bbbff727748adac8","unresolved":false,"context_lines":[{"line_number":373,"context_line":"    cfg.StrOpt(\u0027endpoint_constraint_rule\u0027, default\u003dNone,"},{"line_number":374,"context_line":"               help\u003d\u0027An Oslo Policy rule for endpoint constraint. i.e.\u0027"},{"line_number":375,"context_line":"               \u0027 \"region_id:12345 or endpoint_id:23456\". If absent, no\u0027"},{"line_number":376,"context_line":"               \u0027 endpoint contraint enforcement will be performed.\u0027),"},{"line_number":377,"context_line":"]"},{"line_number":378,"context_line":""},{"line_number":379,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":33,"id":"fa69d971_fbd19030","line":376,"range":{"start_line":376,"start_character":26,"end_line":376,"end_character":35},"updated":"2016-01-07 15:24:09.000000000","message":"constraint*","commit_id":"db0f1646f9f43ade1df3911f103384fcbae75613"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"86d0dba48c256bd6d287930d79d86fc656f1b863","unresolved":false,"context_lines":[{"line_number":373,"context_line":"    cfg.StrOpt(\u0027endpoint_constraint_rule\u0027, default\u003dNone,"},{"line_number":374,"context_line":"               help\u003d\u0027An Oslo Policy rule for endpoint constraint. i.e.\u0027"},{"line_number":375,"context_line":"               \u0027 \"region_id:12345 or endpoint_id:23456\". If absent, no\u0027"},{"line_number":376,"context_line":"               \u0027 endpoint contraint enforcement will be performed.\u0027),"},{"line_number":377,"context_line":"]"},{"line_number":378,"context_line":""},{"line_number":379,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":33,"id":"fa69d971_641a3171","line":376,"range":{"start_line":376,"start_character":26,"end_line":376,"end_character":35},"in_reply_to":"fa69d971_fbd19030","updated":"2016-01-11 18:09:51.000000000","message":"done","commit_id":"db0f1646f9f43ade1df3911f103384fcbae75613"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"543e6eab3c76fb488f6244a6bbbff727748adac8","unresolved":false,"context_lines":[{"line_number":742,"context_line":"        self._token_cache.initialize(request.environ)"},{"line_number":743,"context_line":""},{"line_number":744,"context_line":"        # NOTE(gyee): ideally this should be in the same place as enforce"},{"line_number":745,"context_line":"        # token bind. We need to consolidate to have all the enforcements"},{"line_number":746,"context_line":"        # in one place."},{"line_number":747,"context_line":"        try:"},{"line_number":748,"context_line":"            self._endpoint_constraint_enforcement(request)"},{"line_number":749,"context_line":"        except ksm_exceptions.InvalidToken:"}],"source_content_type":"text/x-python","patch_set":33,"id":"fa69d971_7bcda085","line":746,"range":{"start_line":745,"start_character":22,"end_line":746,"end_character":23},"updated":"2016-01-07 15:24:09.000000000","message":"Is this documented somewhere besides this comment?","commit_id":"db0f1646f9f43ade1df3911f103384fcbae75613"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"86d0dba48c256bd6d287930d79d86fc656f1b863","unresolved":false,"context_lines":[{"line_number":742,"context_line":"        self._token_cache.initialize(request.environ)"},{"line_number":743,"context_line":""},{"line_number":744,"context_line":"        # NOTE(gyee): ideally this should be in the same place as enforce"},{"line_number":745,"context_line":"        # token bind. We need to consolidate to have all the enforcements"},{"line_number":746,"context_line":"        # in one place."},{"line_number":747,"context_line":"        try:"},{"line_number":748,"context_line":"            self._endpoint_constraint_enforcement(request)"},{"line_number":749,"context_line":"        except ksm_exceptions.InvalidToken:"}],"source_content_type":"text/x-python","patch_set":33,"id":"fa69d971_a414a943","line":746,"range":{"start_line":745,"start_character":22,"end_line":746,"end_character":23},"in_reply_to":"fa69d971_7bcda085","updated":"2016-01-11 18:09:51.000000000","message":"That was a suggestion from Jamie. Don\u0027t think it is officially documented. Middleware has been gone through rounds of refactoring lately and I am not sure if we are done yet.","commit_id":"db0f1646f9f43ade1df3911f103384fcbae75613"}],"keystonemiddleware/auth_token/_endpoint_constraint.py":[{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"727c9650214f8c50e3abe3e445d8794ac899826f","unresolved":false,"context_lines":[{"line_number":51,"context_line":"            service_name \u003d service.get(\u0027name\u0027)"},{"line_number":52,"context_line":"            for endpoint in service.get(\u0027endpoints\u0027, []):"},{"line_number":53,"context_line":"                match_endpoint \u003d endpoint.copy()"},{"line_number":54,"context_line":"                match_endpoint[\u0027endpoint_id\u0027] \u003d match_endpoint[\u0027id\u0027]"},{"line_number":55,"context_line":"                if service_id:"},{"line_number":56,"context_line":"                    match_endpoint[\u0027service_id\u0027] \u003d service_id"},{"line_number":57,"context_line":"                if service_type:"}],"source_content_type":"text/x-python","patch_set":30,"id":"da85f559_50292a36","line":54,"updated":"2015-11-10 19:46:35.000000000","message":"please add endpoint_url in here, and make it a list, so we can filter on multiple.  Endpoint_id should also be a list.","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"af24d1d8bbb7fa8f80e0e4dad86cff6cc38c3efe","unresolved":false,"context_lines":[{"line_number":51,"context_line":"            service_name \u003d service.get(\u0027name\u0027)"},{"line_number":52,"context_line":"            for endpoint in service.get(\u0027endpoints\u0027, []):"},{"line_number":53,"context_line":"                match_endpoint \u003d endpoint.copy()"},{"line_number":54,"context_line":"                match_endpoint[\u0027endpoint_id\u0027] \u003d match_endpoint[\u0027id\u0027]"},{"line_number":55,"context_line":"                if service_id:"},{"line_number":56,"context_line":"                    match_endpoint[\u0027service_id\u0027] \u003d service_id"},{"line_number":57,"context_line":"                if service_type:"}],"source_content_type":"text/x-python","patch_set":30,"id":"7a740942_cab90430","line":54,"in_reply_to":"da85f559_50292a36","updated":"2015-12-12 00:01:27.000000000","message":"done","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"}],"keystonemiddleware/auth_token/_global_target_enforcer.py":[{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"1ee9ef7d751906291dafda12b76bce59f4ccd359","unresolved":false,"context_lines":[{"line_number":13,"context_line":"from oslo_config import cfg"},{"line_number":14,"context_line":"from oslo_policy import policy"},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"from keystoneclient import access"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystonemiddleware.auth_token import _exceptions as exc"},{"line_number":19,"context_line":"from keystonemiddleware.i18n import _"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_c4c49560","line":16,"updated":"2015-06-16 19:07:37.000000000","message":"Why isn\u0027t this in the third-party section above?","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d7c40fd8fbf91fca4ec880c4a9f5d531e62fcd96","unresolved":false,"context_lines":[{"line_number":13,"context_line":"from oslo_config import cfg"},{"line_number":14,"context_line":"from oslo_policy import policy"},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"from keystoneclient import access"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystonemiddleware.auth_token import _exceptions as exc"},{"line_number":19,"context_line":"from keystonemiddleware.i18n import _"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_7901a804","line":16,"in_reply_to":"fa32b979_c4c49560","updated":"2015-06-17 01:29:32.000000000","message":"done","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"1ee9ef7d751906291dafda12b76bce59f4ccd359","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        self._global_target_name \u003d global_target_name"},{"line_number":31,"context_line":"        self._enforcer \u003d policy.Enforcer(CONF)"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"        self._LOG.debug(\u0027Enforcing global target: %s\u0027 % (global_target_name))"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    def enforce(self, token, target_dict\u003d{}):"},{"line_number":36,"context_line":"        # we only care about the service catalog so auth_token is not being"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_848c4d36","line":33,"updated":"2015-06-16 19:07:37.000000000","message":"Don\u0027t use the % operator here.","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d7c40fd8fbf91fca4ec880c4a9f5d531e62fcd96","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        self._global_target_name \u003d global_target_name"},{"line_number":31,"context_line":"        self._enforcer \u003d policy.Enforcer(CONF)"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"        self._LOG.debug(\u0027Enforcing global target: %s\u0027 % (global_target_name))"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    def enforce(self, token, target_dict\u003d{}):"},{"line_number":36,"context_line":"        # we only care about the service catalog so auth_token is not being"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_9906ec1b","line":33,"in_reply_to":"fa32b979_848c4d36","updated":"2015-06-17 01:29:32.000000000","message":"good catch!","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"1ee9ef7d751906291dafda12b76bce59f4ccd359","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":"        self._LOG.debug(\u0027Enforcing global target: %s\u0027 % (global_target_name))"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    def enforce(self, token, target_dict\u003d{}):"},{"line_number":36,"context_line":"        # we only care about the service catalog so auth_token is not being"},{"line_number":37,"context_line":"        # used"},{"line_number":38,"context_line":"        auth_ref \u003d access.AccessInfo.factory(body\u003dtoken, auth_token\u003d\u0027\u0027)"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_c4725549","line":35,"updated":"2015-06-16 19:07:37.000000000","message":"Dont use a mutable default arg.","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d7c40fd8fbf91fca4ec880c4a9f5d531e62fcd96","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":"        self._LOG.debug(\u0027Enforcing global target: %s\u0027 % (global_target_name))"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    def enforce(self, token, target_dict\u003d{}):"},{"line_number":36,"context_line":"        # we only care about the service catalog so auth_token is not being"},{"line_number":37,"context_line":"        # used"},{"line_number":38,"context_line":"        auth_ref \u003d access.AccessInfo.factory(body\u003dtoken, auth_token\u003d\u0027\u0027)"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_590ce43a","line":35,"in_reply_to":"fa32b979_c4725549","updated":"2015-06-17 01:29:32.000000000","message":"done","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"}],"keystonemiddleware/tests/unit/auth_token/test_auth_token_middleware.py":[{"author":{"_account_id":5638,"name":"Davanum Srinivas","email":"davanum@gmail.com","username":"dims-v"},"change_message_id":"9b14a6177c5da5e2428580c3228233f3e32b73ef","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        try:"},{"line_number":121,"context_line":"            import memcache"},{"line_number":122,"context_line":"            c \u003d memcache.Client(MEMCACHED_SERVERS)"},{"line_number":123,"context_line":"            c.set(\u0027ping\u0027, \u0027pong\u0027, time\u003d1)"},{"line_number":124,"context_line":"            MEMCACHED_AVAILABLE \u003d c.get(\u0027ping\u0027) \u003d\u003d \u0027pong\u0027"},{"line_number":125,"context_line":"        except ImportError:"},{"line_number":126,"context_line":"            MEMCACHED_AVAILABLE \u003d False"}],"source_content_type":"text/x-python","patch_set":23,"id":"9a41bdd9_4816d3f2","line":123,"updated":"2015-07-16 14:46:04.000000000","message":"This fails in the CI system because the VM has memcached running, So this piece of code actually runs and tries to connect to memcached. However there\u0027s a bug in python-memcached - https://github.com/linsomniac/python-memcached/issues/54 which causes the failure seen in CI.\n\nThis is easily recreatable on my laptop, i just ran memcached and ran \"python -m subunit.run discover -t ./ ./keystonemiddleware/tests --list\" from py34 venv","commit_id":"705347f1b1e21fd0744865ceb624214e0afbfb23"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f7e103a9011a37acb63abc44ed623065b249f4a3","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        try:"},{"line_number":121,"context_line":"            import memcache"},{"line_number":122,"context_line":"            c \u003d memcache.Client(MEMCACHED_SERVERS)"},{"line_number":123,"context_line":"            c.set(\u0027ping\u0027, \u0027pong\u0027, time\u003d1)"},{"line_number":124,"context_line":"            MEMCACHED_AVAILABLE \u003d c.get(\u0027ping\u0027) \u003d\u003d \u0027pong\u0027"},{"line_number":125,"context_line":"        except ImportError:"},{"line_number":126,"context_line":"            MEMCACHED_AVAILABLE \u003d False"}],"source_content_type":"text/x-python","patch_set":23,"id":"9a41bdd9_e8db2720","line":123,"in_reply_to":"9a41bdd9_4816d3f2","updated":"2015-07-16 14:49:12.000000000","message":"so is it just badluck that the VM had memcached installed and running, or will all our CI jobs have memcached from now on? \n\nif so, then we will have to make the py34 job non-voting until python-memcached it fixed and py3 friendly","commit_id":"705347f1b1e21fd0744865ceb624214e0afbfb23"},{"author":{"_account_id":6316,"name":"Anita Kuno","email":"anteaya@anteaya.info","username":"anteaya"},"change_message_id":"c1adb75cd3ea385bc1aa90b6961354573f7277bc","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        try:"},{"line_number":121,"context_line":"            import memcache"},{"line_number":122,"context_line":"            c \u003d memcache.Client(MEMCACHED_SERVERS)"},{"line_number":123,"context_line":"            c.set(\u0027ping\u0027, \u0027pong\u0027, time\u003d1)"},{"line_number":124,"context_line":"            MEMCACHED_AVAILABLE \u003d c.get(\u0027ping\u0027) \u003d\u003d \u0027pong\u0027"},{"line_number":125,"context_line":"        except ImportError:"},{"line_number":126,"context_line":"            MEMCACHED_AVAILABLE \u003d False"}],"source_content_type":"text/x-python","patch_set":23,"id":"9a41bdd9_f3023872","line":123,"in_reply_to":"9a41bdd9_e8db2720","updated":"2015-07-16 15:03:27.000000000","message":"We tend not to rely on luck for vm creation and environmental set-up for jobs.\n\nIf memcached is there we need to find out why. Then either figure out how to work with it needing to be there to suit someone else\u0027s job or remove it explicitly if another package drags it along.","commit_id":"705347f1b1e21fd0744865ceb624214e0afbfb23"}],"keystonemiddleware/tests/unit/auth_token/test_endpoint_constraint.py":[{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"16789dd64eda7a529668008d780567bb5d071474","unresolved":false,"context_lines":[{"line_number":207,"context_line":"        enforcer \u003d _endpoint_constraint.Enforcer(region_and_service_rule)"},{"line_number":208,"context_line":"        self.assertTrue(enforcer.enforce(self.token_data))"},{"line_number":209,"context_line":""},{"line_number":210,"context_line":"    def test_constraint_by_region_and_servicei_no_match(self):"},{"line_number":211,"context_line":"        region_rule \u003d \u0027token.catalog.endpoints.region:%s\u0027 % ("},{"line_number":212,"context_line":"            self.region)"},{"line_number":213,"context_line":"        # so bogus service which doesn\u0027t exist in the service catalog"}],"source_content_type":"text/x-python","patch_set":32,"id":"3a7e1126_c648868a","line":210,"updated":"2015-12-16 23:44:46.000000000","message":"drop the \u0027i\u0027  vi guy.","commit_id":"2d1d10adb8240a7f98368a736f9d4941a6ed51c3"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"c30b10511566f4fa53680ee76efc3f75e49fa9f2","unresolved":false,"context_lines":[{"line_number":207,"context_line":"        enforcer \u003d _endpoint_constraint.Enforcer(region_and_service_rule)"},{"line_number":208,"context_line":"        self.assertTrue(enforcer.enforce(self.token_data))"},{"line_number":209,"context_line":""},{"line_number":210,"context_line":"    def test_constraint_by_region_and_servicei_no_match(self):"},{"line_number":211,"context_line":"        region_rule \u003d \u0027token.catalog.endpoints.region:%s\u0027 % ("},{"line_number":212,"context_line":"            self.region)"},{"line_number":213,"context_line":"        # so bogus service which doesn\u0027t exist in the service catalog"}],"source_content_type":"text/x-python","patch_set":32,"id":"3a7e1126_53bbf30e","line":210,"in_reply_to":"3a7e1126_c648868a","updated":"2015-12-17 00:21:43.000000000","message":"Done","commit_id":"2d1d10adb8240a7f98368a736f9d4941a6ed51c3"}],"keystonemiddleware/tests/unit/auth_token/test_global_target_enforcer.py":[{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"6c16552bf9c382407529bfd19b20622e101f897e","unresolved":false,"context_lines":[{"line_number":105,"context_line":"        # should not raise InvalidToken exception here"},{"line_number":106,"context_line":"        self.enforcer.enforce(self.token)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    def test_endpoint_constraint_using_default_policy(self):"},{"line_number":109,"context_line":"        # make sure the \"default\" is used if the global target is"},{"line_number":110,"context_line":"        # not defined"},{"line_number":111,"context_line":"        self._reset_enforcer_with_new_policy("}],"source_content_type":"text/x-python","patch_set":14,"id":"5afe65bd_65ac94a0","line":108,"updated":"2015-06-03 21:04:29.000000000","message":"This is not correct.  Default policy will be used later for individual line items.\n\nIf there is no rule that explicitly matches, it should be an error, as this is getting activated by a config file option.","commit_id":"8a3d3ecff57ea12c6e4a8116fc614eac0058b43a"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"1ee9ef7d751906291dafda12b76bce59f4ccd359","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright 2015"},{"line_number":2,"context_line":"#"},{"line_number":3,"context_line":"#   Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":4,"context_line":"#   not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_04c7dd45","line":1,"updated":"2015-06-16 19:07:37.000000000","message":"Incomplete? Feel free to remove :-)","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d7c40fd8fbf91fca4ec880c4a9f5d531e62fcd96","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright 2015"},{"line_number":2,"context_line":"#"},{"line_number":3,"context_line":"#   Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":4,"context_line":"#   not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_992d8c97","line":1,"in_reply_to":"fa32b979_04c7dd45","updated":"2015-06-17 01:29:32.000000000","message":":)\n\nI\u0027ll remove.","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"1ee9ef7d751906291dafda12b76bce59f4ccd359","unresolved":false,"context_lines":[{"line_number":13,"context_line":"#   under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import logging"},{"line_number":16,"context_line":"import testtools"},{"line_number":17,"context_line":"import uuid"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from keystoneclient import fixture"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_44eba5b0","line":16,"updated":"2015-06-16 19:07:37.000000000","message":"testtools is third-party","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d7c40fd8fbf91fca4ec880c4a9f5d531e62fcd96","unresolved":false,"context_lines":[{"line_number":13,"context_line":"#   under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import logging"},{"line_number":16,"context_line":"import testtools"},{"line_number":17,"context_line":"import uuid"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from keystoneclient import fixture"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_592384a7","line":16,"in_reply_to":"fa32b979_44eba5b0","updated":"2015-06-17 01:29:32.000000000","message":"Done","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"85f36815fd23689510ab662638e6710053ed84b4","unresolved":false,"context_lines":[{"line_number":72,"context_line":"                                        admin\u003durl,"},{"line_number":73,"context_line":"                                        region\u003dregion)"},{"line_number":74,"context_line":"        # TODO(gyee): need to add the id for now, till this patch lands"},{"line_number":75,"context_line":"        # https://review.openstack.org/#/c/174668/"},{"line_number":76,"context_line":"        endpoint[\u0027id\u0027] \u003d endpoint_id"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    def _generate_token(self):"}],"source_content_type":"text/x-python","patch_set":27,"id":"da20952f_f0be3dfe","line":75,"updated":"2015-09-03 14:03:25.000000000","message":"these comments here could be cleaned up?","commit_id":"6bee3ee639635eb817e84da3f06698cde43ff6c6"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"85f36815fd23689510ab662638e6710053ed84b4","unresolved":false,"context_lines":[{"line_number":160,"context_line":""},{"line_number":161,"context_line":"    def test_no_service_catalog(self):"},{"line_number":162,"context_line":"        del self.token[\u0027serviceCatalog\u0027]"},{"line_number":163,"context_line":"        # this should yield ConfigurationError as token has no service catalog"},{"line_number":164,"context_line":"        self.assertRaises(exc.InvalidToken,"},{"line_number":165,"context_line":"                          self.enforcer.enforce,"},{"line_number":166,"context_line":"                          self.token)"}],"source_content_type":"text/x-python","patch_set":27,"id":"da20952f_90f6e1f7","line":163,"updated":"2015-09-03 14:03:25.000000000","message":"typo? it\u0027s not raise exc.InvalidToken?","commit_id":"6bee3ee639635eb817e84da3f06698cde43ff6c6"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"85f36815fd23689510ab662638e6710053ed84b4","unresolved":false,"context_lines":[{"line_number":178,"context_line":"    \"\"\"Test endpoint constraint enforcement for V3 tokens\"\"\""},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"    def _add_endpoint(self, service, endpoint_id, region, url\u003dNone):"},{"line_number":181,"context_line":"        # NOTE(gyee): keystoneclient.fixture _Service.add_endpoint() args"},{"line_number":182,"context_line":"        # are different, depending on token version. I really really really"},{"line_number":183,"context_line":"        # wish the interface is token agnostic so we don\u0027t have to do this."},{"line_number":184,"context_line":"        url \u003d url or \u0027https://host:35357\u0027"}],"source_content_type":"text/x-python","patch_set":27,"id":"da20952f_2b50c35d","line":181,"updated":"2015-09-03 14:03:25.000000000","message":"keystoneclient.fixture._Service.add_endpoint(), miss the \u0027.\u0027 before _Service.","commit_id":"6bee3ee639635eb817e84da3f06698cde43ff6c6"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"85f36815fd23689510ab662638e6710053ed84b4","unresolved":false,"context_lines":[{"line_number":185,"context_line":"        endpoint \u003d service.add_endpoint(\u0027public\u0027, url,"},{"line_number":186,"context_line":"                                        region\u003dregion)"},{"line_number":187,"context_line":"        # TODO(gyee): need to add the id for now, till this patch lands"},{"line_number":188,"context_line":"        # https://review.openstack.org/#/c/174668/"},{"line_number":189,"context_line":"        endpoint[\u0027id\u0027] \u003d endpoint_id"},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"    def _generate_token(self):"}],"source_content_type":"text/x-python","patch_set":27,"id":"da20952f_abf1336c","line":188,"updated":"2015-09-03 14:03:25.000000000","message":"I think all of these could be cleaned.","commit_id":"6bee3ee639635eb817e84da3f06698cde43ff6c6"}],"keystonemiddleware/tests/unit/utils.py":[{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"1ee9ef7d751906291dafda12b76bce59f4ccd359","unresolved":false,"context_lines":[{"line_number":146,"context_line":"    def setUp(self):"},{"line_number":147,"context_line":"        super(SecureTempFile, self).setUp()"},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"        _fd, self.file_name \u003d tempfile.mkstemp()"},{"line_number":150,"context_line":"        # Make sure no file descriptors are leaked, close the unused FD."},{"line_number":151,"context_line":"        os.close(_fd)"},{"line_number":152,"context_line":"        self.addCleanup(os.remove, self.file_name)"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_a44ab1c3","line":149,"updated":"2015-06-16 19:07:37.000000000","message":"(nit) I don\u0027t think you need to keep file_name as an instance variable at all","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d7c40fd8fbf91fca4ec880c4a9f5d531e62fcd96","unresolved":false,"context_lines":[{"line_number":146,"context_line":"    def setUp(self):"},{"line_number":147,"context_line":"        super(SecureTempFile, self).setUp()"},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"        _fd, self.file_name \u003d tempfile.mkstemp()"},{"line_number":150,"context_line":"        # Make sure no file descriptors are leaked, close the unused FD."},{"line_number":151,"context_line":"        os.close(_fd)"},{"line_number":152,"context_line":"        self.addCleanup(os.remove, self.file_name)"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa32b979_a704e817","line":149,"in_reply_to":"fa32b979_a44ab1c3","updated":"2015-06-17 01:29:32.000000000","message":"not sure if I understand the comment. We need to pass self.file_name to addCleanup() in line 152.","commit_id":"91534f6c1ddcffff29795423171c1ac2128e00de"},{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"727c9650214f8c50e3abe3e445d8794ac899826f","unresolved":false,"context_lines":[{"line_number":152,"context_line":"            raise ImportError"},{"line_number":153,"context_line":""},{"line_number":154,"context_line":""},{"line_number":155,"context_line":"class SecureTempFile(fixtures.Fixture):"},{"line_number":156,"context_line":"    \"\"\"A fixture for creating a secure temp file.\"\"\""},{"line_number":157,"context_line":""},{"line_number":158,"context_line":"    def setUp(self):"}],"source_content_type":"text/x-python","patch_set":30,"id":"da85f559_95c304ed","line":155,"updated":"2015-11-10 19:46:35.000000000","message":"Suspect you don\u0027t need this now.","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"af24d1d8bbb7fa8f80e0e4dad86cff6cc38c3efe","unresolved":false,"context_lines":[{"line_number":152,"context_line":"            raise ImportError"},{"line_number":153,"context_line":""},{"line_number":154,"context_line":""},{"line_number":155,"context_line":"class SecureTempFile(fixtures.Fixture):"},{"line_number":156,"context_line":"    \"\"\"A fixture for creating a secure temp file.\"\"\""},{"line_number":157,"context_line":""},{"line_number":158,"context_line":"    def setUp(self):"}],"source_content_type":"text/x-python","patch_set":30,"id":"7a740942_c7fc9d40","line":155,"in_reply_to":"da85f559_95c304ed","updated":"2015-12-12 00:01:27.000000000","message":"you\u0027re right. We don\u0027t need temp file mechanism anymore.","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"}],"requirements.txt":[{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"727c9650214f8c50e3abe3e445d8794ac899826f","unresolved":false,"context_lines":[{"line_number":6,"context_line":"oslo.config\u003e\u003d2.6.0 # Apache-2.0"},{"line_number":7,"context_line":"oslo.context\u003e\u003d0.2.0 # Apache-2.0"},{"line_number":8,"context_line":"oslo.i18n\u003e\u003d1.5.0 # Apache-2.0"},{"line_number":9,"context_line":"oslo.policy\u003e\u003d0.5.0 # Apache-2.0"},{"line_number":10,"context_line":"oslo.serialization\u003e\u003d1.10.0 # Apache-2.0"},{"line_number":11,"context_line":"oslo.utils!\u003d2.6.0,\u003e\u003d2.4.0 # Apache-2.0"},{"line_number":12,"context_line":"pbr\u003e\u003d1.6"}],"source_content_type":"text/plain","patch_set":30,"id":"da85f559_75622040","line":9,"updated":"2015-11-10 19:46:35.000000000","message":"Do you need this anymore?","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"af24d1d8bbb7fa8f80e0e4dad86cff6cc38c3efe","unresolved":false,"context_lines":[{"line_number":6,"context_line":"oslo.config\u003e\u003d2.6.0 # Apache-2.0"},{"line_number":7,"context_line":"oslo.context\u003e\u003d0.2.0 # Apache-2.0"},{"line_number":8,"context_line":"oslo.i18n\u003e\u003d1.5.0 # Apache-2.0"},{"line_number":9,"context_line":"oslo.policy\u003e\u003d0.5.0 # Apache-2.0"},{"line_number":10,"context_line":"oslo.serialization\u003e\u003d1.10.0 # Apache-2.0"},{"line_number":11,"context_line":"oslo.utils!\u003d2.6.0,\u003e\u003d2.4.0 # Apache-2.0"},{"line_number":12,"context_line":"pbr\u003e\u003d1.6"}],"source_content_type":"text/plain","patch_set":30,"id":"7a740942_e78e79cf","line":9,"in_reply_to":"da85f559_75622040","updated":"2015-12-12 00:01:27.000000000","message":"Yes, We still need this as using Oslo policy to enforce to rule is very flexible.","commit_id":"967a806aa18dfe14b1d084fd2a5b0bd1d0764e04"}]}
