Implement user authentication to my React app and API(with Ory Kratos)

Closed Posted 2 years ago Paid on delivery
Closed Paid on delivery

I am working on a project which now requires user authentication and I am a bit hung up at the moment. I originally created my own authentication feature using HTTP cookies, JWTs, and refresh tokens to authenticate users on login and protect my GraphQL API. This worked perfectly fine for me and I was happy with the solution, however, I'd rather use a proper self-hosted authentication solution instead of my own implementation.

I am aiming to use Ory Kratos to achieve this because it looks like a great solution and a promising future. I've been able to get the registration flow working but it's a bit hacky. I think at this stage it's best to just find someone who is familiar with Ory Kratos and can implement a clean and proper solution for me.

When you start this project, I will provide you with a dumbed-down example of my project. It will include a React app running on an express server for SSR. The app will have a login, register, forgot password, and home page. These pages will already have the forms, layout, and styles on them(using Formik which may need to change due to Ory Kratos using the action method of form submission). All you would be doing is, implementing the logic and functionality on these pages so that when finished, a user can register, verify email flow, login, and view protected routes.

These are the spec:

- Add registration functionality

- Ability to register using email/password method

- Send a confirmation email to complete registration

- Add hook when a user registers to make a request to my GraphQL database to add that user into that DB too(I can handle the functionality of accepting the hook call, I just don't know how to make it)

- Add login functionality

- Ability to login using email/password method

- Create session on login and redirect to a protected page

- Logout functionality

- Add logout button to destroy the session

- Add protected page functionality

- Add ability to specify which route must require a logged-in user

- A solution to protect requests being made to the GraphQL API(data api)

- I am not sure 100% the right solution for this but basically, I'd like to prevent any requests from coming in if the user isn't logged in. Right now I have a middleware that takes the bearer token and check to see if a user exists based on that JWT. I'd like to add some sort of middleware doing a similar thing where it checks to see if there is a Ory Kratos session and if so, allow the requests. The app, API and Kratos API will all be on the same domain.

I would really like to use Ory Kratos so if you're familiar with it and have used it in the past please let me know. If you have another good solution that you would like to suggest, I am happy to hear it. The main restrictions for me are, I want it to be self-hosted, and I can still keep the UI 100% customizable. If you have a good solution for this that will be cheaper please let me know.

Please don't suggest you can connect this all with Ory Kratos if you have never used it. I get a lot of false promises and fabricated experience on here which has always burned me, so I only am interested in solutions you are familiar with and have done before. Just so I know it doesn't turn into an hour burner and weak quality.

Thanks!

Web Security

Project ID: #31775448

About the project

5 proposals Remote project Active 2 years ago

5 freelancers are bidding on average $502 for this job

vukasinstojanovi

How are you doing? I read Implement user authentication to my React app and API(with Ory Kratos) carefully. I have a rich experience in Web Security. I have developed many front end with react.js and vue.js and etc. More

$400 CAD in 5 days
(1 Review)
1.0
rashidamjad

I am an experienced react native developer and have been in the field over the years. I have long-standing experience in providing mobile app services. Over the years, I have worked for different industry niches like More

$630 CAD in 7 days
(0 Reviews)
0.0
rexzetsolutions

Yes, i can implement user authentication to your React app and API. Message me i am ready to start work from right now.

$500 CAD in 3 days
(1 Review)
0.0
Nikita1241

Hi, I have read your post carefully. As a senior web developer, I have already developed lots of websites with Ory Kratos. That's why I think I can get this done in a timely manner. If you hire me , I will bring you t More

$350 CAD in 7 days
(0 Reviews)
0.0