Before, I had asked a question Access control to a page with REST service
But maybe I need to ask more briefly and more generally to get the idea.
I have a REST API. Client is browser. "login" is also one of my REST Service, where user enters his credentials and authenticated. Then, the user begins navigate different pages.
Please note that I do not ask about REST API security, authentication/authorization etc.
The question is:
How do I check if the user was authenticated before, through REST API, to see if the user has right to view a particular web page? (Web Server is based on java)
Thank you for any idea.
Edit:
I see that the question is understood how to authorize with REST API.
After authentication via REST API, I'm not asking the other requests to REST API. I want to see that authentication in my Web Server, which is at another domain, isolated from REST Server. I imagine some work-arounds; however I would like to hear design alternatives. Isn't there anyone who has separated his Web Server and REST API? Is this totally wrong?