mirror of
https://github.com/casdoor/casdoor.git
synced 2025-05-23 02:35:49 +08:00
feat: return "Active: false" for expired token in IntrospectToken() (#3714)
This commit is contained in:
parent
b3bafe8402
commit
c11f013e04
@ -334,6 +334,12 @@ func (c *ApiController) IntrospectToken() {
|
|||||||
c.ServeJSON()
|
c.ServeJSON()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if token.ExpiresIn <= 0 {
|
||||||
|
c.Data["json"] = &object.IntrospectionResponse{Active: false}
|
||||||
|
c.ServeJSON()
|
||||||
|
return
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var introspectionResponse object.IntrospectionResponse
|
var introspectionResponse object.IntrospectionResponse
|
||||||
|
Loading…
x
Reference in New Issue
Block a user