Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: OAuth provider support #1010

Merged
merged 56 commits into from
Oct 4, 2024
Merged

feat: OAuth provider support #1010

merged 56 commits into from
Oct 4, 2024

Conversation

rishabhpoddar
Copy link
Contributor

@rishabhpoddar rishabhpoddar commented Jul 8, 2024

Summary of change

Adds oauth provider feature

Related issues

Test Plan

TODO

Documentation changes

TODO

Checklist for important updates

  • Changelog has been updated
    • If there are any db schema changes, mention those changes clearly
  • coreDriverInterfaceSupported.json file has been updated (if needed)
  • pluginInterfaceSupported.json file has been updated (if needed)
  • Changes to the version if needed
    • In build.gradle
  • If added a new paid feature, edit the getPaidFeatureStats function in FeatureFlag.java file
  • Had installed and ran the pre-commit hook
  • If there are new dependencies that have been added in build.gradle, please make sure to add them
    in implementationDependencies.json.
  • Update function getValidFields in io/supertokens/config/CoreConfig.java if new aliases were added for any core config (similar to the access_token_signing_key_update_interval config alias).
  • Issue this PR against the latest non released version branch.
    • To know which one it is, run find the latest released tag (git tag) in the format vX.Y.Z, and then find the
      latest branch (git branch --all) whose X.Y is greater than the latest released tag.
    • If no such branch exists, then create one from the latest released branch.
  • If added a foreign key constraint on app_id_to_user_id table, make sure to delete from this table when deleting the user as well if deleteUserIdMappingToo is false.

Remaining TODOs for this PR

  • license key should have "oauth" in it.
  • https://supertokens.slack.com/archives/D02B887A2MQ/p1719875078076949
  • check license key fro oauth in the apis
  • in authorization get, check that state is at least 8 chars long
  • Enforce in config check that the oauth urls dont have any path, and normalise them. We check that they are valid urls, but do not require them to not have paths
  • Oauth stuff is to be per app config, and not config yaml config. Cause we should be able to modify app config on the fly without restarting the core for a user. But this config should not be visible in the dashboard.
  • Add tests for new function to make PATCH API calls (new HttpRequest function is added)

@sattvikc sattvikc changed the base branch from 9.1 to 9.2 August 20, 2024 07:43
@sattvikc sattvikc changed the base branch from 9.2 to 9.1 August 20, 2024 07:44
@sattvikc sattvikc changed the base branch from 9.1 to 9.2 August 20, 2024 07:44
@sattvikc sattvikc self-assigned this Aug 20, 2024
sattvikc and others added 6 commits September 25, 2024 16:12
* fix: auth and token api

* fix: cookie and code transformations

* fix: token re-signing

* fix: token endpoint

* fix: license check and jwks caching

* fix: exceptions

* fix: refactor

* fix: refactor

* fix: refactor and client crud APIs

* fix: token type enum

* fix: process ext only on access token

* fix: refactor

* fix: bugs and refactor

* fix: oauth clients list api

* fix: consent get accept and reject

* fix: login request

* fix: query param transformation

* fix: logout request

* fix: refactor

* fix: remove error debug and hint

* fix: introspect api

* fix: pr comments

* fix: pr comments

* fix: pr comment

* fix: pr comment

* fix: pr comments and refactor

* fix: pr comments

* fix: pr comments

* fix: revert original http request

* fix: pr comment refactor

* fix: pr comment

* fix: pr comment

* fix: pr comment

* fix: pr comments

* fix: owner and pagination

* fix: pr comment

* fix: client id check

* fix: ext related

* fix: pr comment

* fix: revoke APIs (#1041)

* fix: revoke consent sessions

* fix: revoke token

* fix: revoke impl

* fix: revoke session

* fix: introspect impl after revoke

* fix: revoke by client_id

* fix: refresh token check in token exchange

* fix: at hash

* fix: sqlite impl

* fix: client props whitelist

* fix: status and query null check

* fix: plugin interface update

* fix: logout api

* fix: ext

* fix: accept consent

* fix: accept consent

* fix: introspect in token api

* fix: keep fragment while updating query params

* fix: count creds and pr comment

* fix: oauth stats

* fix: oauth cleanup cron task

* fix: gid in refresh token

* fix: inememory impl

* feat: add initial payload fields to accept consent

* fix: revoke cleanup

* fix: stats

* fix: client credentials basic

* fix: authorization header

* fix: authorizaion header in revoke

* fix: missing table

---------

Co-authored-by: Mihaly Lengyel <[email protected]>

---------

Co-authored-by: Mihaly Lengyel <[email protected]>
* fix: logout apis

* fix: session revoke in logout

* fix: tests

* feat: update logout logic to make BE integration easier

* refactor: minor fixes for consistency

---------

Co-authored-by: Mihaly Lengyel <[email protected]>
* fix: logout apis

* fix: session revoke in logout

* fix: tests

* fix: tests

* fix: tests

* fix: tests
@sattvikc sattvikc changed the base branch from 9.2 to 9.3 October 2, 2024 10:07
@sattvikc sattvikc changed the title Feat: oauth provider (base pr) feat: OAuth provider support Oct 2, 2024
@sattvikc sattvikc marked this pull request as ready for review October 2, 2024 10:08
@sattvikc sattvikc changed the base branch from 9.3 to 9.2 October 2, 2024 10:19
@sattvikc sattvikc changed the base branch from 9.2 to 9.3 October 2, 2024 10:19
@sattvikc sattvikc merged commit e83c9b4 into 9.3 Oct 4, 2024
8 of 15 checks passed
@sattvikc sattvikc deleted the feat/oauth-provider-base branch October 4, 2024 05:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants