简体   繁体   English

Office 365 API-自动登录

[英]Office 365 API - Automatic Login

In these examples: https://msdn.microsoft.com/en-us/office/office365/howto/starter-projects-and-code-samples the user has to sign in their respective Office 365 account to have access to their email and calendar. 在这些示例中: https : //msdn.microsoft.com/zh-cn/office/office365/howto/starter-projects-and-code-samples用户必须登录各自的Office 365帐户才能访问其电子邮件和日历。

Is it possible to make an automatic sign in process with known username and password and prevent from logging in every time? 是否可以使用已知的用户名和密码进行自动登录,并防止每次登录?

Thanks 谢谢

No, the user has to log in at some point and consent to the app's requested access. 否,用户必须在某个时候登录并同意该应用程序的请求访问权限。 However, once they've done that, you can cache the access token and refresh token. 但是,一旦他们这样做,您就可以缓存访问令牌并刷新令牌。 The user would only have to re-enter their username and password if your refresh token expired. 如果您的刷新令牌过期,则用户只需重新输入用户名和密码即可。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM