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

Create a function to allow the "merging" of multiple auths #588

Closed
Badgerati opened this issue Jul 14, 2020 · 3 comments · Fixed by #1146
Closed

Create a function to allow the "merging" of multiple auths #588

Badgerati opened this issue Jul 14, 2020 · 3 comments · Fixed by #1146

Comments

@Badgerati
Copy link
Owner

Describe the Change

This is from #575.

Could it be possible to have some Merge-PodeAuth function, which would allow the merging of multiple auth methods?

For example:

Merge-PodeAuth -Name -Auths[] <-All> <-One>

This will return a "merged" auth type usable on Routes, and you can either have All auths needed to pass, or just One to pass.

@Badgerati Badgerati added this to the 2.0.0 milestone Jul 14, 2020
@Badgerati Badgerati removed this from the 2.0.0 milestone Oct 15, 2020
@Badgerati Badgerati changed the title 2.0: Create a function to allow the "merging" of multiple auths Create a function to allow the "merging" of multiple auths Oct 15, 2020
@Badgerati Badgerati added this to the 2.8.0 milestone Nov 29, 2022
@Badgerati Badgerati modified the milestones: 2.8.0, 2.9.0 Feb 1, 2023
@Badgerati Badgerati self-assigned this Aug 22, 2023
@Badgerati
Copy link
Owner Author

I've extended this to also cover the new Access methods as well, and tweaked the way they work from #992 slightly.

There is now two new Merge-PodeAuth and Merge-PodeAuthAccess functions, which will let you build more advanced authentication and authorization strategies - and yes you can merge and merged Auth method with another Auth method 😄

I'm also making Test-PodeAuth and Test-PodeAuthExists public, for further advanced/custom scenarios where you want to run the authentication validation manually.

@Badgerati
Copy link
Owner Author

I have overhauled the core authentication validation logic quite a bit. In my initial tests so far there haven't been any breaking changes, and all existing auth methods still work - but it will need more testing to make sure.

@Badgerati
Copy link
Owner Author

All testing seems good 😄 Just need to update the docs.

Badgerati added a commit that referenced this issue Oct 7, 2023
@Badgerati Badgerati mentioned this issue Oct 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant