When setting Azure AD app registration for using OAUTH 2 authentication, you need to create a client secret. A client secret has an expiration date that now (from the Azure Portal) can be set to 24 months as maximum: Source : Stefano Demiliani Read more...