1. 23 Feb, 2006 40 commits
    • Niels Möller's avatar
      (class gateway_connection): New class. · 5db1837d
      Niels Möller authored
      Rev: src/gateway.h:1.3.2.3
      5db1837d
    • Niels Möller's avatar
      (kill_gateway_connection): New function. · 0bcc37a8
      Niels Möller authored
      (gateway_write_packet): New function.
      (gateway_disconnect): New function.
      (oop_read_gateway): New function.
      (gateway_start_read): New function.
      (do_write_packet): New function.
      (do_disconnect): New function.
      (make_gateway_connection): New function.
      
      Rev: src/gateway.c:1.10.2.1
      0bcc37a8
    • Niels Möller's avatar
      (open_direct_tcpip_command): Don't setup any channel_open_context. · 959f8b37
      Niels Möller authored
      Rev: src/client_tcpforward.c:1.1.2.5
      959f8b37
    • Niels Möller's avatar
      (do_exit_status): Updated for const · 52721f03
      Niels Möller authored
      channel_request_info.
      (do_exit_signal): Updated for const channel_request_info. Use enum
      lsh_atom.
      (class session_open_command): New class, replacing command of the
      same name.
      (do_open_session_command): Don't setup any channel_open_context.
      (make_open_session_command): New function.
      (request_shell): Pass non-zero close_on_error to
      channel_send_request.
      (do_session_channel_request): Likewise.
      (client_options): Cosmetic changes.
      (expr make_start_session): Deleted.
      (client_shell_session, client_subsystem_session)
      (client_command_session): Use request queue in client_session
      object.
      (make_client_session): Changed return type to struct
      client_session *.
      
      Rev: src/client.c:1.166.2.19
      52721f03
    • Niels Möller's avatar
      (do_client_session_event): On · 0dafe1d7
      Niels Möller authored
      CHANNEL_EVENT_CONFIRM, send all queued channel requests. On
      CHANNEL_EVENT_DENY, raise an exception. On CHANNEL_EVENT_CLOSE, do
      nothing.
      
      Rev: src/client_session.c:1.21.2.9
      0dafe1d7
    • Niels Möller's avatar
      (class client_session): Moved definition here, from · d77d5834
      Niels Möller authored
      client_session.c.
      
      Rev: src/client.h:1.61.2.4
      d77d5834
    • Niels Möller's avatar
      (do_server_session_event): Handle and · ed73b3b0
      Niels Möller authored
      ignore CHANNEL_EVENT_CLOSE and CHANNEL_EVENT_DENY.
      (do_exit_shell): Updated call to channel_send_request.
      (shell_request_handler, exec_request_handler): Adapted to a const
      channel_request_info.
      (pty_request_handler): Likewise.
      
      Rev: src/server_session.c:1.103.2.15
      ed73b3b0
    • Niels Möller's avatar
      (open_forwarded_tcpip_command): Don't setup any channel_open_context. · 86329555
      Niels Möller authored
      Rev: src/server_tcpforward.c:1.1.2.5
      86329555
    • Niels Möller's avatar
      (class socks_channel): Replaces class · a6560459
      Niels Möller authored
      socks_connection, and inherits channel_forward.
      (class socks_continuation): Deleted.
      (do_socks_continuation, make_socks_continuation): Deleted.
      (class socks_exception_handler): Deleted.
      (do_exc_socks_handler, make_socks_exception_handler): Deleted.
      (do_socks_channel_event): New function, in particular handling
      CHANNEL_EVENT_CONFIRM and CHANNEL_EVENT_DENY.
      
      Rev: src/socks.c:1.5.2.5
      a6560459
    • Niels Möller's avatar
      (channel_forward_shutdown): Made · dc29b85e
      Niels Möller authored
      non-static.
      (channel_forward_start_read): New function.
      (init_channel_forward): Take event handler as argument.
      (forward_open_report, catch_channel_open): Deleted.
      
      Rev: src/channel_forward.h:1.8.2.2
      dc29b85e
    • Niels Möller's avatar
      (channel_forward_shutdown): Made · 592cb763
      Niels Möller authored
      non-static.
      (channel_forward_start_read): New function.
      (channel_forward_start_io): Use channel_forward_start_read.
      (do_channel_forward_event): Use channel_forward_start_read.
      Recognize CHANNEL_EVENT_DENY and CHANNEL_EVENT_CLOSE, and do
      nothing.
      (init_channel_forward): Take event handler as argument.
      (make_channel_forward): Pass do_channel_forward_event to
      init_channel_forward.
      (forward_open_report, catch_channel_open): Deleted.
      
      Rev: src/channel_forward.c:1.14.2.6
      592cb763
    • Niels Möller's avatar
      * src/channel.h (format_channel_close, format_channel_eof): · cfe8984c
      Niels Möller authored
      Deleted prototypes.
      
      * src/channel.h (enum channel_event): New event types
      CHANNEL_EVENT_DENY and CHANNEL_EVENT_CLOSE.
      (struct channel_request_info): Use enum lsh_atom for the type.
      (struct channel_request_methods): New struct, used by gateway
      channels to replace the handling of channel requests.
      (class ssh_channel): New attribute request_methods. Deleted
      request_fallback and channel_open_context.
      (class channel_request): Made the struct channel_request_info *
      argument const.
      
      Rev: src/channel.h:1.77.2.16
      cfe8984c
    • Niels Möller's avatar
      (format_open_confirmation, format_open_failure) · ccc6e1e6
      Niels Möller authored
      (format_channel_success, format_channel_failure)
      (format_channel_window_adjust): New function.
      (lookup_channel, lookup_channel_reserved): Deleted, replaced by
      ssh_connection_lookup_channel.
      (ssh_connection_register_channel): Renamed, was register_channel.
      (send_window_adjust): New function, replacing
      prepare_window_adjust.
      (channel_adjust_rec_window, channel_start_receive): Use
      send_window_adjust.
      (handle_global_request): Use enum lsh_atom.
      (handle_channel_request): Use request_methods, if non-NULL. Treat
      a request on non-existing channel as a protocol error.
      (do_channel_open_continue): Use ssh_connection_register_channel
      and ssh_connection_activate_channel.
      (do_exc_channel_open_handler): Updated for in_use / alloc_state
      renaming.
      (handle_channel_open): Don't use open_fallback handler. Use type
      CHANNEL_ALLOC_RECEIVED_OPEN when allocating the channel number.
      (handle_channel_close): Generate CHANNEL_EVENT_CLOSE.
      (handle_open_confirm): Use ssh_connection_activate_channel. Don't
      use channel_open_context.
      (handle_open_failure): Use ssh_connection_lookup_channel with type
      CHANNEL_ALLOC_SENT_OPEN. Generate CHANNEL_EVENT_DENY. Don't use
      channel_open_context.
      (handle_channel_success, handle_channel_failure): Use
      request_methods if non-NULL. For now, don't invoke any
      continuation or exception.
      (init_channel): Updated initialization for added and removed
      attributes.
      (channel_transmit_data): Use format_channel_data.
      (channel_transmit_extended): Use format_channel_extended_data.
      (channel_open_new_v): Alloc channel with type
      CHANNEL_ALLOC_SENT_OPEN. Call ssh_connection_register_channel.
      (channel_open_new_type): Replaced type argument, an atom, with
      length and const uint8_t *
      (channel_send_request): Replaced the context argument with a flag
      saying if the channel should be closed on failure.
      
      Rev: src/channel.c:1.125.2.21
      ccc6e1e6
    • Niels Möller's avatar
      (enum channel_event): New event types · 73e67026
      Niels Möller authored
      CHANNEL_EVENT_DENY and CHANNEL_EVENT_CLOSE.
      (struct channel_request_info): Use enum lsh_atom for the type.
      (struct channel_request_methods): New struct, used by gateway
      channels to replace the handling of channel requests.
      (class ssh_channel): New attribute request_methods. Deleted
      request_fallback and channel_open_context.
      (class channel_request): Made the struct channel_request_info *
      argument const.
      
      Rev: src/channel.h:1.77.2.15
      73e67026
    • Niels Möller's avatar
      (init_ssh_connection): Initialize alloc_state. · a80ef662
      Niels Möller authored
      (ssh_connection_alloc_channel): Added type argument. Proper
      reallocation of alloc_state.
      (ssh_connection_dealloc_channel): Updated for in_use / alloc_state
      renaming.
      (ssh_connection_activate_channel): Renamed function, was
      ssh_connection_use_channel.
      (ssh_connection_lookup_channel): New function, replacing
      lookup_channel and lookup_channel_reserved in channel.c.
      
      Rev: src/connection.c:1.82.2.7
      a80ef662
    • Niels Möller's avatar
      (enum channel_alloc_state): New name for enum. · 2898642c
      Niels Möller authored
      Replaced CHANNEL_RESERVED and CHANNEL_IN_USE with three values,
      CHANNEL_ALLOC_SENT_OPEN, CHANNEL_ALLOC_RECEIVED_OPEN, and
      CHANNEL_ALLOC_ACTIVE.
      (class ssh_connection): Deleted open_fallback. Renamed array
      in_use to alloc_state.
      
      Rev: src/connection.h:1.76.2.7
      2898642c
    • Niels Möller's avatar
      * src/dsa.c (do_dsa_verify, make_ssh_dss_verifier): Use enum · 69a1c4b9
      Niels Möller authored
      lsh_atom.
      * src/rsa.c (do_rsa_verify, make_ssh_rsa_verifier): Likewise.
      * src/lsh-decode-key.c (lsh_decode_key): Likewise.
      * src/lshd-userauth.c (get_verifier, handle_publickey)
      (handle_userauth): Likewise.
      * src/spki.c (spki_algorithm_lookup): Likewise.
      
      Rev: src/spki.c:1.58.2.3
      69a1c4b9
    • Niels Möller's avatar
      Comment change. · 7201d2e3
      Niels Möller authored
      Rev: src/Makefile.am:1.28.2.34
      Rev: src/lshd-connection.c:1.1.2.18
      7201d2e3
    • Niels Möller's avatar
      * src/gateway_channel.h: Deleted obsolete file. · d7253830
      Niels Möller authored
      * src/gateway_commands.h: Likewise.
      * src/gateway_commands.c: Likewise.
      * src/debug.c: Likewise.
      
      Rev: src/debug.c:1.41.2.1(DEAD)
      d7253830
    • Niels Möller's avatar
      * src/gateway_channel.h: Deleted obsolete file. · c80b2f07
      Niels Möller authored
      * src/gateway_commands.h: Likewise.
      * src/gateway_commands.c: Likewise.
      
      Rev: src/gateway_channel.h:1.7.2.1(DEAD)
      Rev: src/gateway_commands.c:1.24.2.5(DEAD)
      Rev: src/gateway_commands.h:1.6.2.2(DEAD)
      c80b2f07
    • Niels Möller's avatar
      (resource_iterate): New function. · c331162c
      Niels Möller authored
      (do_mark_resources): Use resource_iterate.
      (resource_list_foreach): New function.
      (kill_resource): New function.
      (do_kill_resource_list): Renamed, was do_kill_all. Use
      resource_list_foreach.
      
      Rev: src/resource.c:1.27.2.2
      Rev: src/resource.h:1.15.2.2
      c331162c
    • Niels Möller's avatar
      * src/arglist.h: Added missing include guard. · f43458b3
      Niels Möller authored
      * src/channel_io.h: Likewise.
      * src/lock_file.h: Likewise.
      * src/environ.h.in: Likewise.
      * src/transport_forward.h: Likewise.
      
      Rev: src/transport_forward.h:1.1.2.4
      f43458b3
    • Niels Möller's avatar
      Comment fix. · 25c77436
      Niels Möller authored
      Rev: src/transport_forward.c:1.1.2.8
      25c77436
    • Niels Möller's avatar
      (SSH_LSH_GATEWAY_STOP): New, local, message number. · e503ba06
      Niels Möller authored
      Rev: src/ssh.h:1.12.2.6
      e503ba06
    • Niels Möller's avatar
      * src/arglist.h: Added missing include guard. · 8c605ec2
      Niels Möller authored
      * src/channel_io.h: Likewise.
      * src/lock_file.h: Likewise.
      * src/environ.h.in: Likewise.
      
      Rev: src/environ.h.in:1.5.2.3
      8c605ec2
    • Niels Möller's avatar
      No longer includes format.h. · 660f2689
      Niels Möller authored
      Rev: src/charset.c:1.13.2.2
      660f2689
    • Niels Möller's avatar
      (listen_tcp_command): Use io_bind_sockaddr. · 31ee719b
      Niels Möller authored
      (listen_local_command): New command.
      
      Rev: src/io_commands.c:1.66.2.7
      Rev: src/io_commands.h:1.34.2.3
      31ee719b
    • Niels Möller's avatar
      * src/io.c (io_bind_local, io_connect_local): Changed to return a · 7802374c
      Niels Möller authored
      plain fd, no lsh_fd object.
      (io_bind_sockaddr): New function, used for both AF_LOCAL and
      AF_INET sockets.
      
      Rev: src/io.c:1.215.2.16
      Rev: src/io.h:1.110.2.11
      7802374c
    • Niels Möller's avatar
      * src/lsh_string.c (lsh_string_dup): New function, replacing... · e8b38283
      Niels Möller authored
      * src/format.h (lsh_string_dup): ... deleted macro.
      
      Rev: src/format.h:1.45.2.4
      Rev: src/lsh_string.c:1.2.2.10
      Rev: src/lsh_string.h:1.2.2.8
      e8b38283
    • Niels Möller's avatar
      Changed FIXME:s. · c25c1d5c
      Niels Möller authored
      Rev: src/format.c:1.54.2.5
      c25c1d5c
    • Niels Möller's avatar
      * src/dsa.c (do_dsa_verify, make_ssh_dss_verifier): Use enum · 960f3495
      Niels Möller authored
      lsh_atom.
      * src/rsa.c (do_rsa_verify, make_ssh_rsa_verifier): Likewise.
      * src/lsh-decode-key.c (lsh_decode_key): Likewise.
      * src/lshd-userauth.c (get_verifier, handle_publickey)
      (handle_userauth): Likewise.
      
      Rev: src/dsa.c:1.42.2.4
      Rev: src/lsh-decode-key.c:1.22.2.5
      Rev: src/lshd-userauth.c:1.1.2.15
      Rev: src/rsa.c:1.29.2.3
      960f3495
    • Niels Möller's avatar
      Added FIXME. · fa31878f
      Niels Möller authored
      Rev: src/atoms.h:1.9.2.3
      fa31878f
    • Niels Möller's avatar
      (lsh_sexp_to_atom, lsh_sexp_get_type): Return enum · 03787498
      Niels Möller authored
      lsh_atom, not int.
      
      Rev: src/sexp.c:1.49.2.1
      Rev: src/sexp.h:1.40.2.1
      03787498
    • Niels Möller's avatar
      For the header file, generate an enum, not a · c9398dfd
      Niels Möller authored
      list of #define:s.
      
      Rev: src/process_atoms:1.15.2.1
      c9398dfd
    • Niels Möller's avatar
      (parse_atom): Use enum lsh_atom for · 6c79a1cc
      Niels Möller authored
      Rev: src/parse.h:1.30.2.1
      6c79a1cc
    • Niels Möller's avatar
      (parse_atom, parse_next_atom): Use enum lsh_atom for · fdf09bb0
      Niels Möller authored
      result.
      (parse_atoms): Convert from enum lsh_atom to int, when
      constructing the list.
      
      Rev: src/parse.c:1.43.2.2
      fdf09bb0
    • Niels Möller's avatar
      Deleted unused spki-related atoms, p, q, g, y, x, · df579831
      Niels Möller authored
      r, s, n, e, d, a, b, c.
      
      Rev: src/atoms.in:1.36.2.2
      df579831
    • Niels Möller's avatar
      (lookup_atom): Return enum lsh_atom, not int. · cb60e607
      Niels Möller authored
      Rev: src/atoms.c:1.13.2.1
      Rev: src/atoms.h:1.9.2.2
      cb60e607
    • Niels Möller's avatar
      (sbin_PROGRAMS): Added lshd-pty-helper. · 127c5383
      Niels Möller authored
      (liblsh_a_SOURCES): Added gateway.c and gateway_channel.c.
      
      Rev: src/Makefile.am:1.28.2.33
      127c5383
    • Niels Möller's avatar
      *** empty log message *** · a20dd8ba
      Niels Möller authored
      Rev: src/.cvsignore:1.34.2.4
      a20dd8ba