question

KevinAzure avatar image
0 Votes"
KevinAzure asked ·

Azure AD Express Authentication

I am using Azure AD Express Settings for Authentication for an Angular App.
It is working fine.

I need to put 30 minutes idle timeout for the ID/Access Token
1. how i will set idle timeout in express settings?
2. will there be automatic extension of token if user continuously use for 2 hours?
3. should i refresh the token with access token?

Please advice.






azure-active-directory
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

FrankHuMSFT-3200 avatar image
0 Votes"
FrankHuMSFT-3200 answered ·

Hello @PaulAzure-8925,

How i will set idle timeout in express settings?

You will need to setup a lifetime policy per the docs here :

https://docs.microsoft.com/en-us/azure/active-directory/develop/registration-config-change-token-lifetime-how-to

https://docs.microsoft.com/en-us/azure/active-directory/develop/active-directory-configurable-token-lifetimes#example-token-lifetime-policies

Depending on your requirements per the docs, you may need to get the application ID by switching to the custom view of the App Service's Easy Auth Settings.


Will there be automatic extension of token if user continuously use for 2 hours?

Per the SO : https://stackoverflow.com/questions/45819990/azure-ad-easy-auth-expires-even-when-users-are-actively-using-application

You will need to refresh your token yourself. Please see the answer from Chris Gillium in the SO post for more information

Should i refresh the token with access token?

That's not how the access token works, refresh tokens are used to get new access tokens. For more information on how the OAuth2 flow works for auth code, oidc, or refresh please refer to the docs below :

https://docs.microsoft.com/en-us/azure/active-directory/develop/authentication-scenarios

https://docs.microsoft.com/en-us/azure/active-directory/develop/authentication-flows-app-scenarios





· Share
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.