How to secure front end using aws amplify and node js express server?

0

Greetings,

I have issues understanding how to secure the front-end deployed on Amplify web application using the Cognito service. and i tried the following: https://docs.amplify.aws/lib/auth/getting-started/q/platform/js/#enable-sign-up-sign-in-and-sign-out

Web application background:

The framework used is SAPUI5 tooling where the web application is built into a distribution folder. SAPUI5 tooling is based on node js application.

Locally the framework runs on express server and if i follow the guide for manual authentication https://docs.amplify.aws/lib/auth/emailpassword/q/platform/js/ it works just fine locally.

Deploying it to amplify it no longer works, and as far as i understood this is because it not supported.

Expected behavior / end-result

What i am expecting is that when you do amplify auth add and provide a user the front end UI portion would be protected no matter the URL used. And a login screen is provided before moving on to the main application

Questions:

  1. is amplify auth add only used to secure the back-end API resources? (looks like to be the case) 1-1 If amplify auth is only used for back-end then does this mean the web application itself needs to contain the login flow somehow without a server to prevent access and redirects?
답변 없음

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠