authz-casdoor

NOTE: encrypt_fields = {"client_secret"} is also defined in the schema, which means that the field will be stored encrypted in etcd. See encrypted storage fields.

IMPORTANT

endpoint_addr and callback_url should not end with ‘/‘.

authz-casdoor - 图2IMPORTANT

You can enable the Plugin on a specific Route as shown below:

Once you have enabled the Plugin, a new user visiting this Route would first be processed by the authz-casdoor Plugin. They would be redirected to the login page of Casdoor.

Once this is done, the user is redirected to the original URL they wanted to visit.

To disable the authz-casdoor Plugin, you can delete the corresponding JSON configuration from the Plugin configuration. APISIX will automatically reload and you do not have to restart for this to take effect.

  1. curl http://127.0.0.1:9180/apisix/admin/routes/1 -H 'X-API-KEY: edd1c9f034335f136f87ad84b625c8f1' -X PUT -d '
  2. {
  3. "methods": ["GET"],
  4. "uri": "/anything/*",
  5. "upstream": {
  6. "type": "roundrobin",
  7. "nodes": {
  8. "httpbin.org:80": 1
  9. }