Commit graph

71 commits

Author SHA1 Message Date
tnn
e0244102bf netpgpverify: add configure quirks to get strtoull on legacy platforms 2022-04-03 22:22:55 +00:00
wiz
1d20f6e95f netpgpverify: update to 20201101
Merge:
absorb issuer fingerprint (RFC4880bis 5.2.3.28) in libverify.c
from jhigh from src/

While here, fix build with RELRO and a pkglint warning.

Bump version to 20201101.
2020-11-01 11:28:35 +00:00
agc
a8091f9d3a Rename files so that we pick up the correct header file.
Add the map file for the BSD Makefile's symbol exports.
2020-05-04 19:13:13 +00:00
agc
f04dba6d7d Bump version of libnetpgpverify and netpgpverify to 20200504 for changes
brought over from src.
2020-05-04 01:39:59 +00:00
agc
972dbac7eb bring over changes from src - cast return values 2020-05-04 01:37:54 +00:00
agc
862a1a5330 bring over change from src - cast return values 2020-05-04 01:37:28 +00:00
agc
d7865b1cab Bring over change from src - properly cite authors of RFC 4880 2020-05-04 01:36:40 +00:00
agc
405e2ed187 Update netpgpverify and libnetpgpverify to version 20200503
ensure all exported functions use a unique prfix, so that they don't
conflict with symbols (both data and text) in libcrypto. this works for
statically linked binaries and libraries, rather then the version map which
only works for dynalically-linked.
2020-05-03 23:49:04 +00:00
rillig
b686dd9180 all: migrate several HOMEPAGEs to https
pkglint --only "https instead of http" -r -F

With manual adjustments afterwards since pkglint 19.4.4 fixed a few
indentations in unrelated lines.

This mainly affects projects hosted at SourceForce, as well as
freedesktop.org, CTAN and GNU.
2020-01-18 23:30:43 +00:00
agc
7137d02e07 Bump netpgpverify and libnetpgpverify to 20191003 - fix problem
pointed out by mrg and gcc8:

+ don't read an automatic array element we haven't already written
2019-10-03 20:18:12 +00:00
agc
c6d7b79a20 Update netpgpverify and libnetpgpverify to 20190117
jperkin reported a bootstrapping failure in the newer pre-processor
conditionals, so revert to the older, less comprehensive versions without
gcc version level checks.
2019-01-17 17:26:23 +00:00
agc
2378b53c48 Update netpgpverify and libnetpgpverify to 20190111
Changes since previous version:

+ fuller emulation of openssl API, including

	BN_is_one()
	BN_mod_add()
	BN_mod_sub()
	BN_sub_word()
	BN_add_word()

+ provide all functions and macros with compatibility definitions
2019-01-16 00:33:12 +00:00
jmcneill
41048bcac4 Provide PRIi64 definition where it doesn't exist (like IRIX). 2018-03-11 04:52:03 +00:00
jperkin
063acb04a4 netpgpverify: Update to 20171019.
Changes since 20170201:

  + Don't overwrite error messages generated by time checks, now the correct
    error is printed instead of the generic "Signature does not match".

  + Remove extraneous newlines from time check errors.

Ok'd agc@
2017-10-19 08:23:21 +00:00
joerg
3d1204bc1c Remove unused/empty distinfo files. 2017-03-23 13:07:24 +00:00
agc
450382b0c6 update netpgpverify and libnetpgpverify to 20170201
+ make sure howmany() macro is defined

pointed out by cube - thanks!
2017-02-01 18:09:26 +00:00
agc
6e156d9f59 Update netpgpverify and libnetpgpverify to 20160828
+ bring over change from christos in src/crypto to check for
the end of an ASCII-armored signature

+ no need for namespace protection in array.h any more, now
that netpgp/verify.h now contains opaque structures

+ minor typo clean-up in a definition (benign, ignored by compiler)
2016-08-28 23:23:40 +00:00
agc
c70cf48c64 Update netpgpverify and libnetpgpverify to 20160709
+ free resources associated with the cursor when verifying,
gets rid of 2 more loss records under valgrind.
2016-07-09 17:44:44 +00:00
agc
1619422bb9 Update netpgpverify and libnetpgpverify to 20160708
+ clear and free bignums properly - helps immensely with plugging
memory leaks
2016-07-09 17:18:24 +00:00
agc
3aedfb8bb2 Update netpgpverify and libnetpgpverify to 20160707 to fix some
unusual build errors shown by old gcc versions (works fine for
gcc-5.2.1 on ubuntu and gcc-5.3.0 on NetBSD 7.99.32)

+ use ULL suffix on unsigned 64bit constants, not UL

+ don't typedef the public structs twice - second time just define it
without the typedef

Fixes PR pkg/51327
2016-07-08 17:45:41 +00:00
agc
676cdf183e Update netpgpverify and libnetpgpverify to 20160706
+ 20160705 introduced a bug whereby a key subid would match and verify
fine, but, if formatted, would not display the correct subkey
information.  Fix to show the correct information in this case.
2016-07-08 16:21:10 +00:00
agc
3ff1409ef8 Update netpgpverify and libnetpgpverify to 20160705
External API changes
====================
+ add a pgpv_cursor_close() function to free resources associated with
a cursor

Better memory management
========================
+ restructure the way dynamic arrays are used, to avoid memory
corruption issues and memory leaks - keep all dynamic arrays in the global
data structure, and use indices in the other data structures to index them.
Means lack of data localisation, but avoids stale pointers, and leaks.

+ make signer field of signature a uint8_t array, rather than a pointer

+ use our own version of strdup(3) - don't depend on it being
available in standard library

+ keep track of whether litdata filenames and userid were allocated or not,
and free memory in pgpv_close() if it was allocated

+ free up allocated resources which were allocated in pgpv_close()
2016-07-08 15:56:46 +00:00
agc
588f2ee2ef Update netpgpverify and libnetpgpverify to 20160704
+ get rid of redundant PGPV_ARRAY definition in libverify.c, brought in when
the definitions moved from verify.h

+ fix obuf_add_mem() to use a const void *, as any struct can be
dumped using it

+ remove redundant NO_SUBKEYS definition - unused

+ add an (unused as yet) ARRAY_FREE() macro
2016-07-05 23:56:07 +00:00
agc
4f2d06c735 Update netpgpverify and libnetpgpverify to 20160626
+ make the pgpv_t and pgpv_cursor_t structures opaque

+ add new accessor functions for fields in the pgpv_cursor_t struct

+ add new creation functions for the pgpv_t and pgpv_cursor_t structs
2016-07-05 20:18:03 +00:00
agc
6f7acbaf3f Update netpgpverify and libnetpgpverify to 20160625
+ Perform digest on correctly dash-escaped text, per RFC 4880.
Problem pointed out by Dimitri John Ledkov, fixed in a different way
(in case the last line is itself dash-escaped).

+ add test case
2016-06-30 21:19:59 +00:00
agc
7a3207d024 Update netpgpverify and libnetpgpverify to 20160624
+ Get rid of the tiger digest - only specified in RFC 2440, not specified
in RFC 4880.
2016-06-30 21:10:59 +00:00
agc
6485a3d0fe Update netpgpverify and libnetpgpverify to 20160623
+ remove use of asprintf and vasprintf from libverify. Inspired
by work from Dimitri John Ledkov. Should allow building on Linux
without superfluous definitions.

+ also free the BIGNUM struct in PGPV_BN_clear() - from Dimitri
John Ledkov
2016-06-30 21:03:51 +00:00
agc
0ea1820975 Update netpgpverify and libnetpgpverify to 20160622 during freeze to fix
PR/51262

+ take a bit of a step backwards, and don't use stdbool.h, just to appease
Solaris 10 compiler
2016-06-23 17:40:04 +00:00
agc
a34eed1c00 Update netpgpverify and libnetpgpverify to 20160617
+ don't assume memory will be NUL-terminated when printing
2016-06-15 20:28:48 +00:00
agc
e68cd12527 Update netpgpverify and libnetpgpverify to 20160616
+ bring over joerg's printflike change from the netpgpverify
version in src/crypto

+ add a test for cleartext signatures with version information
to complement the one with no version information
2016-06-15 16:45:10 +00:00
agc
26b259a92a Update netpgpverify and libnetpgpverify to 20160615:
Simplify the method of finding the end of the versioning information
in the signature - back up to the "\n" character at the end of the
signature start:

	"-----BEGIN PGP SIGNATURE-----\n"

and then find the "\n\n" character sequence to denote the start of the
signature itself. The previous version worked, but this is more efficient.
2016-06-15 03:34:15 +00:00
agc
30362ddc5d Update netpgpverify (and libnetpgpverify) to 20160614
+ handle signatures created by gpg with "--no-emit-version", don't assume
there will always be a version string.

+ add a test for above

Fixes security PR/51240.

Thanks to xnox@ubuntu.com for reporting the error
2016-06-14 18:00:59 +00:00
agc
3bec3c2cc4 Update netpgpverify to 20160313
+ minor cosmetic change to bn.h to also define BN_mod_sub, missed in
  previous
2016-06-03 00:11:10 +00:00
agc
78b956e3d3 Remove an item from the netpgpverify/libnetpgpverify TODO list:
+ get rid of calls to snprintf which simply add the returned value to
the number of characters used so far. This practice is unsafe. Instead,
use a dynamic buffer and grow its size to accommodate the contents.

+ add USE_ARG definition to some files which use it but don't check to
see that it's been defined

pkgsrc changes:

+ Bump version number to 20160214

+ Use the same method as libnetpgpverify for finding the version number
from the sources.
2016-02-19 22:41:50 +00:00
agc
c5b3a42432 Update netpgpverify to 20151103
Changes since previous version:

+ fix a bug where SHA512 case was missed in the digest_get_prefix()
  function. Bug and fix from Felix Lange.
2015-11-03 16:50:32 +00:00
agc
268913a35b Update netpgpverify to 20150930.
Changes since 20150919:

+ fixed minor bug in BN_rand() function - used field wasn't set

+ added BN_gcd() function

+ added translation layer in header file, so that library
can be called as a BIGNUM/BN_* replacement if USE_BN_INTERFACE
is defined at compile-time
2015-10-01 01:14:07 +00:00
agc
751677a63d Update netpgpverify, and libnetpgpverify, from version 20150911 to
version 20150919

Changes:

+ get rid of unnecessary header inclusion (sys/syslog.h), which gives
problems on HP/UX and is unused

from Tobias Nygren
2015-09-25 15:46:58 +00:00
agc
7c72bc5399 Update netpgpverify to version 20150911.
Changes since previous version (20150901)

+ Apparently, OS X 10.4 does not have an implementation of le32dec().
Instead, unroll the inline function.

Bug report from Sevan - thanks!
2015-09-12 02:19:06 +00:00
jperkin
f064cce7ff Fix up a few more symbol renames, now -Wimplicit-function-declaration clean. 2015-09-06 21:25:19 +00:00
joerg
236fae7493 Deal with systems defining swap16/swap32 as macros. 2015-09-06 20:21:20 +00:00
jperkin
0fe810a2f0 Complete the SHA* symbol renaming. Ride previous bump. Ok agc. 2015-09-02 17:15:09 +00:00
agc
e1bb19e1e5 Update netpgpverify to 20150901
+ rename all the symbols I could fine which could conflict with those
  in libcrypto.  requested by joerg
2015-09-01 19:38:42 +00:00
jperkin
9999a2a693 Portability fixes. Add a test target and additional tests.
Reviewed by agc.
2015-08-17 11:37:55 +00:00
agc
0cfaed6376 forcibly disable tools build when running the testing script - found when
testing the src/ version, benign for pkgsrc. ride previous version bump.
2015-02-05 01:28:25 +00:00
agc
804fbc2e4d appease compiler warning police - initialise a variable in case it's otherwise
"used uninitialised". ride previous version bump.
2015-02-05 00:58:02 +00:00
agc
b24a4c3e01 Update netpgpverify (and libnetpgpverify) to version 20150205
+ recognise signatures made by subkeys as well as by primary keys

+ print out the relevant key which signed the file, even if it's
a subkey and not the primary key itself.

+ keep the same API as before

with many thanks to Jonathan Perkin
2015-02-05 00:21:57 +00:00
agc
1d1b6986c4 The test file for the "one key" test has embedded CVS Identifiers, so
work around this.
2015-02-04 17:53:39 +00:00
agc
f5b8aa147a add a minimalist shell script to make a tarball of the sources - requested
by various people.
2015-02-04 17:45:04 +00:00
agc
ada62f45b2 Update netpgpverify, and libnetpgpverify, to 20150204
+ dump the huge output to /dev/null so that we can see what's
happening with the other tests in testit.sh

+ fix from jperkin@, don't try to be clever when selecting the only
key id in a keyring

+ add a test for single key (non-ssh) pubring
2015-02-03 21:36:48 +00:00
agc
e5416534d1 Update netpgpverify, and libnetpgpverify, to 20150204
+ dump the huge output in testing script to /dev/null so that we can
see what's happening with the other tests in testit.sh

+ fix from jperkin@, don't try to be clever when selecting the only
key id in a keyring

+ add a test for single key (non-ssh) pubring
2015-02-03 21:34:57 +00:00