Class UafClient
Definition
- Namespace:
- Tizen.Account.FidoClient
- Assembly:
- Tizen.Account.FidoClient.dll
- API Level:
- 3
The FIDO UAF Client APIs
public static class UafClient
- Inheritance
-
UafClient
Properties
View SourceMajorVersion
The FIDO Client Major version
Declaration
public static int MajorVersion { get; }
Property Value
Type | Description |
---|---|
Int32 |
API Level: 3
View SourceMinorVersion
The FIDO Client Minor version
Declaration
public static int MinorVersion { get; }
Property Value
Type | Description |
---|---|
Int32 |
API Level: 3
View SourceStautsOk
The FIDO Server response for successfull interaction.
Declaration
public static int StautsOk { get; }
Property Value
Type | Description |
---|---|
Int32 |
API Level: 3
View SourceVendorName
The FIDO Client vendor name
Declaration
public static string VendorName { get; }
Property Value
Type | Description |
---|---|
String |
API Level: 3
Methods
View SourceCheckPolicyAsync(UafMessage)
Checks whether the FIDO message can be processed
Declaration
public static Task<bool> CheckPolicyAsync(UafMessage uafMessage)
Parameters
Type | Name | Description |
---|---|---|
UafMessage | uafMessage | The FIDO UAF message which is received from the relying party server |
Returns
Type | Description |
---|---|
Task<Boolean> | True if the message can be handled by the device, else false |
Examples
UafMessage uafRequest = new UafMessage()
{
Operation = "UafRequestJson"
};
bool response = await UafClient.CheckPolicyAsync(uafRequest);
Exceptions
Type | Condition |
---|---|
ArgumentException | In case of invalid parameter |
UnauthorizedAccessException | Thrown when the application does not have privilege to access this method |
NotSupportedException | FIDO is not supported |
API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/fido.client
Feature: http://tizen.org/feature/fido.uaf
View SourceNotifyResultAsync(Int32, UafResponse)
Notifies the FIDO client about the server result. FIDO Server sends the result of processing a UAF message to FIDO client.
Declaration
public static Task NotifyResultAsync(int responseCode, UafResponse response)
Parameters
Type | Name | Description |
---|---|---|
Int32 | responseCode | The status code received from Server.(StautsOk implies success) |
UafResponse | response | The FIDO response message sent to server in JSON format |
Returns
Type | Description |
---|---|
Task |
Remarks
This is especially important for cases when a new registration may be considered by the client to be in a pending state until it is communicated that the server accepted it
Examples
UafResponse response = new UafResponse()
{
Response = "Responsejson"
};
await UafClient.NotifyResultAsync(UafClient.StautsOk, response);
Exceptions
Type | Condition |
---|---|
ArgumentException | In case of invalid parameter |
UnauthorizedAccessException | Thrown when the application does not have privilege to access this method |
NotSupportedException | FIDO is not supported |
API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/fido.client
Feature: http://tizen.org/feature/fido.uaf
View SourceProcessRequestAsync(UafMessage, String)
Processes the given FIDO UAF message.
Declaration
public static Task<UafResponse> ProcessRequestAsync(UafMessage uafMessage, string channelBindng)
Parameters
Type | Name | Description |
---|---|---|
UafMessage | uafMessage | The FIDO UAF message which is received from the relying party server |
String | channelBindng | The channel binding data in JSON format which is received from the relying party server |
Returns
Type | Description |
---|---|
Task<UafResponse> | FIDO response message |
Examples
UafMessage uafRequest = new UafMessage()
{
Operation = "UafAuthRequestJson"
};
var response = await UafClient.ProcessRequestAsync(uafRequest, null);
Exceptions
Type | Condition |
---|---|
ArgumentException | In case of invalid parameter |
UnauthorizedAccessException | Thrown when the application does not have privilege to access this method |
NotSupportedException | FIDO is not supported |