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

Auth client that wraps authn and authz #2028

Closed
5 of 6 tasks
arvindh123 opened this issue Oct 17, 2023 · 6 comments
Closed
5 of 6 tasks

Auth client that wraps authn and authz #2028

arvindh123 opened this issue Oct 17, 2023 · 6 comments

Comments

@arvindh123
Copy link
Contributor

arvindh123 commented Oct 17, 2023

@arvindh123 arvindh123 changed the title Auth client that wraps authn and authz in both HTTP and gRPC endpoints Auth client that wraps authn and authz in gRPC endpoints Nov 15, 2023
@arvindh123 arvindh123 changed the title Auth client that wraps authn and authz in gRPC endpoints Auth client that wraps authn and authz Nov 15, 2023
@dborovcanin dborovcanin transferred this issue from absmach/magistrala-old Jan 10, 2024
@dborovcanin dborovcanin moved this to Todo in Magistrala May 15, 2024
@dborovcanin dborovcanin added this to the S5 milestone May 15, 2024
@dborovcanin dborovcanin modified the milestones: S5, 0.15.0 Jun 12, 2024
@dborovcanin dborovcanin moved this from ☑ Todo to ⛏ Backlog in Magistrala Jun 12, 2024
@felixgateru felixgateru moved this from ⛏ Backlog to 🚧 In Progress in Magistrala Jul 3, 2024
@felixgateru felixgateru moved this from 🚧 In Progress to ⛏ Backlog in Magistrala Jul 4, 2024
@dborovcanin dborovcanin modified the milestones: 0.15.0, v0.16.0 Jul 10, 2024
@dborovcanin dborovcanin moved this from ⛏ Backlog to 🛑 Blocked in Magistrala Jul 24, 2024
@dborovcanin dborovcanin moved this from 🛑 Blocked to ⛏ Backlog in Magistrala Aug 14, 2024
@dborovcanin
Copy link
Collaborator

This is related to #2264. In #2264 the idea is to create separate gRPC APIs for policy CRUD, AuthN, and AuthZ, and in this one, the idea is to have the abstraction for those clients so that we can either call Auth service gRPC APIs or SpiceDB directly.
@arvindh123 Please doublecheck if we need all 3, or if we can have only CRUD and Auth APIs.

@arvindh123
Copy link
Contributor Author

arvindh123 commented Aug 22, 2024

After this PR #2392 merged
We need to have kind of client on top AuthService and PolicyService gRPC Client

And I'm think of like having Authentication and Authorization in single place, i.e in AuthService for both users and things.
In this method, AuthService will communicate with users and things via gRPC to verify user password or thing key (Authentication) and then proceed with spiceDB for Authorization.

@arvindh123
Copy link
Contributor Author

@dborovcanin's idea , Services like Users, Things, Bootstrap, etc.. will import the "Policy Service" and "Auth service" as library in their code. Service don't know about how these libraries are connected to "Policy Service" or "Auth Service".

If we want to achieve this, one of the way is , we need add wrap above the existing gRPC client.

But I'm not sure about approach for "Policy Service" , Because the Policy Service library can either directly connect to SpiceDB or it can connect to Auth Service , where auth service act like proxy to SpiceDB

@arvindh123
Copy link
Contributor Author

arvindh123 commented Aug 26, 2024

Create wrapper for PolicyCURD alone, at present wrapper can communicate to Auth service.

In next PR replace Auth service in wrapper to SpiceDB.

Same way we need wrap for Authn/Authz and then Move Auth to middleware, It should impalement service by service , (Individual service in one PR )

Then wrap Authn/Authz wrapper can use JWT for users Authn and for things Authn ,it can verify with things service via gRPC.

@dborovcanin
Copy link
Collaborator

This is the absolute priority for the following sprint. It is blocking development related to constraints, PAT, but also restructuring the whole svc layer. @arvindh123 Please create follow-up tickets and use this as an umbrella task for this initiative.

@dborovcanin
Copy link
Collaborator

This is an umbrella issue for a couple of tasks. Only the JWT part is reamining and there is a corresponding issue, so I'm closing this one.

@github-project-automation github-project-automation bot moved this from 🚧 In Progress to ✅ Done in Magistrala Sep 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ✅ Done
Development

No branches or pull requests

3 participants