apisix icon indicating copy to clipboard operation
apisix copied to clipboard

docs: Supplements the openid-connect configuration doc

Open wensenz opened this issue 1 year ago • 8 comments

This configuration is used when token introspection endpoints require additional parameters

Description

Supplements the openid-connect configuration document

Checklist

  • [x] I have explained the need for this PR and the problem it solves
  • [x] I have explained the changes or the new features added to this PR
  • [x] I have added tests corresponding to this change
  • [x] I have updated the documentation to reflect this change
  • [x] I have verified that this change is backward compatible (If not, please discuss on the APISIX mailing list first)

wensenz avatar Jun 05 '24 03:06 wensenz

Will need to add this to the schema of apisix/plugins/openid-connect.lua as well and update the English doc.

Preferably add a test case.

kayx23 avatar Jun 05 '24 08:06 kayx23

Will need to add this to the schema of apisix/plugins/openid-connect.lua as well and update the English doc.

Preferably add a test case.

done..

wensenz avatar Jun 14 '24 06:06 wensenz

Will need to add this to the schema of apisix/plugins/openid-connect.lua as well and update the English doc. Preferably add a test case.

done..

schema is not updated? in apisix/plugins/openid-connect.lua

kayx23 avatar Jun 14 '24 07:06 kayx23

Will need to add this to the schema of apisix/plugins/openid-connect.lua as well and update the English doc. Preferably add a test case.

done..

schema is not updated? in apisix/plugins/openid-connect.lua

This is not necessary. In apisix/plugins/openid-connect.lua:413 -> lua-resty-openidc/lib/resty/openidc.lua:1740, the introspection_params is already supported.

wensenz avatar Jun 17 '24 10:06 wensenz

Configure the plugin like this, it works

"plugins": {
    "openid-connect": {
      "_meta": {
        "disable": false
      },
      "bearer_only": true,
      "client_id": "your client_id",
      "client_secret": "your client_secret",
      "discovery": "http://your host/.well-known/openid-configuration",
      "introspection_endpoint": "http://your host/api/login/oauth/introspect",
      "introspection_endpoint_auth_method": "client_secret_basic",
      "introspection_params": {
        "token_type_hint": "access_token"
      }
    }
  },

wensenz avatar Jun 17 '24 10:06 wensenz

Yes it will work; however introspection_params should still be added to the plugin schema. The other parameters supported by lua-resty-openidc and APISIX were also added to schema in the same way. @shreemaan-abhishek thoughts?

kayx23 avatar Jun 19 '24 02:06 kayx23

This pull request has been marked as stale due to 60 days of inactivity. It will be closed in 4 weeks if no further activity occurs. If you think that's incorrect or this pull request should instead be reviewed, please simply write any comment. Even if closed, you can still revive the PR at any time or discuss it on the [email protected] list. Thank you for your contributions.

github-actions[bot] avatar Aug 25 '24 10:08 github-actions[bot]

Yes it will work; however introspection_params should still be added to the plugin schema. The other parameters supported by lua-resty-openidc and APISIX were also added to schema in the same way. @shreemaan-abhishek thoughts?

+1 on this. The reason why it works is because the parameter is passed to the fundamental library.

juzhiyuan avatar Aug 25 '24 12:08 juzhiyuan

This pull request has been marked as stale due to 60 days of inactivity. It will be closed in 4 weeks if no further activity occurs. If you think that's incorrect or this pull request should instead be reviewed, please simply write any comment. Even if closed, you can still revive the PR at any time or discuss it on the [email protected] list. Thank you for your contributions.

github-actions[bot] avatar Dec 27 '24 10:12 github-actions[bot]

This pull request has been marked as stale due to 60 days of inactivity. It will be closed in 4 weeks if no further activity occurs. If you think that's incorrect or this pull request should instead be reviewed, please simply write any comment. Even if closed, you can still revive the PR at any time or discuss it on the [email protected] list. Thank you for your contributions.

github-actions[bot] avatar Mar 01 '25 10:03 github-actions[bot]

This pull request/issue has been closed due to lack of activity. If you think that is incorrect, or the pull request requires review, you can revive the PR at any time.

github-actions[bot] avatar Mar 30 '25 10:03 github-actions[bot]