summaryrefslogtreecommitdiff
path: root/examples (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* examples/sssh.scm (print-help, print-version): Improve.Artyom Poptsov2014-02-221-28/+23
| | | | | | | | * examples/sssh.scm (print-help): Rename to `print-help-and-exit'. Call `exit'. All callers updated. (print-version): Rename to `print-version-and-exit'. Call `exit'. All callers updated. (main): Update.
* examples/ssshd.scm (main): Add `--ssh-debug' option.Artyom Poptsov2014-02-221-2/+5
| | | | | | * examples/ssshd.scm (main): Add `--ssh-debug' option. (print-help-and-exit): Likewise. * NEWS: Update.
* examples/README: Update.Artyom Poptsov2014-02-072-6/+19
| | | | | | * examples/README: Update. * examples/README.org: Add the symlink to `examples/README.org' to help the GitHub recognize the org-mode markup.
* examples/ssshd.scm: Add `--detach' option.Artyom Poptsov2014-02-031-10/+35
| | | | | * examples/ssshd.scm (close-ports): New procedure. (main): Add `--detach' option.
* examples/ssshd.scm: Parse command-line options.Artyom Poptsov2014-02-021-9/+37
| | | | | | | * examples/ssshd.scm (main): Add command-line options: `--rsakey', `--dsakey', `--help'. (print-help-and-exit): New procedure. * NEWS: Update.
* examples/ssshd.scm (format-debug): Remove.Artyom Poptsov2014-02-011-5/+0
|
* examples/ssshd.scm (poll): Remove.Artyom Poptsov2014-02-011-7/+0
|
* src/server-func.c (set_option): Use symbols for `log-verbosity'.Artyom Poptsov2014-01-282-2/+2
| | | | | | | | | | | | * src/server-func.c (set_option) [SSH_BIND_OPTIONS_LOG_VERBOSITY]: Use symbols to represent log levels instead of numbers. All callers updated. (set_sym_opt): New procedure. * src/session-func.c: Move `log_verbosity' to `common.c' file. * src/common.c, src/common.h: Update. * examples/echo/server.scm (*default-log-verbosity*): Set to 'nolog. * examples/ssshd.scm (*default-log-verbosity*): Likewise. * NEWS: Update.
* session-func.c (set_option): Use symbols for `log-verbosity'.Artyom Poptsov2014-01-282-2/+4
| | | | | | | | | | * src/session-func.c (set_option)[SSH_OPTIONS_LOG_VERBOSITY]: Use symbols to represent log levels instead of numbers. All callers updated. (set_sym_opt): New procedure. * examples/echo/client.scm (main): Set log verbosity to `nolog'. * examples/sssh.scm (main): Update. * NEWS: Update.
* Merge branch 'channel-to-ptob'Artyom Poptsov2014-01-276-29/+424
|\ | | | | | | | | | | Conflicts: ChangeLog NEWS
| * examples/echo/client.scm (main): Print MD5 sum.Artyom Poptsov2014-01-271-1/+3
| | | | | | | | | | * examples/echo/client.scm (main): Print MD5 sum if the server is not known.
| * examples/echo/client.scm: Improve.Artyom Poptsov2014-01-221-23/+24
| |
| * examples/echo/server.scm (main): Add `--port' option. Improve.Artyom Poptsov2014-01-221-5/+10
| | | | | | | | | | | | * examples/echo/server.scm (print-help): Update. (main): Add `--port' option. Print RSA/DSA key pathes and current bind port on the start.
| * examples/echo/{server,client}.scm (read-all): Fix a bug.Artyom Poptsov2014-01-202-4/+4
| | | | | | | | | | | | * examples/echo/server.scm (read-all): Fix a bug: return the first read line if there is no more data to read. * examples/echo/client.scm (read-all): Likewise.
| * examples/echo/server.scm: Handle command-line options.Artyom Poptsov2014-01-201-57/+86
| | | | | | | | | | * examples/echo/server.scm (print-help): New procedure. (main): Handle command-line options.
| * examples/ssshd.scm, examples/sssh.scm: Update.Artyom Poptsov2014-01-112-14/+23
| | | | | | | | | | | | | | | | | | | | | | | | * examples/ssshd.scm (handle-channel): Use `read-all' instead of `channel-read'. Update. (handle-request-exec): Use `display' instead of `channel-write'. (shell-loop): Use `read-all' instead of `channel-read' and `channel-poll'. Use `display' instead of `channel-write'. (main): Close a channel before disconnecting the session. * examples/sssh.scm (read-all): New procedure. (main): Use `read-all' instead of `read-line'. Use `char-ready?' instead of `channel-poll'.
| * examples/echo/{client,server}.scm: Update comments.Artyom Poptsov2014-01-072-2/+48
| | | | | | | | | | * examples/echo/client.scm: Update comments. * examples/echo/server.scm: Likewise.
| * examples/echo/{client,server}.scm: Update.Artyom Poptsov2014-01-072-16/+33
| | | | | | | | | | | | | | | | | | * examples/echo/server.scm (read-all): New procedure. (main): Update. Catch exceptions. Use `write-line' instead of `display'. * examples/echo/client.scm (read-all): New procedure. (main): Update. Use `char-ready?' instead of `channel-poll'. Use `write-line' instead of `display'.
| * src/channel-type.c (ptob_input_waiting): Implement the procedure.Artyom Poptsov2014-01-041-4/+4
| | | | | | | | | | | | | | | | * src/channel-type.c (ptob_input_waiting): Call `ssh_channel_poll'. (init_channel_type): Register callback with `scm_set_port_input_waiting' procedure. * examples/echo/server.scm (main): Use `char-ready?' predicate instead of the custom procedure `channel-poll'.
| * src/channel-type.c (ptob_close): New procedure.Artyom Poptsov2014-01-042-5/+6
| | | | | | | | | | | | | | | | | | | | | | * src/channel-type.c (ptob_close): New procedure. (print_channel): Don't try to get state of a channel if its port is closed because it leads to segfaults. Closed port means closed channel. (init_channel_type): Register `ptob_close' with `scm_set_port_close'. * examples/echo/client.scm (main): Call `close' on a channel. * examples/echo/server.scm (main): Likewise.
| * Use Guile port API to implement Guile-SSH channels.Artyom Poptsov2014-01-025-18/+304
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/channel-func.c (guile_ssh_channel_read) (guile_ssh_channel_write): Remove. * src/channel-func.h (guile_ssh_channel_read): Remove. * src/channel-type.c (ptob_fill_input, ptob_write, ptob_flush) (ptob_input_waiting, _ssh_channel_to_scm): New procedures. (guile_ssh_make_channel): Use `_ssh_channel_to_scm'. (_scm_to_ssh_channel): Use `SCM_STREAM' macro. (init_channel_type): Register Guile port callbacks. * src/channel-type.h (_ssh_channel_to_scm): Export. * src/channel.scm (channel-read, channel-write): Remove. * src/message-func.c (guile_ssh_message_channel_request_open_reply_accept): Use `_ssh_channel_to_scm'. * examples/echo: Add to the repository. * examples/Makefile.am: Add echo server/client example. * examples/README: Update. * examples/sssh.scm: Update. * README: Update.
* | examples/sssh.scm: Use `userauth-autopubkey!'.Artyom Poptsov2014-01-181-24/+6
| | | | | | | | | | * examples/sssh.scm (main): Use `userauth-autopubkey!' for authentication.
* | src/key-func.c: Add basic support of encrypted keys.Artyom Poptsov2014-01-121-4/+17
|/ | | | | | * examples/sssh.scm (main): Ask the user for a passphrase. * src/key-func.c (guile_ssh_private_key_from_file): Change argument list: add optional argument `passphrase'.
* ssshd.scm (main): Print useful information on the start.Artyom Poptsov2013-11-251-0/+6
| | | | | * examples/ssshd.scm (main): Print path to a key and the port number on the start.
* examples/ssshd.scm: Handle `channel-request-env'.Artyom Poptsov2013-11-251-2/+14
| | | | | | * examples/ssshd.scm (handle-req-channel): Handle `channel-request-env'. (main): Improve handling of `request-channel'.
* examples/sssh.scm (*option-spec*): Add missed `ssh-debug' switch.Artyom Poptsov2013-11-231-1/+2
|
* examples/Makefile.am: Add missed `ssshd.scm' to distribution.Artyom Poptsov2013-11-231-3/+1
| | | | | | * examples/Makefile.am (dist_examples_DATA): Add missed `ssshd.scm'. (AM_CFLAGS): Remove.
* examples/sssh.scm: Improve debug mode. Print SSH cnannels.Artyom Poptsov2013-11-181-17/+14
| | | | | * examples/sssh.scm (main): Separate libssh debug and the program debug mode. Print SSH channels.
* src/channel-type.c: Set the printer procedure for the smob.Artyom Poptsov2013-11-181-0/+9
| | | | | | * src/channel-type.c (print_channel): New procedure. (init_channel_type): Set the printer procedure for the smob. * NEWS: Update.
* src/message.scm (message-reply-success): New procedure.Artyom Poptsov2013-11-031-7/+7
| | | | | | * src/message.scm (message-reply-success): New procedure. * examples/ssshd.scm (handle-req-auth, handle-req-channel, main): Use `message-reply-success'.
* examples/ssshd.scm (handle-req-auth): Handle public key state.Artyom Poptsov2013-11-031-4/+15
|
* src/message.scm (auth-req:pubkey-state): New procedure.Artyom Poptsov2013-11-021-2/+5
| | | | | | * src/message.scm (auth-req:pubkey-state): New procedure. * src/message-func.c (get_auth_req): Store public key state in the vector.
* examples/ssshd.scm: Add to the repository.Artyom Poptsov2013-11-022-2/+264
| | | | | * examples/ssshd.scm: Add to the repository. * examples/README: Update.
* examples/: Add to the repository.Artyom Poptsov2013-10-283-0/+248
* Makefile.am (SUBDIRS): Add examples/ * configure.ac: Add examples/Makefile * examples/: Add to the repository.