Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

upscli_connect(3) [freebsd man page]

UPSCLI_CONNECT(3)						    NUT Manual							 UPSCLI_CONNECT(3)

NAME
upscli_connect - Open a connection to a NUT upsd SYNOPSIS
#include <upsclient.h> int upscli_connect(UPSCONN_t *ups, const char *host, int port, int flags); DESCRIPTION
The upscli_connect() function takes the pointer ups to a UPSCONN_t state structure and opens a TCP connection to the host on the given port. flags may be either UPSCLI_CONN_TRYSSL to try a SSL connection, or UPSCLI_CONN_REQSSL to require a SSL connection. If SSL mode is required, this function will only return successfully if it is able to establish a SSL connection with the server. Possible reasons for failure include no SSL support on the server, and if upsclient itself hasn't been compiled with SSL support. You must call upscli_disconnect(3) when finished with a connection, or your program will slowly leak memory and file descriptors. RETURN VALUE
The upscli_connect() function modifies the UPSCONN_t structure and returns 0 on success, or -1 if an error occurs. SEE ALSO
upscli_disconnect(3), upscli_fd(3), upscli_splitaddr(3), upscli_splitname(3), upscli_ssl(3), upscli_strerror(3), upscli_upserror(3) Network UPS Tools 05/22/2012 UPSCLI_CONNECT(3)

Check Out this Related Man Page

UPSCLI_CONNECT(3)						    NUT Manual							 UPSCLI_CONNECT(3)

NAME
upscli_connect - Open a connection to a NUT upsd SYNOPSIS
#include <upsclient.h> int upscli_connect(UPSCONN_t *ups, const char *host, int port, int flags); DESCRIPTION
The upscli_connect() function takes the pointer ups to a UPSCONN_t state structure and opens a TCP connection to the host on the given port. flags may be either UPSCLI_CONN_TRYSSL to try a SSL connection, or UPSCLI_CONN_REQSSL to require a SSL connection. If SSL mode is required, this function will only return successfully if it is able to establish a SSL connection with the server. Possible reasons for failure include no SSL support on the server, and if upsclient itself hasn't been compiled with SSL support. You must call upscli_disconnect(3) when finished with a connection, or your program will slowly leak memory and file descriptors. RETURN VALUE
The upscli_connect() function modifies the UPSCONN_t structure and returns 0 on success, or -1 if an error occurs. SEE ALSO
upscli_disconnect(3), upscli_fd(3), upscli_splitaddr(3), upscli_splitname(3), upscli_ssl(3), upscli_strerror(3), upscli_upserror(3) Network UPS Tools 05/22/2012 UPSCLI_CONNECT(3)
Man Page

2 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

SSL ftp from Unix

I need to make an SSL FTP connection from my Unix machine to an SSL FTP server. I've found lots of SSL-capable FTP clients for windows machines, but can't seem to find any for Unix (HP-UX 11i, to be specific). I found, and have tried a package called tlswrap, but that is not working. Anybody... (2 Replies)
Discussion started by: denverd0n
2 Replies

2. Red Hat

How to check port used for SSL?

I have RHEL 5.8 in our production environment. We are using SSL, my query is how to find the port used for SSL. In /etc/services, it shows 443 but when I give netstat -tulpn | grep 443 Or netstat -tulp | grep https I do not get any output. I hope, my question is clear of how to find... (4 Replies)
Discussion started by: RHCE
4 Replies