tfTeldUserSetSsl

Jump to: navigation, search

Table of Contents >> Application Reference >> Telnet Daemon


#include <trsocket.h>


int tfTeldUserSetSsl (
ttUserTeldSrvHandle userSrvHandle,
int sessionId
);


Function Description

This function enables the Telnet over SSL feature for all clients connecting to the specified Telnet server (if you have purchased the Treck SSL server option). You must obtain a SSL session id (see the Treck SSL Programmer's Reference) by calling tfSslNewSession(). This function associates the SSL session id with userSrvHandle, which forces every incoming connection on the server to perform SSL handshaking prior to starting the Telnet protocol. See Using SSL with the Treck TELNET Server for a full discussion and example code.

To enable the Telnet over SSL code, uncomment the following compile time macro in your trsystem.h module:

#define TM_USE_SSL_SERVER


Parameters


Returns

  • TM_ENOERROR
    Success
  • TM_EPERM
    Not initialized; call tfTeldUserInit() first.
  • TM_EINVAL
    Invalid parameter.
  • . . .
    (See setsockopt() for additional error codes).


Table of Contents >> Application Reference >> Telnet Daemon