aboutsummaryrefslogtreecommitdiffstats
path: root/agent/command-ssh.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Change all quotes in strings and comments to the new GNU standard.Werner Koch2012-06-051-6/+6
| | | | | | | | | | | | | | | | | | | The asymmetric quotes used by GNU in the past (`...') don't render nicely on modern systems. We now use two \x27 characters ('...'). The proper solution would be to use the correct Unicode symmetric quotes here. However this has the disadvantage that the system requires Unicode support. We don't want that today. If Unicode is available a generated po file can be used to output proper quotes. A simple sed script like the one used for en@quote is sufficient to change them. The changes have been done by applying sed -i "s/\`\([^'\`]*\)'/'\1'/g" to most files and fixing obvious problems by hand. The msgid strings in the po files were fixed with a similar command.
* Improve ssh card key diagnostic message.Werner Koch2011-11-281-2/+3
| | | | | | | * command-ssh.c (card_key_available): Change wording of no key diagnostic. (ssh_handler_request_identities): Do not call card_key_available if the scdaemon is disabled.
* Fixed set but unused variable bugsWerner Koch2011-08-101-2/+0
|
* Fix crash while reading unsupported ssh keys.Werner Koch2011-07-221-12/+6
| | | | | This bug was found by n-roeser at gmx.net (gnupg-devel@, msgid [email protected]).
* Support a confirm flag for ssh.Werner Koch2011-07-201-22/+133
| | | | | This implements the suggestion from bug#1349. With this change the fingerprint of the ssh key is also displayed in the pinentry prompts.
* Added gpg-agent OPTION "s2k-count".Ben Kibbey2011-06-291-1/+1
| | | | When unset or 0, the calibrated count will be used.
* Nuked almost all trailing white space.post-nuke-of-trailing-wsWerner Koch2011-02-041-62/+62
| | | | | | | | We better do this once and for all instead of cluttering all future commits with diffs of trailing white spaces. In the majority of cases blank or single lines are affected and thus this change won't disturb a git blame too much. For future commits the pre-commit scripts checks that this won't happen again.
* More agent support for gpg.Werner Koch2010-10-131-2/+2
|
* Exporting secret keys via gpg-agent is now basically supported.Werner Koch2010-10-011-2/+2
| | | | | | A couple of forward ported changes. Doc updates.
* s/CACHE_MODE_IMPGEN/CACHE_MODE_NONCE/.Werner Koch2010-09-011-1/+1
| | | | | Prepare for more use cases of the cache nonce.
* .Werner Koch2010-08-261-7/+5
|
* Whole lot of changes to support CE.Werner Koch2010-04-141-1/+2
|
* Merged jnlib into common.Werner Koch2010-03-101-1/+0
|
* Reworked passing of envars to Pinentry.Werner Koch2009-07-071-16/+28
|
* Fix bug #1053Werner Koch2009-05-151-12/+49
| | | | | Add option --qualitybar to command GET_PASSPHRASE.
* Marked all unused args on non-W32 platforms.Werner Koch2008-10-201-0/+15
|
* Fixed segv in gpg-agent (command marktrusted).Werner Koch2008-05-271-2/+2
| | | | | | Replaced almost all free by xfree. Translation fixes.
* Started to implement the audit log feature.Werner Koch2007-11-191-0/+4
| | | | | | | | Pass PINENTRY_USER_DATA and XAUTHORITY to Pinentry. Improved support for the quality bar. Minor internal restructuring. Translation fixes.
* 2007-10-15 Daiki Ueno <[email protected]> (wk)Werner Koch2007-10-151-3/+37
| | | | | | | | * command-ssh.c (reenter_compare_cb): New function; imported from genkey.c. (ssh_identity_register): Ask initial passphrase twice.
* Use Assuan socket wrapper calls.Werner Koch2007-10-011-5/+2
| | | | | Made socket servers secure under Windows.
* Changed to GPLv3.Werner Koch2007-07-041-4/+2
| | | | | Removed intl/.
* agent/Werner Koch2007-01-311-7/+15
| | | | | | | * command-ssh.c (stream_read_string): Initialize LENGTH to zero. (start_command_handler_ssh): Use es_fgetc/es_ungetc to check if EOF has been reached before trying to process another request.
* Made some PIN pads work.Werner Koch2006-11-201-25/+15
| | | | | Some cleanups for 64 bit CPUs.
* Preparing a new releasegnupg-1.9.90Werner Koch2006-09-251-2/+2
|
* Take advantage of newer gpg-error features.Werner Koch2006-09-141-40/+40
|
* Allow for 4k ssh keys and better error reporting.Werner Koch2006-08-291-0/+9
|
* Various smaller changesWerner Koch2006-06-271-11/+7
|
* Updated FSF's address.Werner Koch2006-06-201-2/+2
|
* 2006-04-09 Moritz Schulte <[email protected]>Moritz Schulte2006-04-091-5/+8
| | | | | | * command-ssh.c (ssh_request_process): Removed FIXME mentioning a possible DoS attack.
* 2006-04-01 Moritz Schulte <[email protected]>Moritz Schulte2006-04-011-3/+1
| | | | | | | * command-ssh.c (ssh_identity_register): Make KEY_GRIP_RAW be 20 instead of 21 bytes long; do not fill KEY_GRIP_RAW[20] with NUL byte - KEY_GRIP_RAW is a raw binary string anyway.
* Bug fixes and ssh support for the BELPIC.Werner Koch2005-09-091-21/+25
|
* (data_sign): Removed empty statement.Werner Koch2005-06-291-1/+1
|
* gcc-4 defaults forced me to edit many many files to get rid of theWerner Koch2005-06-161-42/+33
| | | | | | | char * vs. unsigned char * warnings. The GNU coding standards used to say that these mismatches are okay and better than a bunch of casts. Obviously this has changed now.
* New debugging optionhs, updates to the manual.Werner Koch2005-06-071-2/+3
|
* * call-scd.c (inq_needpin): Skip leading spaces in of PINWerner Koch2005-05-241-1/+1
| | | | | | | | | description. * divert-scd.c (getpin_cb): Enhanced to cope with description flags. * query.c (agent_askpin): Add arg PROMPT_TEXT. Changed all callers.
* 2005-05-05 Moritz Schulte <[email protected]>Moritz Schulte2005-05-051-31/+29
| | | | | | | * command-ssh.c: Use ssh_key_grip(), where gcry_pk_get_keygrip() has been used before. (ssh_handler_sign_request): Removed unusued variable P.
* 2005-05-05 Moritz Schulte <[email protected]>Moritz Schulte2005-05-051-38/+85
| | | | | | | * command-ssh.c (ssh_key_to_buffer): Rename to ... (ssh_key_to_protected_buffer): ... this; change callers. Improved documentation.
* 2005-04-20 Moritz Schulte <[email protected]>Moritz Schulte2005-04-201-3/+0
| | | | | | * command-ssh.c (ssh_handler_request_identities): Removed debugging code (sleep call), which was commited unintenionally.
* * configure.ac: Require libksba 0.9.11.Werner Koch2005-04-181-0/+1
| | | | | | | | | | | | sm/ * call-dirmngr.c (inq_certificate): Add new inquire SENDCERT_SKI. * certlist.c (gpgsm_find_cert): Add new arg KEYID and implement this filter. Changed all callers. * certchain.c (find_up_search_by_keyid): New helper. (find_up): Also try using the AKI.keyIdentifier. (find_up_external): Ditto.
* 2005-04-03 Moritz Schulte <[email protected]>Moritz Schulte2005-04-091-60/+97
| | | | | | | | | | * command-ssh.c (ssh_request_spec): New member: secret_input. (REQUEST_SPEC_DEFINE): New argument: secret_input. (request_specs): Add secret_input flag. (request_spec_lookup): New function ... (ssh_request_process): ... use it here; depending on secret_input flag allocate secure or non-secure memory.
* * acinclude.m4 (GNUPG_PTH_VERSION_CHECK): Accidently usedWerner Koch2005-03-031-1/+1
| | | | | | | | | --ldflags instead of --cflags. Reported by Kazu Yamamoto. * Makefile.am (AM_CFLAGS): Added PTH_CFLAGS. Noted by Kazu Yamamoto. * Makefile.am (gpgsm_LDADD): Added PTH_LIBS. Noted by Kazu Yamamoto.
* 2005-03-02 Moritz Schulte <[email protected]>Moritz Schulte2005-03-021-28/+49
| | | | | | | | | | | | | | | | | | | | | | * command-ssh.c (sexp_key_extract): Removed FIXME, since xtrymallos does set errno correctly by now. (sexp_extract_identifier): Remove const attribute from identifier. (ssh_handler_request_identities): Remove const attribute from key_type; removes ugly casts and FIXME. (sexp_key_extract): Remove const attribute from comment. (ssh_send_key_public): Remove const attribute from key_type/comment; removes ugly cast. (data_sign): Remove const attribute from identifier; removes ugly cast. (key_secret_to_public): Remove const attribute from comment; removes ugly cast. (ssh_handler_sign_request): Remove const attribute from p. (sexp_key_extract): Use make_cstring(). (ssh_key_extract_comment): Likewise. (ssh_key_to_buffer): Use secure memory for memory area to hold the key S-Expression. Added more comments.
* * findkey.c (modify_description): Keep invalid % escapes, so thatWerner Koch2005-02-251-28/+128
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | %0A may pass through. * agent.h (server_control_s): New field USE_AUTH_CALL. * call-scd.c (agent_card_pksign): Make use of it. * command-ssh.c (data_sign): Set the flag. (ssh_send_key_public): New arg OVERRIDE_COMMENT. (card_key_available): Add new arg CARDSN. (ssh_handler_request_identities): Use the card s/n as comment. (sexp_key_extract): Use GCRYMPI_FMT_STD. (data_sign): Ditto. * learncard.c (make_shadow_info): Moved to .. * protect.c (make_shadow_info): .. here. Return NULL on malloc failure. Made global. * agent.h: Add prototype. * xasprintf.c (xtryasprintf): New. * app-openpgp.c (get_public_key): Make sure not to return negative numbers. (do_sign): Allow passing of indata with algorithm prefix. (do_auth): Allow OPENPGP.3 as an alternative ID. * app.c (app_getattr): Return just the S/N but not the timestamp. * no-libgcrypt.c (gcry_strdup): New.
* * call-scd.c (unescape_status_string): New. Actual a copy ofWerner Koch2005-02-241-66/+142
| | | | | | | | | | | | | | | | | | | | | | ../g10/call-agent.c (card_getattr_cb, agent_card_getattr): New. * command-ssh.c (card_key_available): New. (ssh_handler_request_identities): First see whether a card key is available. * app.c (app_getattr): Return APPTYPE or SERIALNO type even if the application does dot support the getattr call. * app.c (select_application): Return an error code and the application context in an new arg. * command.c (open_card): Adjusted for that. Don't use the fallback if no card is present. Return an error if the card has been removed without a reset. (do_reset, cmd_serialno): Clear that error flag. (TEST_CARD_REMOVAL): New. Use it with all command handlers. (scd_update_reader_status_file): Set the error flag on all changes.
* * command-ssh.c (get_passphrase): Removed.Werner Koch2005-02-231-76/+287
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (ssh_identity_register): Partly rewritten. (open_control_file, search_control_file, add_control_entry): New. (ssh_handler_request_identities): Return only files listed in our control file. * findkey.c (unprotect): Check for allocation error. * agent.h (opt): Add fields to record the startup terminal settings. * gpg-agent.c (main): Record them and do not force keep display with --enable-ssh-support. * command-ssh.c (start_command_handler_ssh): Use them here. * gpg-agent.c: Renamed option --ssh-support to --enable-ssh-support. * command.c (cmd_readkey): New. (register_commands): Register new command "READKEY". * command-ssh.c (ssh_request_process): Improved logging. * findkey.c (agent_write_private_key): Always use plain open. Don't depend on an umask for permissions. (agent_key_from_file): Factored file reading code out to .. (read_key_file): .. new function. (agent_public_key_from_file): New.
* (stream_read_string): Removed call to abort onWerner Koch2005-02-221-8/+5
| | | | | | | memory error because the CVS version of libgcrypt makes sure that ERRNO gets always set on error even with a faulty user supplied function.
* 2005-02-19 Moritz Schulte <[email protected]>Moritz Schulte2005-02-191-38/+77
| | | | | | | | | | | | | | | | * command-ssh.c (ssh_receive_mpint_list): Slightly rewritten, do not use elems_secret member of key_spec. (ssh_key_type_spec): Removed member: elems_secret. (ssh_key_types): Removed elems_secret data. (ssh_sexp_construct): Renamed to ... (sexp_key_construct): ... this; changed callers. (ssh_sexp_extract): Renamed to ... (sexp_key_extract): ... this; changed callers. (ssh_sexp_extract_key_type): Renamed to ... (sexp_extract_identifier): ... this; changed callers; use make_cstring(). Added more comments.
* 2005-02-18 Moritz Schulte <[email protected]>Moritz Schulte2005-02-181-111/+39
| | | | | | | | | | * command-ssh.c (ssh_sexp_construct): Rewritten generation of sexp template, clarified. (ssh_sexp_extract): Support shadowed-private-key-sexp; treat protected-private key and shadowed-private-key as public keys. (key_secret_to_public): Rewritten: simply use ssh_sexp_extract() and ssh_sexp_construct().
* 2005-02-14 Moritz Schulte <[email protected]>Moritz Schulte2005-02-141-17/+12
| | | | | | * command-ssh.c (uint32_construct): New macro ... (stream_read_uint32): ... use it; removed unnecessary cast.
* 2005-02-14 Moritz Schulte <[email protected]>Moritz Schulte2005-02-141-128/+121
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * command-ssh.c (es_read_byte): Renamed to ... (stream_es_read_byte): ... this; changed callers. (es_write_byte): Renamed to ... (stream_write_byte): ... this; changed callers. (es_read_uint32): Renamed to ... (stream_read_uint32): ... this; changed callers. (es_write_uint32): Renamed to ... (stream_write_uint32): ... this; changed callers. (es_read_data): Renamed to ... (stream_read_data): ... this; changed callers. (es_write_data): Renamed to ... (stream_write_data): ... this; changed callers. (es_read_string): Renamed to ... (stream_read_string): ... this; changed callers. (es_read_cstring): Renamed to ... (stream_read_cstring): ... this; changed callers. (es_write_string): Renamed to ... (stream_write_string): ... this; changed callers. (es_write_cstring): Renamed to ... (stream_write_cstring): ... this; changed callers. (es_read_mpi): Renamed to ... (stream_read_mpi): ... this; changed callers. (es_write_mpi): Renamed to ... (stream_write_mpi): ... this; changed callers. (es_copy): Renamed to ... (stream_copy): ... this; changed callers. (es_read_file): Renamed to ... (file_to_buffer): ... this; changed callers. (ssh_identity_register): Removed variable description_length; changed code to use asprintf for description. (stream_write_uint32): Do not filter out the last byte of shift expression.