Commit Graph

1693 Commits

Author SHA1 Message Date
tteras 119e5ecd44 From Paul Wernau: vmbuf.h was defined twice in the headers. Remove the
redundant entry so new install tool does not complain about overwriting
just installed file.
2009-12-11 09:04:04 +00:00
agc 1fc3f56acb Minor change (benign everywhere else) to pick up the asprintf(3)
prototype on Linux - caught by Alan Horn.
2009-12-09 22:10:51 +00:00
agc 5674064867 Add a prototype for netpgp_match_list_keys() 2009-12-07 16:56:03 +00:00
martin 071ab236f8 size_t %z police 2009-12-07 16:55:37 +00:00
agc 93d262f9d5 + The internal variable "sshetcdir" has been renamed to "sshkeydir"
+ Take advantage of the new regular expression searching methods
2009-12-07 16:18:44 +00:00
agc 99e2a61b78 The internal variable "sshetcdir" has been renamed to "sshkeydir" 2009-12-07 16:17:57 +00:00
agc 183e04eb84 + When using ssh keys, use the first key as the default userid, unless
specified.

+ The internal variable "sshetcdir" has been renamed to "sshkeydir"

+ When matching the text fields in the username, use an ICASE, NOSUB, EXTENDED
regular expression. This allows more advanced ways of searching, such as:

% netpgpkeys --list-keys '\.de\>'

to find all the keys in the default keyring which have an email address
in Germany. This is actually surprisingly useful.
2009-12-07 16:17:17 +00:00
agc 5b91f35fb9 Fix up some lint.
Change the license on new files to a 2-clause one.
2009-12-06 17:43:05 +00:00
martin f20c48026a printf format fixes to make it compile 2009-12-05 17:23:39 +00:00
wiz e34d48521a Correct Xref to libnetpgp(3). 2009-12-05 10:05:54 +00:00
agc 1e9d36d82d Update the manual page for the addition of ssh host keys. 2009-12-05 07:33:18 +00:00
agc d6c0ee4fff One more thing in the "Done" section - add ssh host keys 2009-12-05 07:21:07 +00:00
agc 561d2d6ad0 Add new files into netpgp lib 2009-12-05 07:17:29 +00:00
agc 91c29c7450 Add the ability to use ssh host keys (on the fly) to provide RSA keys.
These keys can be used in the same way as normal PGP keys - to sign, verify,
encrypt and decrypt files and data.

	% cp configure a
	% sudo netpgp --ssh-keys --sign --userid 1e00404a a
	Password:
	pub 1024/RSA (Encrypt or Sign) 040180871e00404a 2008-08-11
	Key fingerprint: c4aa b385 4796 e6ce 606c f0c2 0401 8087 1e00 404a
	% sudo chmod 644 a.gpg
	% netpgp --ssh-keys --verify a.gpg
	netpgp: default key set to "C0596823"
	can't open '/etc/ssh/ssh_host_rsa_key'
	Good signature for a.gpg made Fri Dec  4 23:04:36 2009
	using RSA (Encrypt or Sign) key 040180871e00404a
	pub 1024/RSA (Encrypt or Sign) 040180871e00404a 2008-08-11
	Key fingerprint: c4aa b385 4796 e6ce 606c f0c2 0401 8087 1e00 404a
	uid              osx-vm1.crowthorne.alistaircrooks.co.uk (/etc/ssh/ssh_host_rsa_key.pub) <root@osx-vm1.crowthorne.alistaircrooks.co.uk>
	% uname -a
	NetBSD osx-vm1.crowthorne.alistaircrooks.co.uk 5.99.20 NetBSD 5.99.20 (ISCSI) #0: Wed Oct  7 17:16:33 PDT 2009  agc@osx-vm1.crowthorne.alistaircrooks.co.uk:/usr/obj/i386/usr/src/sys/arch/i386/compile/ISCSI i386
	%

The ssh host keys do not need to be manipulated in any way - the information
is read from existing files.
2009-12-05 07:08:18 +00:00
christos 4ab80ffe22 Disable SSL V3 session renegotiation since the protocol parameters of the
old session are not cryptographically tied to the new session ones.
NB: Applications that require session re-negotiation will fail after this
update.
2009-12-03 23:44:33 +00:00
agc 7d576ad983 Add python bindings for netpgp, via swig.
When using python, always add the dumb symbolic link to the library name.
2009-12-02 00:32:06 +00:00
agc e5e6e15318 Re-instate perl taint checking by re-defining the possible taint check in
swig. Fix a bug whereby the generated shlib_version file got appended to,
rather than rewritten.
2009-12-01 20:44:50 +00:00
agc f17a59eb6a Turns out that swig and tainted don't play well together - perl has no way
of knowing whether the memory will be modified. For now, the gross hack is
to switch off tainting
2009-12-01 08:02:50 +00:00
agc e1d61885e2 Add language bindings for tcl and perl 2009-12-01 06:43:57 +00:00
agc 6b13238156 Use the right field for the prefix 2009-12-01 06:33:31 +00:00
agc e502623fdd Add a swig interface file, and a wrapper script, for calling swig for
various language bindings for netpgp.
2009-12-01 05:19:51 +00:00
agc b4d6642e10 Recognise the hash algorithm in a case-insensitive manner. 2009-12-01 02:36:32 +00:00
christos aabb31871d PR/42363: Yasuoka Masahiko:
racoon uses a wrong IPsec-SA handle that is for other peer in case it
receives a ISAKMP message for IPsec-SA that has the same message-id as
the message-id that is received before.

racoon uses message-id to find the handle of IPsec-SA.  The message-id
is a unique number for each peer, but different peers may use the same
value.

Different Windows Vista or Windows 7 peers seem to use the same
message-id.  racoon can handle the first Windows's Phase-2, but it
cannot handle the second Windows.  Because racoon misunderstands the
message for the second Windows as the message for the first Windows.

>Category:       bin
>Synopsis:       racoon uses a wrong IPsec-SA that is for different peer
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Nov 22 18:25:00 +0000 2009
>Originator:     yasuoka@iij.ad.jp
2009-11-22 19:34:55 +00:00
agc f8429fa3c9 Remove vestiges of debugging 2009-11-20 15:23:37 +00:00
agc 33ee8138ba When writing an ascii-armoured message, push the linebreak writer onto
the write function stack for the body of the message as well as the
headers.

This means that an ascii-armoured signed file created by netpgp conforms
to RFC 4880 (and 2440, thanks, moof[1]), and can be verified by gpg now, as
well as netpgp.

[1] Are there any other RFCs which are superceded by their double?
2009-11-20 15:21:18 +00:00
agc 632dc3ac9b Unbreak the creation of ascii-armoured signatures.
Add automatic detection of ascii-armoured signatures.

Add tests for same - with small and large source files.
2009-11-20 07:17:07 +00:00
agc ad7bc21d21 Commit some changes that have been in a private tree for a while:
+ add a netpgp library function - netpgp_get_key(3) - to print a
specific key
+ add functionality to call this function in netpgpkeys(1)
+ add test for netpgp_get_key
+ add a verbose switch to the tst script
+ add netpgp functions to expose the memory signing and verification
functions - netpgp_sign_memory(3) and netpgp_verify_memory(3)
+ coalesced signing and verification ops file functions
2009-11-19 21:56:00 +00:00
christos 2853bbf4b7 use %option instead of #define YY_NO_... 2009-10-29 14:49:02 +00:00
christos 792f03d2b0 use %option noinput nounput 2009-10-29 14:34:27 +00:00
christos cd2a002a7a no unput 2009-10-28 20:59:46 +00:00
wiz 02d06f301f Remove .Os argument.
Remove ending dot in SEE ALSO.
Use Fl Fl for long options.
New sentence, new line.
Remove trailing whitespace.
2009-10-25 10:30:47 +00:00
reed 06921da813 Fix section number for a man page reference.
While here put the man pages in the SEE ALSO in order too.
(This was shared and now fixed upstream too.)
2009-10-25 01:52:04 +00:00
reed fa923fa9a7 Fix Nm macro usage.
Fixed upstream in April:
9747de8132
2009-10-24 11:12:56 +00:00
reed 638b376411 Fix Document Title.
(I already report and it is fixed upstream.)
2009-10-24 11:09:31 +00:00
agc a2dd3398cd Add 'a' and 'a.sig' to CLEANFILES - from Marc Balmer
Wrap long lines
2009-10-19 05:17:46 +00:00
agc 5ea8497ecf Use LD_LIBRARY_PATH to manage the library path, and don't try to second
guess from the lua driver program
2009-10-19 01:07:08 +00:00
agc 9470081fd3 Use a lua for loop in preference to a while and increment in the lua
example code - suggested by Marc Balmer.

	% make USETOOLS=no t
	cp Makefile a
	./netpgp.lua --sign --detached a
	netpgp: default key set to "C0596823"
	pub 2048/RSA (Encrypt or Sign) 1b68dcfcc0596823 2004-01-12
	Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823
	uid              Alistair Crooks <agc@netbsd.org>
	uid              Alistair Crooks <agc@pkgsrc.org>
	uid              Alistair Crooks <agc@alistaircrooks.com>
	uid              Alistair Crooks <alistair@hockley-crooks.com>
	netpgp passphrase:
	-rw-r--r--  1 agc  agc  287 Oct 17 15:58 a.sig
	./netpgp.lua --verify a.sig
	netpgp: default key set to "C0596823"
	netpgp: assuming signed data in "a"
	Good signature for a.sig made Sat Oct 17 15:58:09 2009
	using RSA (Encrypt or Sign) key 1b68dcfcc0596823
	pub 2048/RSA (Encrypt or Sign) 1b68dcfcc0596823 2004-01-12
	Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823
	uid              Alistair Crooks <alistair@hockley-crooks.com>
	uid              Alistair Crooks <agc@pkgsrc.org>
	uid              Alistair Crooks <agc@netbsd.org>
	uid              Alistair Crooks <agc@alistaircrooks.com>
	%
2009-10-18 07:23:37 +00:00
agc 1f8267516a Minor changes to find lua glue library, and to set the home directory on
the correct C/Lua structure
2009-10-18 07:17:28 +00:00
agc 606ee0c668 Link in the netpgp shared library to the lua glue library 2009-10-18 07:15:43 +00:00
agc faff2f64a8 Create .so from the lua interface library 2009-10-18 07:14:55 +00:00
agc 829fc7a59b Minor renaming of lua array
Zero allocated storage after return from lua_newuserdata()
2009-10-18 07:14:19 +00:00
joerg d935d602c7 Fix redundancy. 2009-10-15 00:07:45 +00:00
joerg addb345ac7 Do not work around ancient groff limits with .Xo/.Xc. 2009-10-14 23:37:33 +00:00
joerg 4467064d5b Do not use .Xo/.Xc to workaround ancient groff limits. 2009-10-14 23:36:55 +00:00
joerg a453670196 Do not use .Xo/.Xc to work around ancient groff limits.
Fix markup.
2009-10-14 18:34:14 +00:00
joerg 0639ebde24 Don't use .Xo/.Xc to work around ancient groff limits.
Set only one list type.
2009-10-14 18:22:04 +00:00
joerg 2644011d38 Use proper markup. 2009-10-14 17:33:56 +00:00
joerg 37ee8ee594 Don't use .Xo/.Xc to work around ancient groff limits. 2009-10-14 17:33:20 +00:00
joerg 68d56b9fdf Fix markup. 2009-10-13 22:49:34 +00:00
joerg 37aea36c2a Use sane logical markup and actual cross references. 2009-10-13 22:47:55 +00:00