Client - SetBannerHandler, OnBanner


__cdecl FlowSshC_Client_SetBannerHandler(
  FlowSshC_Client* client,
  FlowSshC_BannerHandler handler,
  void* handlerData);


[Client] virtual void OnBanner(std::wstring const& banner);


[ClientBase] public event BannerEventHandler OnBanner;

[C] Parameters

  • client: FlowSshC_Client pointer.
  • handler: A BannerHandler function.
  • handlerData: An application-defined value to be passed to the handler. Optional.

[C++/.NET] Overrides and Events

  • OnBanner: Invoked when there is a banner message to be reported.
    • banner: A banner message. Production code should remove volatile characters before using the string.


Sometimes sending a warning message before the client user authenticates may be relevant to ensure legal protection against violators. Banner handlers are invoked if:

  • The server has sent a banner message in the first place.
  • A handler was registered/implemented.

If both conditions are satisfied, the handler is invoked while establishing a connection with the SSH server, at progress [ConnectStep]SshUserAuth.