Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
QuickLoginQrCodeAuthenticator.cs
1using Paiwise;
2using System.Threading.Tasks;
4
6{
11 {
15 public const string QuickLoginAddressType = "QuickLogin";
16
20 public const string QuickLoginDescriptionMarkdown =
21 "The standard *Quick-Login* mechanism is indicated by setting the " +
22 "`AddressType` parameter to `QuickLogin`. This method only takes an empty " +
23 "`Address` parameter. Instead, it returns a `ChallengeUrl` URI that references " +
24 "a QR code that the user must scan to trigger the login procedure. The QR Code " +
25 "is only valid for a short time, so the petition should be polled (regardless " +
26 "of response method used) to ensure new updated QR codes care are presented to " +
27 "the user. You can customize the URI by appending any of the query parameters "+
28 "defined in the [QR Code API](https://lab.tagroot.io/Community/Post/Enhanced_QR_Code_API)";
29
34 : base()
35 {
36 }
37
42
47
54 {
55 return string.Equals(RemoteIdentifier.AddressType, QuickLoginAddressType, System.StringComparison.InvariantCultureIgnoreCase) ?
56 Grade.Excellent : Grade.NotAtAll;
57 }
58
64 public override Task<IRemoteAuthentication> CreateAuthentication(IRemoteIdentifier RemoteIdentifier)
65 {
66 return Task.FromResult<IRemoteAuthentication>(
67 new QuickLoginRemoteAuthentication(null, null));
68 }
69 }
70}
Contains information about a remote identifier.
string AddressType
Remote Address Type, identifying the type of address used in Address.
Interface for remote authentications.
Interface for remote identifiers.
Grade
Grade enumeration
Definition: Grade.cs:7