idbeta commented on issue #716:
URL:
https://github.com/apache/apisix-dashboard/issues/716#issuecomment-723419143
@membphis I create a consumer again, and it returns 500 when I generate JWT
credential, what I do was exactly the same as before.
etcd data
```
/apisix/consumers/test_hj
{"id":"test_hj","create_time":1604737871,"update_time":1604737871,"username":"test_hj","plugins":{"jwt-auth":{"algorithm":"HS256","base64_secret":false,"key":"dd","secret":"my-secret-key"}}}
```
error.log
```
2020/11/07 16:41:07 [error] 84990#1547973: *120907 lua entry thread aborted:
runtime error: /Users/idbeta/1106/apisix-2.0/apisix/plugins/jwt-auth.lua:218:
attempt to perform arithmetic on field 'exp' (a nil value)
stack traceback:
coroutine 0:
/Users/idbeta/1106/apisix-2.0/apisix/plugins/jwt-auth.lua: in function
'handler'
/Users/idbeta/1106/apisix-2.0/apisix/api_router.lua:107: in function
'handler'
.../1106/apisix-2.0//deps/share/lua/5.1/resty/radixtree.lua:730: in
function 'dispatch'
/Users/idbeta/1106/apisix-2.0/apisix/api_router.lua:133: in function
'match'
/Users/idbeta/1106/apisix-2.0/apisix/init.lua:373: in function
'http_access_phase'
access_by_lua(nginx.conf:173):2: in main chunk, client: 127.0.0.1,
server: , request: "GET /apisix/plugin/jwt/sign?key=dd HTTP/1.1", host:
"127.0.0.1:9080"
```
----------------------------------------------------------------
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]