summaryrefslogtreecommitdiffstats
path: root/rfb
diff options
context:
space:
mode:
authorChristian Beier <dontmind@freeshell.org>2012-02-20 15:52:19 +0100
committerChristian Beier <dontmind@freeshell.org>2012-02-20 15:52:19 +0100
commit83a7c713a99a65f910fabab1bb95428762f569fb (patch)
tree46e2fad855fd03a2e9a8bf6e03c2d2242b26de43 /rfb
parent1078e8a8b050b5b4ebbcb011750f5dd2d8eacc37 (diff)
downloadlibtdevnc-83a7c713a99a65f910fabab1bb95428762f569fb.tar.gz
libtdevnc-83a7c713a99a65f910fabab1bb95428762f569fb.zip
IPv6 support for LibVNCServer, part one: accept IPv4 and IPv6 connections.
This uses a separate-socket approach since there are systems that do not support dual binding sockets under *any* circumstances, for instance OpenBSD. Using separate sockets for IPv4 and IPv6 is thus more portable than having a v6 socket handle v4 connections as well. Signed-off-by: Christian Beier <dontmind@freeshell.org>
Diffstat (limited to 'rfb')
-rw-r--r--rfb/rfb.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/rfb/rfb.h b/rfb/rfb.h
index e068e76..9e9fbfe 100644
--- a/rfb/rfb.h
+++ b/rfb/rfb.h
@@ -377,6 +377,12 @@ typedef struct _rfbScreenInfo
char *sslkeyfile;
char *sslcertfile;
#endif
+ int ipv6port; /**< The port to listen on when using IPv6. */
+ char* listen6Interface;
+ /* We have an additional IPv6 listen socket since there are systems that
+ don't support dual binding sockets under *any* circumstances, for
+ instance OpenBSD */
+ SOCKET listen6Sock;
} rfbScreenInfo, *rfbScreenInfoPtr;
@@ -738,6 +744,7 @@ extern int rfbCheckFds(rfbScreenInfoPtr rfbScreen,long usec);
extern int rfbConnect(rfbScreenInfoPtr rfbScreen, char* host, int port);
extern int rfbConnectToTcpAddr(char* host, int port);
extern int rfbListenOnTCPPort(int port, in_addr_t iface);
+extern int rfbListenOnTCP6Port(int port, const char* iface);
extern int rfbListenOnUDPPort(int port, in_addr_t iface);
extern int rfbStringToAddr(char* string,in_addr_t* addr);
extern rfbBool rfbSetNonBlocking(int sock);