Lines Matching refs:ssh

180 client_alive_check(struct ssh *ssh)  in client_alive_check()  argument
187 sshpkt_fmt_connection_id(ssh, remote_id, sizeof(remote_id)); in client_alive_check()
196 if ((channel_id = channel_find_open(ssh)) == -1) { in client_alive_check()
201 channel_request_start(ssh, channel_id, in client_alive_check()
214 wait_until_can_do_something(struct ssh *ssh, in wait_until_can_do_something() argument
226 channel_prepare_select(ssh, readsetp, writesetp, maxfdp, in wait_until_can_do_something()
292 client_alive_check(ssh); in wait_until_can_do_something()
297 client_alive_check(ssh); in wait_until_can_do_something()
310 process_input(struct ssh *ssh, fd_set *readset, int connection_in) in process_input() argument
320 ssh_remote_ipaddr(ssh), ssh_remote_port(ssh)); in process_input()
327 ssh_remote_ipaddr(ssh), in process_input()
328 ssh_remote_port(ssh), strerror(errno)); in process_input()
351 process_buffered_input_packets(struct ssh *ssh) in process_buffered_input_packets() argument
353 ssh_dispatch_run_fatal(ssh, DISPATCH_NONBLOCK, NULL); in process_buffered_input_packets()
357 collect_children(struct ssh *ssh) in collect_children() argument
372 session_close_by_pid(ssh, pid, status); in collect_children()
379 server_loop2(struct ssh *ssh, Authctxt *authctxt) in server_loop2() argument
407 process_buffered_input_packets(ssh); in server_loop2()
409 if (!ssh_packet_is_rekeying(ssh) && in server_loop2()
411 channel_output_poll(ssh); in server_loop2()
412 if (options.rekey_interval > 0 && !ssh_packet_is_rekeying(ssh)) in server_loop2()
417 wait_until_can_do_something(ssh, connection_in, connection_out, in server_loop2()
426 collect_children(ssh); in server_loop2()
427 if (!ssh_packet_is_rekeying(ssh)) in server_loop2()
428 channel_after_select(ssh, readset, writeset); in server_loop2()
429 if (process_input(ssh, readset, connection_in) < 0) in server_loop2()
433 collect_children(ssh); in server_loop2()
439 channel_free_all(ssh); in server_loop2()
442 session_destroy_all(ssh, NULL); in server_loop2()
446 server_input_keep_alive(int type, u_int32_t seq, struct ssh *ssh) in server_input_keep_alive() argument
459 server_request_direct_tcpip(struct ssh *ssh, int *reason, const char **errmsg) in server_request_direct_tcpip() argument
478 c = channel_connect_to_port(ssh, target, target_port, in server_request_direct_tcpip()
495 server_request_direct_streamlocal(struct ssh *ssh) in server_request_direct_streamlocal() argument
517 c = channel_connect_to_path(ssh, target, in server_request_direct_streamlocal()
532 server_request_tun(struct ssh *ssh) in server_request_tun() argument
564 c = channel_new(ssh, "tun", SSH_CHANNEL_OPEN, sock, sock, -1, in server_request_tun()
569 channel_register_filter(ssh, c->self, sys_tun_infilter, in server_request_tun()
593 server_request_session(struct ssh *ssh) in server_request_session() argument
611 c = channel_new(ssh, "session", SSH_CHANNEL_LARVAL, in server_request_session()
616 channel_free(ssh, c); in server_request_session()
619 channel_register_cleanup(ssh, c->self, session_close_by_channel, 0); in server_request_session()
624 server_input_channel_open(int type, u_int32_t seq, struct ssh *ssh) in server_input_channel_open() argument
641 c = server_request_session(ssh); in server_input_channel_open()
643 c = server_request_direct_tcpip(ssh, &reason, &errmsg); in server_input_channel_open()
645 c = server_request_direct_streamlocal(ssh); in server_input_channel_open()
647 c = server_request_tun(ssh); in server_input_channel_open()
677 server_input_hostkeys_prove(struct ssh *ssh, struct sshbuf **respp) in server_input_hostkeys_prove() argument
691 sshkey_type_from_name(ssh->kex->hostkey_alg)); in server_input_hostkeys_prove()
692 while (ssh_packet_remaining(ssh) > 0) { in server_input_hostkeys_prove()
695 if ((r = sshpkt_get_string_direct(ssh, &blob, &blen)) != 0 || in server_input_hostkeys_prove()
705 if ((ndx = ssh->kex->host_key_index(key, 1, ssh)) == -1) { in server_input_hostkeys_prove()
715 (key_pub = get_hostkey_public_by_index(ndx, ssh)) == NULL) { in server_input_hostkeys_prove()
731 ssh->kex->session_id, ssh->kex->session_id_len)) != 0 || in server_input_hostkeys_prove()
733 (r = ssh->kex->sign(key_prv, key_pub, &sig, &slen, in server_input_hostkeys_prove()
735 use_kexsigtype ? ssh->kex->hostkey_alg : NULL, 0)) != 0 || in server_input_hostkeys_prove()
755 server_input_global_request(int type, u_int32_t seq, struct ssh *ssh) in server_input_global_request() argument
791 success = channel_setup_remote_fwd_listener(ssh, &fwd, in server_input_global_request()
809 success = channel_cancel_rport_listener(ssh, &fwd); in server_input_global_request()
829 success = channel_setup_remote_fwd_listener(ssh, in server_input_global_request()
841 success = channel_cancel_rport_listener(ssh, &fwd); in server_input_global_request()
847 success = server_input_hostkeys_prove(ssh, &resp); in server_input_global_request()
853 ssh_packet_put_raw(ssh, sshbuf_ptr(resp), in server_input_global_request()
864 server_input_channel_req(int type, u_int32_t seq, struct ssh *ssh) in server_input_channel_req() argument
877 if ((c = channel_lookup(ssh, id)) == NULL) in server_input_channel_req()
882 chan_rcvd_eow(ssh, c); in server_input_channel_req()
885 success = session_input_channel_req(ssh, c, rtype); in server_input_channel_req()