1

I have built a Node.js web app hosted on Azure with Azure AD authentication. How can I obtain the bearer token from the client's session to send authenticated requests to another app service in Azure also protected by the same Azure AD?

1
  • Hi, have you solved your issue now? If you have any update, please feel free to let me know. Commented Jul 6, 2016 at 6:02

1 Answer 1

2

When your user get authenticated via AAD and redirect to your web app hosted on Azure. Your can get the HTTP header of this request, you can find the access_token is stored in the header param X-Ms-Token-Aad-Id-Token.

Then you can store this token in session or in cookie for your custom requirement. And you set this token in the header of the request against to your other web apps in the same AAD.

The token should be set in the Authorization param in headers and the value format should be bearer <token>.

Any further concern, please feel free let me know.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.