Hello All,
I am new to Software engineering and development. I am trying to implement auth0 for out application which is using nextjs for frontend and springboot for backend. I successfully implemented the auth0 login in nextjs. I am using the App route structure, so I had to create a new folder named “pages” to be able to follow the instruction provided in auth0. I am not very confident about this procedure but I got it to work.
I still need to to the following:
1- secure nextjs pages (only authenticated user could access otherwise redirect to login page)
2-secure endpoints in java (spring boot)
4-send secure calls from nextjs to the backend APIs.
I am a little bit lost on how to protect pages in nextjs. I know I need to use “withPageAuthRequired” but looks like it is not working only with Page router not the app router.
I am experiencing a lot of deprecated functions and issues that are related to using App router in nextjs and using ‘org.springframework.boot’ version ‘3.0.6’ in the backend.