Skip to content

struct flake::AuthenticationSink

#include <Connection.h>

Public Functions

Name
virtual [void]onAuthChallengeReceived([const][char] * challenge_type, [uint8_t] * challenge, [int] challenge_len, [uint8_t] ** response, [int] * response_len) =0
called if we need to authenticate (Client and Router)
virtual [int]onAuthChallengeRequested([void] * wire, [char] ** challenge_type, [uint8_t] ** challenge, [int] * challenge_len) =0
virtual [int]onAuthResponseReceived([const][char] * challenge_type, [uint8_t] * challenge, [int] challenge_len, [uint8_t] * response, [int] response_len) =0
virtual [int]onConnect([const]PropArray & props) =0
called if authentication type is 'atInteractive'. Return 0 if auth is accepted (Router only)
virtual [flakeAuthType]authenticationType() =0
return the desired authentication type

Protected Functions

Name
virtual~AuthenticationSink() =default

Public Functions Documentation

function onAuthChallengeReceived

cpp
virtual void onAuthChallengeReceived(
    constchar * challenge_type,
    uint8_t * challenge,
    int challenge_len,
    uint8_t ** response,
    int * response_len
) =0

called if we need to authenticate (Client and Router)

function onAuthChallengeRequested

cpp
virtual int onAuthChallengeRequested(
    void * wire,
    char ** challenge_type,
    uint8_t ** challenge,
    int * challenge_len
) =0

called on a new connection on a wire (Router only) return 0 if challenge is present, -1 if no auth wanted/needed

function onAuthResponseReceived

cpp
virtual int onAuthResponseReceived(
    constchar * challenge_type,
    uint8_t * challenge,
    int challenge_len,
    uint8_t * response,
    int response_len
) =0

called if we asked for challenge auth on a wire. Returns 0 if auth is ok (Router only) the previously allocated challenge_type and challenge should be freed here.

function onConnect

cpp
virtual int onConnect(
    constPropArray & props
) =0

called if authentication type is 'atInteractive'. Return 0 if auth is accepted (Router only)

function authenticationType

cpp
virtual flakeAuthType authenticationType() =0

return the desired authentication type

Protected Functions Documentation

function ~AuthenticationSink

cpp
virtual ~AuthenticationSink() =default