Lines Matching refs:s_out
78 void raw_xfer(int csock, int s_in, int s_out);
701 static int ssl_init(int s_in, int s_out, int skip_vnc_tls, double last_https) { in ssl_init() argument
709 static void ssl_xfer(int csock, int s_in, int s_out, int is_https) { in ssl_xfer() argument
713 raw_xfer(csock, s_in, s_out); in ssl_xfer()
741 static int ssl_init(int s_in, int s_out, int skip_vnc_tls, double last_https);
742 static void ssl_xfer(int csock, int s_in, int s_out, int is_https);
1559 static int anontls_dialog(int s_in, int s_out) { in anontls_dialog() argument
1561 if (s_in || s_out) {} in anontls_dialog()
1577 static int vencrypt_dialog(int s_in, int s_out) { in vencrypt_dialog() argument
1588 if (!write_exact(s_out, buf, 2)) { in vencrypt_dialog()
1589 close(s_in); close(s_out); in vencrypt_dialog()
1596 close(s_in); close(s_out); in vencrypt_dialog()
1604 close(s_in); close(s_out); in vencrypt_dialog()
1612 write_exact(s_out, buf, 1); in vencrypt_dialog()
1613 close(s_in); close(s_out); in vencrypt_dialog()
1619 if (!write_exact(s_out, buf, 1)) { in vencrypt_dialog()
1620 close(s_in); close(s_out); in vencrypt_dialog()
1660 if (!write_exact(s_out, buf2, 1)) { in vencrypt_dialog()
1661 close(s_in); close(s_out); in vencrypt_dialog()
1665 if (!write_exact(s_out, buf, 4*n)) { in vencrypt_dialog()
1666 close(s_in); close(s_out); in vencrypt_dialog()
1672 close(s_in); close(s_out); in vencrypt_dialog()
1680 close(s_in); close(s_out); in vencrypt_dialog()
1694 close(s_in); close(s_out); in vencrypt_dialog()
1711 if (!write_exact(s_out, buf, 1)) { in vencrypt_dialog()
1712 close(s_in); close(s_out); in vencrypt_dialog()
1730 static int check_vnc_tls_mode(int s_in, int s_out, double last_https) { in check_vnc_tls_mode() argument
1802 if (!write_exact(s_out, proto, strlen(proto))) { in check_vnc_tls_mode()
1803 close(s_in); close(s_out); in check_vnc_tls_mode()
1809 close(s_in); close(s_out); in check_vnc_tls_mode()
1820 close(s_in); close(s_out); in check_vnc_tls_mode()
1826 close(s_in); close(s_out); in check_vnc_tls_mode()
1850 if (!write_exact(s_out, buf, n+1)) { in check_vnc_tls_mode()
1851 close(s_in); close(s_out); in check_vnc_tls_mode()
1858 close(s_in); close(s_out); in check_vnc_tls_mode()
1878 write_exact(s_out, buf, 4); in check_vnc_tls_mode()
1879 write_exact(s_out, msg, strlen(msg)); in check_vnc_tls_mode()
1880 close(s_in); close(s_out); in check_vnc_tls_mode()
1887 return vencrypt_dialog(s_in, s_out); in check_vnc_tls_mode()
1889 return anontls_dialog(s_in, s_out); in check_vnc_tls_mode()
1937 static int ssl_init(int s_in, int s_out, int skip_vnc_tls, double last_https) { in ssl_init() argument
1967 } else if (!check_vnc_tls_mode(s_in, s_out, last_https)) { in ssl_init()
1971 getpid(), s_in, s_out, timeout); in ssl_init()
1982 if (s_in == s_out) { in ssl_init()
1992 if (! SSL_set_wfd(ssl, s_out)) { in ssl_init()
2157 static void symmetric_encryption_xfer(int csock, int s_in, int s_out);
2159 static void ssl_xfer(int csock, int s_in, int s_out, int is_https) { in ssl_xfer() argument
2183 raw_xfer(csock, s_in, s_out); in ssl_xfer()
2190 raw_xfer(csock, s_in, s_out); in ssl_xfer()
2192 symmetric_encryption_xfer(csock, s_in, s_out); in ssl_xfer()
2226 if (s_out > s_in) { in ssl_xfer()
2227 ssock = s_out; in ssl_xfer()
2318 FD_SET(s_out, &wr); in ssl_xfer()
2360 …d\n", getpid(), nfd, FD_ISSET(csock, &wr), FD_ISSET(csock, &rd), FD_ISSET(s_out, &wr), FD_ISSET(s_… in ssl_xfer()
2421 if ((cptr > 0 && FD_ISSET(s_out, &wr)) || in ssl_xfer()
2495 (SSL_want_write(ssl) && FD_ISSET(s_out, &wr)) || in ssl_xfer()
2550 getpid(), csock, s_in, s_out); in ssl_xfer()
2553 close(s_out); in ssl_xfer()
3491 int s_in, s_out, httpsock = -1; in accept_openssl() local
3540 s_out = fileno(stdout); in accept_openssl()
3542 s_in = s_out = sock; in accept_openssl()
3545 if (! ssl_init(s_in, s_out, skip_vnc_tls, last_https)) { in accept_openssl()
3663 write(s_out, reply, strlen(reply)); in accept_openssl()
3701 write(s_out, reply, strlen(reply)); in accept_openssl()
3841 ssl_xfer(httpsock, s_in, s_out, is_http); in accept_openssl()
3856 ssl_xfer(vncsock, s_in, s_out, 0); in accept_openssl()
4213 void raw_xfer(int csock, int s_in, int s_out) { in raw_xfer() argument
4234 if (db) rfbLog("raw_xfer start: %d -> %d/%d\n", csock, s_in, s_out); in raw_xfer()
4245 m = write(s_out, src, len); in raw_xfer()
4254 if (db) rfbLog("raw_xfer bad write: %d -> %d | %d/%d errno=%d\n", csock, s_out, m, n, errno); in raw_xfer()
4262 if (db) rfbLog("raw_xfer done: %d -> %d\n", csock, s_out); in raw_xfer()
4298 close(s_out); in raw_xfer()
4318 static void symmetric_encryption_xfer(int csock, int s_in, int s_out) { in symmetric_encryption_xfer() argument
4339 if (s_out) {} in symmetric_encryption_xfer()