gnupg/common
Werner Koch b7fa4960c2
common: Minor fixes for the new private-keys.c.
* common/private-keys.c (my_error_from_syserror): New.  Use it in
place of gpg_error_from_syserror.
(_pkc_add, pkc_lookup, pke_next_value): Use ascii_strcasecmp.
(pkc_parse): Use xtrystrdup and append_to_strlist_try as intended.

(_pkc_add): Add braces around if-statement.
--

We should have a macro so that we do not need to define a wrapper
function like my_error_from_syserror in files where it is needed.  I
am not sure about a proper name, "my_" seems to be the easiest
replacement.  Note that the global DEFAULT_ERRSOURCE is relatively new
to replace the need to convey the error source in function calls; we
want that function from common/ return the error source of the main
binary.

We require that a key is ASCII and thus we better use ascii_strcasecmp
to avoid problems with strange locales.

Signed-off-by: Werner Koch <wk@gnupg.org>
2016-04-25 18:14:12 +02:00
..
ChangeLog-2011 Fix typos 2015-10-28 10:20:17 +01:00
ChangeLog-2011.include include: Remove this directory. 2014-01-29 17:45:05 +01:00
ChangeLog.jnlib common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
Makefile.am common: Add support for the new extended private key format. 2016-04-21 14:38:53 +02:00
README common: Update README. 2016-03-02 14:27:30 +01:00
agent-opt.c agent: Move a typedef to common and provide parse_pinentry_mode. 2013-02-06 12:56:19 +01:00
argparse.c Update copyright years. 2016-01-26 13:20:59 +01:00
argparse.h common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
asshelp.c common: New function get_assuan_server_version. 2016-01-08 06:42:29 +01:00
asshelp.h common: New function get_assuan_server_version. 2016-01-08 06:42:29 +01:00
asshelp2.c Switch to the libgpg-error provided estream. 2014-08-26 17:47:54 +02:00
audit.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
audit.h Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
b64dec.c Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
b64enc.c common: Avoid warnings about useless assignments. 2016-01-06 08:35:56 +01:00
call-gpg.c common: Use default_errsource for call-gpg and exectool. 2015-12-15 13:40:10 +01:00
call-gpg.h common: New file fwddecl.h. 2015-12-21 11:37:21 +01:00
common-defs.h common: Change license of some modules to LGPLv3+/GPLv2+. 2015-12-14 16:21:19 +01:00
convert.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
dotlock.c common: Make sure dotlock functions set a proper ERRNO. 2016-01-13 14:42:12 +01:00
dotlock.h common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
dynload.h common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
exaudit.awk Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
exechelp-posix.c common/exechelp: Provide a way to wait for multiple processes. 2016-02-23 11:58:52 +01:00
exechelp-w32.c common/exechelp: Provide a way to wait for multiple processes. 2016-02-23 11:58:52 +01:00
exechelp-w32ce.c common/exechelp: Provide a way to wait for multiple processes. 2016-02-23 11:58:52 +01:00
exechelp.h common/exechelp: Provide a way to wait for multiple processes. 2016-02-23 11:58:52 +01:00
exectool.c common: Make gnupg_exec_tool conform to spec. 2016-02-13 17:06:38 +01:00
exectool.h common: Change license for exectool to LGPLv3+/GPLv2+. 2015-12-14 16:21:19 +01:00
exstatus.awk Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
fwddecl.h common: New file fwddecl.h. 2015-12-21 11:37:21 +01:00
gc-opt-flags.h gpg: Add option --dirmngr-program. 2014-03-12 18:35:36 +01:00
get-passphrase.c common: New put_membuf_cb to replace static membuf_data_cb. 2016-01-08 06:33:27 +01:00
get-passphrase.h Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
gettime.c common: Add new function gnupg_gmtime. 2015-04-10 13:09:39 +02:00
gettime.h common: Change license of some modules to LGPLv3+/GPLv2+. 2015-12-14 16:21:19 +01:00
gnupg.ico w32: Add icons and version information. 2013-05-07 21:35:48 +02:00
gpgrlhelp.c Make use of the *_NAME etc macros. 2013-11-18 14:09:47 +01:00
helpfile.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
homedir.c Now build "gpg" binary but install as "gpg2" 2016-04-04 18:40:25 +02:00
host2net.h Use inline functions to convert buffer data to scalars. 2015-02-11 10:28:25 +01:00
i18n.c common,w32: Avoid unused var warning about msgcache. 2015-07-28 17:38:44 +02:00
i18n.h Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
init.c Add a hook to be called right after main. 2015-01-28 19:57:22 +01:00
init.h Add a hook to be called right after main. 2015-01-28 19:57:22 +01:00
iobuf.c gpg: Rename pop_filter to iobuf_pop_filter and export it. 2016-03-02 20:36:16 +01:00
iobuf.h gpg: Rename pop_filter to iobuf_pop_filter and export it. 2016-03-02 20:36:16 +01:00
isascii.c common: Change license of isascii.c to all-premissive, 2015-12-14 16:21:19 +01:00
keyserver.h common: Change license of some modules to LGPLv3+/GPLv2+. 2015-12-14 16:21:19 +01:00
localename.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
logging.c Avoid incompatible pointer assignment warnings on Windows. 2015-11-27 18:32:17 +01:00
logging.h common: Add log_assert. 2016-02-23 21:14:21 +01:00
mapstrings.c Typo fix. 2015-03-17 09:18:23 +01:00
mbox-util.c common: Add function is_valid_mailbox_mem. 2015-03-20 15:40:09 +01:00
mbox-util.h common: Add function is_valid_mailbox_mem. 2015-03-20 15:40:09 +01:00
membuf.c common: New put_membuf_cb to replace static membuf_data_cb. 2016-01-08 06:33:27 +01:00
membuf.h common: New put_membuf_cb to replace static membuf_data_cb. 2016-01-08 06:33:27 +01:00
miscellaneous.c common: Use new function to print a failure of xtrymalloc. 2016-04-25 17:26:57 +02:00
mischelp.c common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
mischelp.h Remove replacements for libgpg-error < 1.21. 2015-12-12 14:06:30 +01:00
mkdir_p.c common: Make sure tilde expansion works for the mkdir functions. 2015-10-20 12:17:46 +02:00
mkdir_p.h common: Prefix the mkdir functions with gnupg_. Make args const. 2015-10-16 16:40:40 +02:00
mkerrors Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
mkerrtok Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
mkstrtable.awk Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
openpgp-oid.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
openpgpdefs.h common: Provide a function for mapping packet types to strings. 2016-03-02 20:36:17 +01:00
percent.c Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
private-keys.c common: Minor fixes for the new private-keys.c. 2016-04-25 18:14:12 +02:00
private-keys.h common: Add support for the new extended private key format. 2016-04-21 14:38:53 +02:00
server-help.c common: Consolidate Assuan server argument handling. 2016-03-02 14:14:33 +01:00
server-help.h common: Consolidate Assuan server argument handling. 2016-03-02 14:14:33 +01:00
session-env.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
session-env.h Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
sexp-parse.h doc: Note that the persistant passphrase format is unimplemented. 2016-04-12 14:38:44 +02:00
sexputil.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
shareddefs.h agent: Move a typedef to common and provide parse_pinentry_mode. 2013-02-06 12:56:19 +01:00
signal.c Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
simple-pwquery.c common: Change simple_query to ignore status messages. 2016-02-12 22:12:21 +01:00
simple-pwquery.h common: Remove two JNLIB_ macros (jnlib merge). 2015-04-24 16:10:15 +02:00
ssh-utils.c ssh: Fix fingerprint computation for EdDSA key. 2015-09-29 15:33:59 +09:00
ssh-utils.h Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
status.c common: Change license of some modules to LGPLv3+/GPLv2+. 2015-12-14 16:21:19 +01:00
status.h Print warnings if old daemon versions are used. 2016-01-08 10:33:19 +01:00
stringhelp.c common: New function compare_version_strings. 2016-01-08 08:58:21 +01:00
stringhelp.h common: New function compare_version_strings. 2016-01-08 08:58:21 +01:00
strlist.c common: Use new function to print a failure of xtrymalloc. 2016-04-25 17:26:57 +02:00
strlist.h common: Add 'free_strlist_wipe' which wipes memory. 2016-04-21 14:38:53 +02:00
sysutils.c agent: Sanitize permissions of the private key directory. 2016-04-20 15:02:37 +02:00
sysutils.h agent: Sanitize permissions of the private key directory. 2016-04-20 15:02:37 +02:00
t-b64.c Change all quotes in strings and comments to the new GNU standard. 2012-06-05 19:29:22 +02:00
t-convert.c common: Do not deref vars in tests after a fail(). 2016-01-06 08:31:38 +01:00
t-dotlock.c Change all quotes in strings and comments to the new GNU standard. 2012-06-05 19:29:22 +02:00
t-exechelp.c Fixed set but unused variable bugs 2011-08-10 14:11:30 +02:00
t-gettime.c common: Add new function isodate_human_to_tm 2015-04-10 13:09:37 +02:00
t-helpfile.c Change all quotes in strings and comments to the new GNU standard. 2012-06-05 19:29:22 +02:00
t-iobuf.c common: Fix iobuf API of filter function for alignment. 2016-01-12 10:32:20 +09:00
t-mapstrings.c common: Do not deref vars in tests after a fail(). 2016-01-06 08:31:38 +01:00
t-mbox-util.c Move new mailbox.c source file to common/. 2015-02-25 11:43:50 +01:00
t-openpgp-oid.c gpg: Add --list-gcrypt-config and "curve" item for --list-config. 2015-03-10 15:35:30 +01:00
t-percent.c Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
t-private-keys.c common: Drop unused variables, fix warnings. 2016-04-21 15:35:37 +02:00
t-session-env.c Nuked almost all trailing white space. 2011-02-04 12:57:53 +01:00
t-sexputil.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
t-ssh-utils.c ssh: Fix fingerprint computation for EdDSA key. 2015-09-29 15:33:59 +09:00
t-stringhelp.c common: New function compare_version_strings. 2016-01-08 08:58:21 +01:00
t-strlist.c common: Add new function strlist_rev. 2015-11-06 11:03:50 +01:00
t-support.c common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
t-support.h Remove replacements for libgpg-error < 1.21. 2015-12-12 14:06:30 +01:00
t-sysutils.c Remove use of gnulib (part 2) 2014-11-11 15:14:31 +01:00
t-timestuff.c common: Do not deref vars in tests after a fail(). 2016-01-06 08:31:38 +01:00
t-w32-reg.c common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
t-zb32.c common: Improve t-zb32 to be used for manual encoding. 2015-10-30 12:40:22 +01:00
tlv.c common: Avoid warnings about useless assignments. 2016-01-06 08:35:56 +01:00
tlv.h Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
ttyio.c Fix typos found using codespell. 2015-11-17 12:50:22 +01:00
ttyio.h Change some keyedit functions to allow printing to arbitrary streams. 2014-03-27 12:59:55 +01:00
types.h Remove replacements for libgpg-error < 1.21. 2015-12-12 14:06:30 +01:00
userids.c common: Avoid warnings about useless assignments. 2016-01-06 08:35:56 +01:00
userids.h Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
utf8conv.c w32: Replace libiconv DLL by iconv feature of libgpg-error. 2016-04-21 09:17:11 +02:00
utf8conv.h gpgtar,w32: Fix gpgtar 8 bit encoding handling on W32 2016-01-26 09:53:42 +01:00
util.h common: Use new function to print a failure of xtrymalloc. 2016-04-25 17:26:57 +02:00
w32-afunix.c common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
w32-afunix.h Silence unused variable or parameter warnings. 2015-11-27 18:32:26 +01:00
w32-reg.c common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
w32help.h common: Remove JNLIB from boiler plate (jnlib merge). 2015-04-24 16:42:28 +02:00
w32info-rc.h.in Update copyright years. 2015-02-03 09:12:45 +01:00
xasprintf.c Switch to the libgpg-error provided estream. 2014-08-26 17:47:54 +02:00
xreadline.c Change license for some files in common to LGPLv3+/GPLv2+. 2012-04-20 15:48:48 +02:00
yesno.c common: Change license of some modules to LGPLv3+/GPLv2+. 2015-12-14 16:21:19 +01:00
zb32.c common: Add z-base-32 encoder. 2014-04-17 21:09:10 +02:00
zb32.h common: Add separate header for zb32.c. 2015-10-30 12:33:40 +01:00

README

Common functionality used by all modules of GnuPG.