aboutsummaryrefslogtreecommitdiffstats
path: root/src (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* Add a no_logging flag.Werner Koch2010-09-015-1/+21
|
* Prepare for a gpg-error changeWerner Koch2010-08-191-1/+1
|
* doc changesWerner Koch2010-08-112-7/+6
|
* Add ASSUAN_CONVEY_COMMENTS flag.Werner Koch2010-08-117-9/+45
|
* 2010-08-03 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-08-032-43/+263
| | | | | | | | | | | | | * gpgcedev.c (GPGCEDEV_IOCTL_ASSIGN_RVID): New call ASSIGN_RVID. (PIPE_FLAG_HALT_MONITOR): New flag. (struct pipeimpl_s): New members monitor_proc, monitor_access. (pipeimpl_new): Initialize them. (assert_pipeimpl): New function. (access_opnctx, make_pipe): Use it. (make_pipe): If there is a monitor, halt it. (monitor, assign_rvid): New functions. (GPG_IOControl): Handle GPGCEDEV_IOCTL_ASSIGN_RVID.
* 2010-08-03 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-08-022-94/+114
| | | | | | | | * gpgcedev.c: Use index (between 1 and table size) into opnctx_table as public context identifiers, instead using pointers into the table directly (which are not stable under table resize). (OPNCTX_TO_IDX, OPNCTX_FROM_IDX, OPNCTX_VALID_IDX_P): New macros.
* Handle NOTIFY event.Werner Koch2010-06-293-3/+187
|
* 2010-06-11 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-06-103-4/+44
| | | | | | | | | | | | * assuan-handler.c (std_handler_input, std_handler_output) [HAVE_W32CE_SYSTEM]: Finish the pipe. We must do this here, because otherwise assuan_close_input_fd() and assuan_close_output_fd() can't work. * system-w32ce.c (_assuan_w32ce_finish_pipe): Call SetLastError in error case. (__assuan_close): Save WSAGetLastError before trashing it! Otherwise handle is never closed and GPGME hangs.
* 2010-06-10 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-06-103-0/+50
| | | | | | | | | * w32ce-add.h (ASSUAN_STDIN, ASSUAN_STDOUT): Define magic handle values. * system-w32ce.c (__assuan_read, __assuan_write): Handle magic handle values differently. * system-w32ce.c (_assuan_w32ce_finish_pipe): Return error on RVID 0.
* 2010-06-09 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-06-092-0/+81
| | | | | | | | | | | * gpgcedev.c (GPGCEDEV_IOCTL_UNBLOCK): New ioctl. (PIPE_FLAG_UNBLOCK_READER, PIPE_FLAG_UNBLOCK_WRITER): New flags. (GPG_Read): Check if PIPE_FLAG_UNBLOCK_READER is set and return ERROR_BUSY in that case. (GPG_Write): Likewise for PIPE_FLAG_UNBLOCK_WRITER. (unblock_call): New function. (GPG_IOControl): Implement GPGCEDEV_IOCTL_UNBLOCK.
* 2010-06-07 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-06-072-275/+373
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gpgcedev.c: This rewrite does away with troublesome race conditions (close vs everything else, for example) by simplifying the locking model. It also handles EOF, EPIPE, but still assumes that there is always only ever one reader and writer. Also, no need to treat ERROR_PIPE_NOT_CONNECTED and ERROR_BUSY as EAGAIN anymore. (struct pipeimpl_s, pipeimpl_t): New types. (PIPE_FLAG_NO_READER, PIPE_FLAG, NO_WRITER): New macros. (struct opnctx_s): Remove everything that's now in struct pipeimpl_s. Remove also assoc and locked. Add pipeimpl field. (pipeimpl_new, pipeimpl_unref, allocate_opnctx, verify_opnctx, access_opnctx): New functions. (get_new_opnctx, find_and_lock_opnctx, validate_and_lock_opnctx, unlock_opnctx): Removed. (GPG_Init, GPG_Deinit): Improve debugging output. (GPG_Open): Improve debugging output, use allocate_opnctx instead of get_new_opnctx. (GPG_Close): Improve debugging output. Rewrite to use reference counting. Also check if reader or writer is closed and set flags for triggering EOF or EPIPE. (GPG_Read): Improve debugging output. Rewrite using pipeimpl. Check for EOF. (GPG_Write): Improve debugging output. Rewrite using pipeimpl. Check for EPIPE. (make_pipe): Rewrite using pipeimpl. (GPG_IOControl): Improve debugging output.
* Sho the pid in the the hello line.Werner Koch2010-04-222-1/+17
|
* More robust detection of socketsWerner Koch2010-04-192-47/+90
|
* 2010-04-16 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-04-162-2/+10
| | | | | | * assuan-uds.c (uds_reader, uds_sendfd): Don't break strict aliasing rules.
* Rename device driver during installWerner Koch2010-04-142-0/+8
|
* Changes for W32CEWerner Koch2010-04-147-12/+49
|
* 2010-04-14 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-04-142-1/+5
| | | | | * Makefile.am (EXTRA_DIST): Add gpgcedev.def.
* Removed sysdep stuff from assuan.h.Werner Koch2010-04-0615-163/+484
| | | | | fixed a problem for W32CE and Pth.
* typo fixes and fix w32ce message formattingWerner Koch2010-03-303-2/+10
|
* Do not distribute assuan.h.Werner Koch2010-03-224-3/+35
|
* Changed the implementation of CreatePipe under W32CE.Werner Koch2010-03-2212-309/+687
| | | | | Reorganized the source.
* Refactored platform system code.Werner Koch2010-03-166-650/+1296
|
* Cleaned up the loggingWerner Koch2010-03-118-153/+247
|
* Add options and documentation for gpgcedev.Werner Koch2010-03-052-3/+75
|
* A couple of changes to eventually fully support W32ce.Werner Koch2010-02-2415-60/+1216
|
* 2010-02-03 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-02-033-1/+6
| | | | | * libassuan.vers, libassuan.def: Add assuan_set_sock_nonce.
* Cleanups for W32CE.Werner Koch2010-01-2810-8/+198
| | | | | Implement getenv replacement for W32CE.
* Changes to build for W32CE - does not yet work, though.Werner Koch2010-01-224-4/+19
|
* Prepare for a port to WindowsCE.Werner Koch2010-01-228-42/+49
|
* Fix NULL de-reference in debug code.Werner Koch2010-01-143-7/+16
|
* 2010-01-05 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-01-051-1/+3
| | | | | * configure.ac (_DARWIN_C_SOURCE): Define on frapple.
* 2010-01-05 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-01-054-3/+78
| | | | | | | | * debug.h (TRACE_LOG5): Add macro. * debug.c (_assuan_debug_buffer): Add newline * system.c: Add more debug output (conditioned on the compile-time DEBUG_SYSIO macro).
* Add comments.Marcus Brinkmann2010-01-051-2/+7
|
* Return and parse comment lines with the assuan_client_ functions.Werner Koch2009-12-143-6/+24
|
* Another one.Marcus Brinkmann2009-12-081-1/+1
|
* 2009-12-08 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-12-082-1/+4
| | | | | | * assuan.h (struct assuan_system_hooks): Don't use "namespace" as argument name in declaration (C++ keyword).
* 2009-12-08 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-12-082-0/+3
| | | | | * client.c (assuan_client_read_response): Fix linelen.
* doc/Marcus Brinkmann2009-12-083-1/+11
| | | | | | | | | | | | | | 2009-12-08 Marcus Brinkmann <[email protected]> * assuan.texi (Contexts): Document ASSUAN_SPAWN_DETACHED. src/ 2009-12-08 Marcus Brinkmann <[email protected]> * assuan.h (ASSUAN_SPAWN_DETACHED): New macro. * assuan-pipe-connect.c (pipe_connect): Calculate spawn_flags from flags.
* Fix changelog.Marcus Brinkmann2009-12-081-1/+1
|
* 2009-12-08 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-12-082-1/+6
| | | | | * assuan_fd_from_posix_fd (assuan_fd_from_posix_fd): Handle invalid fd early.
* 2009-12-08 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-12-086-21/+49
| | | | | | | | | | | | | | | | | | * assuan-socket.c (get_nonce): Cast buffer to unsigned. (_assuan_sock_connect) [HAVE_W32_SYSTEM]: Drop ctx argument from read_port_and_nonce invocation. * system.c (assuan_fdopen) [HAVE_W32_SYSTEM]: Fix typo in variable name. (__assuan_spawn) [HAVE_W32_SYSTEM]: Fix types of fd and fdp. Use ASSUAN_INVALID_FD. Add missing context argument to _assuan_free, and fix call to _assuan_w32_strerror. Set errno on error. (__assuan_socketpair) [HAVE_W32_STRERROR]: Fix type of filedes argument. * assuan-pipe-connect.c (pipe_connect, assuan_pipe_connect, socketpair_connect) [HAVE_W32_SYSTEM]: Fix type of fd_child_list. * assuan-defs.h (_assuan_socketpair): Likewise for prototype. * assuan.h (assuan_fd_from_posix_fd): New static inline function.
* 2009-12-03 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-12-032-2/+28
| | | | | | | | | | * assuan-logging.c: (log_cats): New static variable. (TEST_LOG_CAT): New macro. (_assuan_log_handler): Check log category. (assuan_set_assuan_log_stream): Check ASSUAN_DEBUG for logging categories. (assuan_set_log_stream): Call assuan_set_assuan_log_stream.
* src/Marcus Brinkmann2009-12-0210-242/+304
| | | | | | | | | | | | | | | | | | | | | | | | | | 2009-12-02 Marcus Brinkmann <[email protected]> * Makefile.am (common_sources): Remove assuan-client.c. * assuan-client.c: File removed. * assuan.h (ASSUAN_RESPONSE_ERROR, ASSUAN_RESPONSE_OK) (ASSUAN_RESPONSE_STATUS, ASSUAN_RESPONSE_INQUIRE) (ASSUAN_RESPONSE_STATUS): New macros. (assuan_response_t): New type. (assuan_client_read_response, assuan_client_parse_response): New prototypes. * libassuan.def, libassuan.vers: Add assuan_client_read_response, assuan_client_parse_response. * assuan-client.c (xtoi_1, xtoi_2, assuan_transact) (_assuan_read_from_server): Moved to ... * client.c: ... here, with updates to use new functions and types. Include <stdlib.h>. (assuan_client_read_response, assuan_client_parse_response): New functions. * assuan-defs.h (_assuan_read_from_server): Use assuan_response_t. * assuan-pipe-connect.c (initial_handshake): Use assuan_response_t and ASSUAN_RESPONSE_OK. * assuan-socket-connect.c (assuan_socket_connect): Likewise.
* 2009-12-01 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-12-012-3/+10
| | | | | * assuan-pipe-server.c (assuan_init_pipe_server): Fix debug output.
* 2009-11-27 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-11-2713-63/+143
| | | | | | | | | | | | | | | | | | | * assuan.h (assuan_set_assuan_log_stream): Add prototype. * libassuan.def, libassuan.vers: Add back assuan_set_assuan_log_stream. * assuan-logging.c (assuan_set_assuan_log_stream): Add back. * context.c (assuan_get_pointer): Don't output debug info here. (assuan_get_peercred, assuan_get_pid): But do here. * system.c: Improve debug output. * assuan-defs.h (struct assuan_context_s): Rename pipe_mode to max_accepts. * assuan-listen.c (assuan_accept): Rework max accepts logic. * assuan-socket-server.c (assuan_init_socket_server), assuan-socket-connect.c (assuan_socket_connect), assuan-pipe-server.c (assuan_init_pipe_server), assuan-pipe-connect.c (socketpair_connect): Add debug output, set max_accepts instead of pipe_mode.
* doc/Marcus Brinkmann2009-11-256-9/+42
| | | | | | | | | | | | | | | | | | | | 2009-11-25 Marcus Brinkmann <[email protected]> * assuan.texi (Data Types): Document assuan_fdopen. src/ 2009-11-25 Marcus Brinkmann <[email protected]> * assuan.h (assuan_init_pipe_server): Change type of filedes to assuan_fd_t. (assuan_fdopen): New prototype. * libassuan.vers, libassuan.def: Add assuan_fdopen. * system.c (assuan_fdopen): New function. * assuan-pipe-server.c (assuan_init_pipe_server): Change type of filedes to assuan_fd_t. No longer translate fd to handle. Don't set to binary either (that doesn't do anything for handles, it only affects the libc fd).
* doc/Marcus Brinkmann2009-11-244-10/+23
| | | | | | | | | | | | | | | 2009-11-24 Marcus Brinkmann <[email protected]> * assuan.texi: Remove assuan_disconnect, assuan_deinit_server. Many smaller API fixes. src/ 2009-11-24 Marcus Brinkmann <[email protected]> * assuan.h (struct _assuan_peercred) [_WIN32]: Define dummy member so struct is not empty. * assuan-socket.c (assuan_sock_deinit): Set sock_ctx to NULL.
* 2009-11-19 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-11-1912-192/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.am (common_sources): Remove assuan-connect.c and add client.c. * client.c, server.c: New file. * assuan-defs.h (_assuan_disconnect): Remove. (struct assuan_context_s): Remove members deinit_handler. (_assuan_client_release, _assuan_client_finish) (_assuan_server_finish, _assuan_server_release): New. * assuan-socket-server.c (accept_connection_bottom): Use ASSUAN_INVALID_PID, not -1. (finish_connection, deinit_socket_server): Remove. (assuan_init_socket_server): Use _assuan_server_release. * assuan-socket-connect.c (do_finish, do_deinit): Remove. (assuan_socket_connect): Use _assuan_client_release. * assuan-pipe-connect.c (do_finish, do_deinit): Remove. (pipe_connect): Update deinitialization. (socketpair_connect): Here as well. * context.c (assuan_get_pid): New from ... * assuan-connect.c (assuan_get_pid): ... here. Remove this file. * assuan-pipe-server.c (_assuan_deinit_server, accept_connection) (deinit_pipe_server, finish_connection): Remove unused function. * assuan-listen.c (assuan_accept): Check CTX->accept_handler before calling. Initialize RC. Do not call finish handler for pipe server. * assuan-uds.c (_assuan_uds_deinit): Do not call finish handler.
* 2009-11-10 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-11-106-67/+58
| | | | | | | | | | | | | | | | * assuan-defs.h (struct assuan_context_s): Rename CTX->process_done to CTX->process_complete for clarity. Remove buffer variables from UDS. * assuan-pipe-connect.c (socketpair_connect): Allow FD_CHILD_LIST to be NULL. * assuan-handler.c: Rename CTX->process_done to CTX->process_complete for clarity. (process_request, process_next): Handle EOF. * assuan-uds.c (uds_reader): Remove buffering, which breaks the pending line algorithm in assuan-buffer.c. (_assuan_init_uds_io, _assuan_uds_deinit): Remove buffering. * assuan-buffer.c (_assuan_read_line): Add comment.
* 2009-11-05 Marcus Brinkmann <[email protected]>Marcus Brinkmann2009-11-0510-158/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * tests/fdpassing.c (main): Call assuan_pipe_connect instead of assuan_pipe_connect_ext. doc/ 2009-11-05 Marcus Brinkmann <[email protected]> * assuan.texi (Client code): Document ASSUAN_PIPE_CONNECT_FDPASSING and ASSUAN_PIPE_CONNECT_DETACHED. (Server code): Document ASSUAN_SOCKET_SERVER_FDPASSING and ASSUAN_SOCKET_SERVER_ACCEPTED. (Utilities): Update documentation of assuan_get_peercred. src/ 2009-11-05 Marcus Brinkmann <[email protected]> * assuan.h (struct _assuan_peercred, assuan_peercred_t): New. (assuan_get_peercred): Define on all systems, return assuan_peercred_t. * assuan-defs.h (struct assuan_context_s): Move valid flag out of peercred struct, use struct _assuan_peercred. * libassuan.def: Add assuan_get_peercred. * assuan-connect.c (assuan_get_peercred): Moved to ... * context.c (assuan_get_peercred): ... here. Reimplement. * assuan-socket-server.c (accept_connection_bottom): Adjust access to peercred in context. * assuan.h (ASSUAN_PIPE_CONNECT_FDPASSING) (ASSUAN_PIPE_CONNECT_DETACHED, ASSUAN_SOCKET_SERVER_FDPASSING) (ASSUAN_SOCKET_SERVER_ACCEPTED, ASSUAN_SOCKET_CONNECT_FDPASSING): New. (assuan_pipe_connect_ext): Renamed to ... (assuan_pipe_connect): ... this, overwriting old prototype. (assuan_socket_connect_ext): Renamed to ... (assuan_socket_connect): ... this, overwriting old prototype. (assuan_init_socket_server_ext): Renamed to ... (assuan_init_socket_server): ... this, overwriting old prototype. * assuan-pipe-connect.c: Likewise for functions. * assuan-socket-connect.c: Likewise. * assuan-socket-server.c: Likewise. * libassuan.def (assuan_init_socket_server_ext) (assuan_pipe_connect_ext, assuan_socket_connect_ext): Removed. * libassuan.vers: Likewise.