Class NavigatorLogin
- Namespace
- CSharpToJavaScript.APIs.JS
- Assembly
- CSharpToJavaScript.dll
The NavigatorLogin interface of the Federated Credential Management (FedCM) API defines login functionality for federated identity providers (IdPs). Specifically, it enables a federated identity provider (IdP) to set its login status when a user signs into or out of the IdP.
[Value("NavigatorLogin")]
public class NavigatorLogin
- Inheritance
-
NavigatorLogin
- Inherited Members
Remarks
See Update login status using the Login Status API for more details of how this is used.
NavigatorLogin is accessed via the Login property.
Constructors
NavigatorLogin()
public NavigatorLogin()
Methods
SetStatus(LoginStatus)
The setStatus() method of the NavigatorLogin interface sets the login status of a federated identity provider (IdP), when called from the IdP's origin. By this, we mean "whether any users are logged into the IdP on the current browser or not". This should be called by the IdP site following a user login or logout.
[Value("setStatus")]
public Task<GlobalObject.Undefined> SetStatus(LoginStatus status)
Parameters
statusLoginStatus
Returns
- Task<GlobalObject.Undefined>
A Promise that fulfills with
undefined.
Remarks
The browser stores this state for each IdP; the FedCM API then uses it to reduce the number of requests it makes to the IdP (because it does not need to waste time requesting accounts when there are no users logged in to the IdP). It also mitigates potential timing attacks.
See Update login status using the Login Status API for more information about FedCM login status.