Difference between revisions of "Unit Authentication"

From Ultibo.org
Jump to: navigation, search
 
(10 intermediate revisions by the same user not shown)
Line 5: Line 5:
 
----
 
----
  
'''Ultibo Authentication interface unit'''
+
'''Ultibo Authentication Interface unit'''
 
+
''To be documented''
+
  
 
=== Constants ===
 
=== Constants ===
Line 14: Line 12:
  
 
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 20px; padding-bottom: 15px;">
 
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 20px; padding-bottom: 15px;">
<div style="font-size: 14px; padding-left: 12px;">'''Authenticator flag constants''' <code> AUTHENTICATOR_FLAG_* </code></div>
+
<div style="font-size: 14px; padding-left: 12px;">'''Authenticator flag''' <code> AUTHENTICATOR_FLAG_* </code></div>
 
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 
{| class="wikitable" style="font-size: 14px; background: white;"
 
{| class="wikitable" style="font-size: 14px; background: white;"
Line 34: Line 32:
  
  
'''Authenticator'''
+
'''Authentication specific classes'''
  
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial;">
+
{| class="wikitable" style="font-size: 14px; text-align: left; width: 100%; height: 50px;"
 
+
<code>TAuthenticator = class(TObject)</code>
+
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
+
{| class="wikitable" style="font-size: 14px; background: white;"
+
 
|-
 
|-
|colspan="2"|<div style="font-family: monospace,courier;">'''public'''</div>
+
| [[TAuthenticator|<code>TAuthenticator = class(TObject)</code>]]
|-
+
| <code>constructor Create;</code>
+
| style="width: 50%;"|&nbsp;
+
|-
+
| <code>destructor Destroy; override;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|<div style="font-family: monospace,courier;">'''private'''</div>
+
|-
+
| <code>FLock:TCriticalSectionHandle;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|&nbsp;
+
|-
+
| <code>FFlags:LongWord;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|&nbsp;
+
|-
+
| <code>procedure SetFlags(AFlags:LongWord);</code>
+
| &nbsp;
+
|-
+
|colspan="2"|<div style="font-family: monospace,courier;">'''protected'''</div>
+
|-
+
| <code>function AcquireLock:Boolean;</code>
+
| &nbsp;
+
|-
+
| <code>function ReleaseLock:Boolean;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|<div style="font-family: monospace,courier;">'''public'''</div>
+
|-
+
| <code>property Flags:LongWord read FFlags write SetFlags;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|&nbsp;
+
|-
+
| <code>function UsernamePrompt:String; virtual;</code>
+
| &nbsp;
+
|-
+
| <code>function PasswordPrompt(const AUsername:String):String; virtual;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|&nbsp;
+
|-
+
| <code>function CheckUsername(const AUsername:String):LongWord; virtual;</code>
+
| &nbsp;
+
|-
+
| <code>function CheckPassword(const AUsername,APassword:String):LongWord; virtual;</code>
+
| &nbsp;
+
 
|-
 
|-
 
|}
 
|}
</div></div>
+
{| class="wikitable" style="font-size: 14px; text-align: left; width: 100%; height: 50px;"
 
+
|-  
'''Null authenticator'''
+
| [[TNullAuthenticator|<code>TNullAuthenticator = class(TAuthenticator)</code>]]
 
+
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial;">
+
 
+
<code>TNullAuthenticator = class(TAuthenticator)</code>
+
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
+
{| class="wikitable" style="font-size: 14px; background: white;"
+
|-
+
|colspan="2"|Note: An authenticator module that accepts any username and password.
+
|-
+
|colspan="2"|&nbsp;  
+
|-
+
|colspan="2"|<div style="font-family: monospace,courier;">'''public'''</div>
+
|-
+
| <code>function UsernamePrompt:String; override;</code>
+
| style="width: 50%;"|&nbsp;
+
|-
+
| <code>function PasswordPrompt(const AUsername:String):String; override;</code>
+
| &nbsp;
+
|-
+
|colspan="2"|&nbsp;
+
|-
+
| <code>function CheckUsername(const AUsername:String):LongWord; override;</code>
+
| &nbsp;
+
|-
+
| <code>function CheckPassword(const AUsername,APassword:String):LongWord; override;</code>
+
| &nbsp;
+
 
|-
 
|-
 
|}
 
|}
</div></div>
 
 
<br />
 
<br />
  
Line 146: Line 63:
 
{| class="wikitable" style="font-size: 14px; background: white;"
 
{| class="wikitable" style="font-size: 14px; background: white;"
 
|-
 
|-
! '''Note'''
+
! Note
 
| None documented
 
| None documented
 
|-
 
|-

Latest revision as of 04:39, 31 August 2021

Return to Unit Reference


Description


Ultibo Authentication Interface unit

Constants



Authenticator flag AUTHENTICATOR_FLAG_*
AUTHENTICATOR_FLAG_NONE = $00000000;  


Type definitions


None defined

Class definitions



Authentication specific classes

TAuthenticator = class(TObject)
TNullAuthenticator = class(TAuthenticator)


Public variables


None defined

Function declarations



Initialization functions

procedure AuthInit;
Description: To be documented
Note None documented


Return to Unit Reference