Lines Matching refs:ssh
234 set_control_persist_exit_time(struct ssh *ssh) in set_control_persist_exit_time() argument
240 } else if (channel_still_open(ssh)) { in set_control_persist_exit_time()
278 client_x11_get_proto(struct ssh *ssh, const char *display, in client_x11_get_proto() argument
364 channel_set_x11_refuse_time(ssh, in client_x11_get_proto()
438 client_check_window_change(struct ssh *ssh) in client_check_window_change() argument
447 channel_send_window_changes(ssh); in client_check_window_change()
451 client_global_request_reply(int type, u_int32_t seq, struct ssh *ssh) in client_global_request_reply() argument
458 gc->cb(ssh, type, seq, gc->ctx); in client_global_request_reply()
489 client_wait_until_can_do_something(struct ssh *ssh, in client_wait_until_can_do_something() argument
503 if (session_closed && !channel_still_open(ssh) && in client_wait_until_can_do_something()
530 set_control_persist_exit_time(ssh); in client_wait_until_can_do_something()
653 client_status_confirm(struct ssh *ssh, int type, Channel *c, void *ctx) in client_status_confirm() argument
706 mux_tty_alloc_failed(ssh, c); in client_status_confirm()
708 chan_read_failed(ssh, c); in client_status_confirm()
709 chan_write_failed(ssh, c); in client_status_confirm()
716 client_abandon_status_confirm(struct ssh *ssh, Channel *c, void *ctx) in client_abandon_status_confirm() argument
722 client_expect_confirm(struct ssh *ssh, int id, const char *request, in client_expect_confirm() argument
730 channel_register_status_confirm(ssh, id, client_status_confirm, in client_expect_confirm()
756 process_cmdline(struct ssh *ssh) in process_cmdline() argument
830 ok = channel_request_rforward_cancel(ssh, &fwd) == 0; in process_cmdline()
832 ok = channel_cancel_lport_listener(ssh, &fwd, in process_cmdline()
835 ok = channel_cancel_lport_listener(ssh, &fwd, in process_cmdline()
849 if (!channel_setup_local_fwd_listener(ssh, &fwd, in process_cmdline()
855 if (channel_request_remote_forwarding(ssh, &fwd) < 0) { in process_cmdline()
933 process_escapes(struct ssh *ssh, Channel *c, in process_escapes() argument
969 chan_read_failed(ssh, c); in process_escapes()
970 chan_write_failed(ssh, c); in process_escapes()
972 c->detach_user(ssh, in process_escapes()
977 chan_ibuf_empty(ssh, c); in process_escapes()
1018 channel_request_start(ssh, c->self, "break", 0); in process_escapes()
1019 if ((r = sshpkt_put_u32(ssh, 1000)) != 0 || in process_escapes()
1020 (r = sshpkt_send(ssh)) != 0) in process_escapes()
1073 channel_stop_listening(ssh); in process_escapes()
1108 s = channel_open_message(ssh); in process_escapes()
1118 process_cmdline(ssh); in process_escapes()
1193 client_filter_cleanup(struct ssh *ssh, int cid, void *ctx) in client_filter_cleanup() argument
1199 client_simple_escape_filter(struct ssh *ssh, Channel *c, char *buf, int len) in client_simple_escape_filter() argument
1204 return process_escapes(ssh, c, c->input, c->output, c->extended, in client_simple_escape_filter()
1209 client_channel_closed(struct ssh *ssh, int id, void *arg) in client_channel_closed() argument
1211 channel_cancel_cleanup(ssh, id); in client_channel_closed()
1223 client_loop(struct ssh *ssh, int have_pty, int escape_char_arg, in client_loop() argument
1303 channel_register_filter(ssh, session_ident, in client_loop()
1309 channel_register_cleanup(ssh, session_ident, in client_loop()
1319 if (session_closed && !channel_still_open(ssh)) in client_loop()
1322 if (ssh_packet_is_rekeying(ssh)) { in client_loop()
1327 if ((r = kex_start_rekex(ssh)) != 0) in client_loop()
1337 channel_output_poll(ssh); in client_loop()
1343 client_check_window_change(ssh); in client_loop()
1353 client_wait_until_can_do_something(ssh, &readset, &writeset, in client_loop()
1354 &max_fd2, &nalloc, ssh_packet_is_rekeying(ssh)); in client_loop()
1360 if (!ssh_packet_is_rekeying(ssh)) in client_loop()
1361 channel_after_select(ssh, readset, writeset); in client_loop()
1403 channel_free_all(ssh); in client_loop()
1472 client_request_forwarded_tcpip(struct ssh *ssh, const char *request_type, in client_request_forwarded_tcpip() argument
1491 c = channel_connect_by_listen_address(ssh, listen_address, listen_port, in client_request_forwarded_tcpip()
1525 client_request_forwarded_streamlocal(struct ssh *ssh, in client_request_forwarded_streamlocal() argument
1540 c = channel_connect_by_listen_path(ssh, listen_path, in client_request_forwarded_streamlocal()
1547 client_request_x11(struct ssh *ssh, const char *request_type, int rchan) in client_request_x11() argument
1572 sock = x11_connect_display(ssh); in client_request_x11()
1575 c = channel_new(ssh, "x11", in client_request_x11()
1583 client_request_agent(struct ssh *ssh, const char *request_type, int rchan) in client_request_agent() argument
1600 c = channel_new(ssh, "authentication agent connection", in client_request_agent()
1609 client_request_tun_fwd(struct ssh *ssh, int tun_mode, in client_request_tun_fwd() argument
1628 c = channel_new(ssh, "tun", SSH_CHANNEL_OPENING, fd, fd, -1, in client_request_tun_fwd()
1634 channel_register_filter(ssh, c->self, sys_tun_infilter, in client_request_tun_fwd()
1652 client_input_channel_open(int type, u_int32_t seq, struct ssh *ssh) in client_input_channel_open() argument
1668 c = client_request_forwarded_tcpip(ssh, ctype, rchan, rwindow, in client_input_channel_open()
1671 c = client_request_forwarded_streamlocal(ssh, ctype, rchan); in client_input_channel_open()
1673 c = client_request_x11(ssh, ctype, rchan); in client_input_channel_open()
1675 c = client_request_agent(ssh, ctype, rchan); in client_input_channel_open()
1707 client_input_channel_req(int type, u_int32_t seq, struct ssh *ssh) in client_input_channel_req() argument
1714 c = channel_lookup(ssh, id); in client_input_channel_req()
1715 if (channel_proxy_upstream(c, type, seq, ssh)) in client_input_channel_req()
1730 chan_rcvd_eow(ssh, c); in client_input_channel_req()
1734 mux_exit_message(ssh, c, exitval); in client_input_channel_req()
1905 client_global_hostkeys_private_confirm(struct ssh *ssh, int type, in client_global_hostkeys_private_confirm() argument
1924 sshkey_type_from_name(ssh->kex->hostkey_alg)); in client_global_hostkeys_private_confirm()
1929 if (ssh->kex->session_id_len == 0) in client_global_hostkeys_private_confirm()
1943 (r = sshbuf_put_string(signdata, ssh->kex->session_id, in client_global_hostkeys_private_confirm()
1944 ssh->kex->session_id_len)) != 0 || in client_global_hostkeys_private_confirm()
1949 if ((r = sshpkt_get_string_direct(ssh, &sig, &siglen)) != 0) { in client_global_hostkeys_private_confirm()
1962 use_kexsigtype ? ssh->kex->hostkey_alg : NULL, 0)) != 0) { in client_global_hostkeys_private_confirm()
1974 ssh_packet_check_eom(ssh); in client_global_hostkeys_private_confirm()
2010 struct ssh *ssh = active_state; /* XXX */ in client_input_hostkeys() local
2030 while (ssh_packet_remaining(ssh) > 0) { in client_input_hostkeys()
2033 if ((r = sshpkt_get_string_direct(ssh, &blob, &len)) != 0) { in client_input_hostkeys()
2119 if ((r = sshpkt_start(ssh, SSH2_MSG_GLOBAL_REQUEST)) != 0 || in client_input_hostkeys()
2120 (r = sshpkt_put_cstring(ssh, in client_input_hostkeys()
2122 (r = sshpkt_put_u8(ssh, 1)) != 0) /* bool: want reply */ in client_input_hostkeys()
2134 if ((r = sshpkt_put_stringb(ssh, buf)) != 0) in client_input_hostkeys()
2138 if ((r = sshpkt_send(ssh)) != 0) in client_input_hostkeys()
2158 client_input_global_request(int type, u_int32_t seq, struct ssh *ssh) in client_input_global_request() argument
2181 client_session2_setup(struct ssh *ssh, int id, int want_tty, int want_subsystem, in client_session2_setup() argument
2191 if ((c = channel_lookup(ssh, id)) == NULL) in client_session2_setup()
2204 channel_request_start(ssh, id, "pty-req", 1); in client_session2_setup()
2205 client_expect_confirm(ssh, id, "PTY allocation", CONFIRM_TTY); in client_session2_setup()
2213 ssh_tty_make_modes(ssh, -1, tiop); in client_session2_setup()
2245 channel_request_start(ssh, id, "env", 0); in client_session2_setup()
2262 channel_request_start(ssh, id, "env", 0); in client_session2_setup()
2276 channel_request_start(ssh, id, "subsystem", 1); in client_session2_setup()
2277 client_expect_confirm(ssh, id, "subsystem", in client_session2_setup()
2282 channel_request_start(ssh, id, "exec", 1); in client_session2_setup()
2283 client_expect_confirm(ssh, id, "exec", CONFIRM_CLOSE); in client_session2_setup()
2288 channel_request_start(ssh, id, "shell", 1); in client_session2_setup()
2289 client_expect_confirm(ssh, id, "shell", CONFIRM_CLOSE); in client_session2_setup()