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

Add ability to disable authentication adapter #7952

Closed
3 tasks done
dblythy opened this issue Apr 26, 2022 · 6 comments · Fixed by #7953
Closed
3 tasks done

Add ability to disable authentication adapter #7952

dblythy opened this issue Apr 26, 2022 · 6 comments · Fixed by #7953
Labels
type:feature New feature or improvement of existing feature

Comments

@dblythy
Copy link
Member

dblythy commented Apr 26, 2022

New Feature / Enhancement Checklist

Current Limitation

Currently, all internal auth adapters are enabled by default, with no option to disable auth adapters that aren't necessary.

Feature / Enhancement Description

Allow

auth : {
 facebook: {
   enabled: false
 }
}

Example Use Case

n/a

Alternatives / Workarounds

n/a

3rd Party References

n/a

@parse-github-assistant
Copy link

Thanks for opening this issue!

  • 🎉 We are excited about your ideas for improvement!

@mtrezza
Copy link
Member

mtrezza commented Apr 26, 2022

Do we need a separate property for this or just disable them if they are not configured in the Parse Server options? Maybe we can make this breaking change in the future and add the option only temporarily, already with a depreciation warning?

@dblythy
Copy link
Member Author

dblythy commented Apr 27, 2022

That's what I was thinking. Disabling them if they are not configured would be a breaking change. Many auth adapters however don't require any backend configuration and depend fully on client side. Perhaps we can make a change:

  • For the adapters that require configuration, if they are in the auth payload (e.g auth.facebook) consider them enabled
  • For the adapters that do not require configuration, they require auth.google.enabled to be enabled.

This still would be a breaking change, however I think it's one worth pushing through.

@mtrezza
Copy link
Member

mtrezza commented Apr 27, 2022

If not every adapter requires server configuration then I guess it doesn't work to only enable them if they are configured server side. I think your suggestion makes most sense to introduce an enabled property that is currently true by default (with a deprecation warning), and then we change this in a later version to false by default so one has to manually enable them - for security.

@dblythy
Copy link
Member Author

dblythy commented Apr 27, 2022

Sounds good!

@mtrezza mtrezza added the type:feature New feature or improvement of existing feature label Apr 27, 2022
@mtrezza mtrezza linked a pull request May 28, 2022 that will close this issue
7 tasks
@mtrezza
Copy link
Member

mtrezza commented May 28, 2022

Closing via #7953

@mtrezza mtrezza closed this as completed May 28, 2022
@dblythy dblythy mentioned this issue Oct 12, 2022
31 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:feature New feature or improvement of existing feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants