HotspotAuthenticationContext.TryGetAuthenticationContext Method

Definition

Gets the context of an authentication attempt.

Note

This functionality is available only to mobile operator apps and UWP apps given privileged access by mobile network operators.

If you want to use this API and publish your app to the Microsoft Store, then you'll need special approval. For more information, see the Restricted capabilities section in the App capability declarations topic.

public:
 static bool TryGetAuthenticationContext(Platform::String ^ evenToken, [Out] HotspotAuthenticationContext ^ & context);
 static bool TryGetAuthenticationContext(winrt::hstring const& evenToken, [Out] HotspotAuthenticationContext const& & context);
public static bool TryGetAuthenticationContext(string evenToken, out HotspotAuthenticationContext context);
Public Shared Function TryGetAuthenticationContext (evenToken As String, ByRef context As HotspotAuthenticationContext) As Boolean

Parameters

evenToken
String

Platform::String

winrt::hstring

The event token retrieved from the network operator hotspot authentication event. The token is a GUID in string format.

context
HotspotAuthenticationContext

The network operator hotspot authentication context.

Returns

Boolean

bool

If true, the authentication context was retrieved. The authentication context can only be retrieved if the calling application matches the application ID specified in the hotspot profile of the underlying WLAN connection and if the authentication hasn’t be completed by the corresponding context already or timed out.

Windows requirements

App capabilities
cellularDeviceControl cellularDeviceIdentity

Applies to