spacewander commented on a change in pull request #4099:
URL: https://github.com/apache/apisix/pull/4099#discussion_r617991536
##########
File path: apisix/plugins/jwt-auth.lua
##########
@@ -277,18 +285,44 @@ function _M.rewrite(conf, ctx)
if not consumer then
return 401, {message = "Invalid user key in JWT token"}
end
- core.log.info("consumer: ", core.json.delay_encode(consumer))
+ log.info("consumer: ", core.json.delay_encode(consumer))
local _, auth_secret = algorithm_handler(consumer)
jwt_obj = jwt:verify_jwt_obj(auth_secret, jwt_obj)
- core.log.info("jwt object: ", core.json.delay_encode(jwt_obj))
+ log.info("jwt object: ", core.json.delay_encode(jwt_obj))
if not jwt_obj.verified then
return 401, {message = jwt_obj.reason}
end
consumer_mod.attach_consumer(ctx, consumer, consumer_conf)
- core.log.info("hit jwt-auth rewrite")
+ log.info("hit jwt-auth rewrite")
+end
+
+
+local function user_info()
Review comment:
This feature can be implemented as a local script to check.
There is no need to expose it as a public API of the gateway.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]