Discuss this help topic in SecureBlackbox Forum

TElCustomSimpleSSLClient.OnKeyNeeded

TElCustomSimpleSSLClient     


Filter: C#  VB.NET  Pascal  C++  PHP  Java  


This event is fired when TElSSLClient needs pre-shared-key from user.

Declaration

[C#]
    event TSBClientKeyNeededEvent OnKeyNeeded;
    delegate void TSBClientKeyNeededEvent(Object Sender, string Hint, ref string Identity, ref byte[] Key);

[VB.NET]
    Event OnKeyNeeded As TSBClientKeyNeededEvent
    Delegate Sub TSBClientKeyNeededEvent(ByVal Sender As Object, ByVal Hint As String, ByRef Identity As String, ByRef Key As Byte())

[Pascal]
    property OnKeyNeeded : TSBClientKeyNeededEvent;
    TSBClientKeyNeededEvent = procedure(Sender : TObject; const Hint : string; var Identity : string; var Key : ByteArray) of object;

[C++]
    void get_OnKeyNeeded(TSBClientKeyNeededEvent &pMethodOutResult, void * &pDataOutResult);
    void set_OnKeyNeeded(TSBClientKeyNeededEvent pMethodValue, void * pDataValue);
    typedef void (SB_CALLBACK *TSBClientKeyNeededEvent)(void * _ObjectData, TObjectHandle Sender, const char * pcHint, int32_t szHint, char * pcIdentity, int32_t &szIdentity, uint8_t pKey[], int32_t &szKey);

[PHP]
    TSBClientKeyNeededEvent|callable|NULL get_OnKeyNeeded()
    void set_OnKeyNeeded(TSBClientKeyNeededEvent|callable|NULL $Value)
    callable TSBClientKeyNeededEvent(TObject $Sender, string $Hint, string &$Identity, string &$Key)

[Java]
    TSBClientKeyNeededEvent getOnKeyNeeded();
    void setOnKeyNeeded(TSBClientKeyNeededEvent Value);
    TSBClientKeyNeededEvent.Callback OnKeyNeeded = new TSBClientKeyNeededEvent.Callback() {
        public byte[] TSBClientKeyNeededEventCallback(TObject Sender, String Hint, TSBString Identity) {
            //...
        }
    }

Parameters

  • Hint - identity hint provided by server to help the client in selecting which identity to use
  • Identity - identifier of the key choosen by client
  • Key - key. Must be initialized in event handler
  • pcHint - identity hint provided by server to help the client in selecting which identity to use
  • szHint - the length of pcHint.
  • pcIdentity - identifier of the key choosen by client
  • szIdentity - the length of pcIdentity.
  • pKey -
  • szKey - the length of pcKey.

Description

    This event is fired by TElSSLClient when it needs pre-shared-key from the user. This event is fired only when PSK-based ciphersuites are used.

Discuss this help topic in SecureBlackbox Forum