SecureBlackbox 2020 C++ Edition

Questions / Feedback?

UnknownKeyReceived Event

Signals that the server has introduced itself with an unknown key.

Syntax

ANSI (Cross Platform)
virtual int FireUnknownKeyReceived(SFTPClientUnknownKeyReceivedEventParams *e);
typedef struct {
const char *Algorithm;
int Bits;
const char *FingerprintSHA256;
int Action; int reserved; } SFTPClientUnknownKeyReceivedEventParams; Unicode (Windows) virtual INT FireUnknownKeyReceived(SFTPClientUnknownKeyReceivedEventParams *e);
typedef struct {
LPCWSTR Algorithm;
INT Bits;
LPCWSTR FingerprintSHA256;
INT Action; INT reserved; } SFTPClientUnknownKeyReceivedEventParams;
- (void)onUnknownKeyReceived:(NSString*)algorithm :(int)bits :(NSString*)fingerprintSHA256 :(int*)action;
#define EID_SFTPCLIENT_UNKNOWNKEYRECEIVED 16

virtual INT SECUREBLACKBOX_CALL FireUnknownKeyReceived(LPSTR &lpszAlgorithm, INT &iBits, LPSTR &lpszFingerprintSHA256, INT &iAction);

Remarks

The class fires this event to tell the application that the server has introduced itself with a key not present in TrustedKeysFile. The details of the key are provided. In this event handler, you need to make a decision whether to proceed with the connection.

Use ServerKey to access more key details.

Use Action to tell the class what it should do with the key, supported values: catAcceptOnce = 1, catAcceptPermanently = 2, catReject = 3. Note that accepting an unknown and unchecked key may be risky.

Copyright (c) 2022 /n software inc. - All rights reserved.
SecureBlackbox 2020 C++ Edition - Version 20.0 [Build 8166]