strongswan.git
4 years agoencoding: Allow ke_payload_create_from_diffie_hellman() to fail
Martin Willi [Mon, 23 Mar 2015 10:10:40 +0000 (11:10 +0100)]
encoding: Allow ke_payload_create_from_diffie_hellman() to fail

4 years agodiffie-hellman: Use bool instead of status_t as get_shared_secret() return value
Martin Willi [Mon, 23 Mar 2015 09:54:24 +0000 (10:54 +0100)]
diffie-hellman: Use bool instead of status_t as get_shared_secret() return value

While such a change is not unproblematic, keeping status_t makes the API
inconsistent once we introduce return values for the public value operations.

4 years agoload-tester: Migrate NULL DH implementation to INIT/METHOD macros
Martin Willi [Mon, 23 Mar 2015 09:44:55 +0000 (10:44 +0100)]
load-tester: Migrate NULL DH implementation to INIT/METHOD macros

4 years agoikev1: Make sure SPIs in an IKEv1 DELETE payload match the current SA
Tobias Brunner [Mon, 23 Mar 2015 09:58:30 +0000 (10:58 +0100)]
ikev1: Make sure SPIs in an IKEv1 DELETE payload match the current SA

OpenBSD's isakmpd uses the latest ISAKMP SA to delete other expired SAs.
This caused strongSwan to delete e.g. a rekeyed SA even though isakmpd
meant to delete the old one.

What isakmpd does might not be standard compliant. As RFC 2408 puts
it:

  Deletion which is concerned with an ISAKMP SA will contain a
  Protocol-Id of ISAKMP and the SPIs are the initiator and responder
  cookies from the ISAKMP Header.

This could either be interpreted as "copy the SPIs from the ISAKMP
header of the current message to the DELETE payload" (which is what
strongSwan assumed, and the direction IKEv2 took it, by not sending SPIs
for IKE), or as clarification that ISAKMP "cookies" are actually the
SPIs meant to be put in the payload (but that any ISAKMP SA may be
deleted).

4 years agoencoding: Add getter for IKE SPIs in IKEv1 DELETE payloads
Tobias Brunner [Mon, 23 Mar 2015 09:53:58 +0000 (10:53 +0100)]
encoding: Add getter for IKE SPIs in IKEv1 DELETE payloads

4 years agopki: Choose default digest based on the signature key
Tobias Brunner [Tue, 17 Mar 2015 13:40:02 +0000 (14:40 +0100)]
pki: Choose default digest based on the signature key

4 years agopki: Use SHA-256 as default for signatures
Tobias Brunner [Mon, 16 Mar 2015 17:25:22 +0000 (18:25 +0100)]
pki: Use SHA-256 as default for signatures

Since the BLISS private key supports this we don't do any special
handling anymore (if the user choses a digest that is not supported,
signing will simply fail later because no signature scheme will be found).

4 years agotrap-manager: Add option to ignore traffic selectors from acquire events
Tobias Brunner [Thu, 12 Mar 2015 10:50:20 +0000 (11:50 +0100)]
trap-manager: Add option to ignore traffic selectors from acquire events

The specific traffic selectors from the acquire events, which are derived
from the triggering packet, are usually prepended to those from the
config.  Some implementations might not be able to handle these properly.

References #860.

4 years agounit-tests: Fix settings test after merging multi-line strings
Tobias Brunner [Mon, 23 Mar 2015 09:46:32 +0000 (10:46 +0100)]
unit-tests: Fix settings test after merging multi-line strings

4 years agoswanctl: Append /ESN to proposal for a CHILD_SA using Extended Sequence Numbers
Martin Willi [Mon, 23 Mar 2015 09:12:06 +0000 (10:12 +0100)]
swanctl: Append /ESN to proposal for a CHILD_SA using Extended Sequence Numbers

We previously printed just the value for the "esn" keyword, which is "1", and
not helpful as such.

Fixes #904.

4 years agounit-tests: Depend on SHA1/SHA256 features for mgf1 test cases
Martin Willi [Mon, 23 Mar 2015 08:53:34 +0000 (09:53 +0100)]
unit-tests: Depend on SHA1/SHA256 features for mgf1 test cases

4 years agoman: More accurately describe features of the new parser in ipsec.conf(5)
Tobias Brunner [Thu, 19 Mar 2015 17:34:26 +0000 (18:34 +0100)]
man: More accurately describe features of the new parser in ipsec.conf(5)

4 years agosettings: Merge quoted strings that span multiple lines
Tobias Brunner [Thu, 19 Mar 2015 17:34:02 +0000 (18:34 +0100)]
settings: Merge quoted strings that span multiple lines

4 years agostarter: Merge quoted strings that span multiple lines
Tobias Brunner [Thu, 19 Mar 2015 17:33:19 +0000 (18:33 +0100)]
starter: Merge quoted strings that span multiple lines

4 years agoencoding: Don't verify length of IKEv1 KE payloads
Tobias Brunner [Fri, 20 Mar 2015 15:32:56 +0000 (16:32 +0100)]
encoding: Don't verify length of IKEv1 KE payloads

The verification introduced with 84738b1aed95 ("encoding: Verify the length
of KE payload data for known groups") can't be done for IKEv1 as the KE
payload does not contain the DH group.

4 years agocharon-systemd: Optionally load plugin list from charon-systemd.load
Tobias Brunner [Thu, 19 Mar 2015 15:19:24 +0000 (16:19 +0100)]
charon-systemd: Optionally load plugin list from charon-systemd.load

4 years agoapidoc: Limit INPUT to src subdirectory and README.md
Martin Willi [Thu, 19 Mar 2015 11:17:03 +0000 (12:17 +0100)]
apidoc: Limit INPUT to src subdirectory and README.md

While 0909bf6c explicitly includes the whole source tree (to cover README.md),
this has the unpleasant side effect of covering a workspace under "testing"
with all its sources, or any other potential subdirectory that exists.

4 years agoutils: Fix enum_flags_to_string parameter name to match Doxygen description
Martin Willi [Thu, 19 Mar 2015 11:14:30 +0000 (12:14 +0100)]
utils: Fix enum_flags_to_string parameter name to match Doxygen description

4 years agoattr-sql: Rename sql_attribute_t to attr_sql_provider_t
Martin Willi [Thu, 19 Mar 2015 10:24:31 +0000 (11:24 +0100)]
attr-sql: Rename sql_attribute_t to attr_sql_provider_t

As the plugin has its origins in the sql plugin, it still uses the naming
scheme for the attribute provider implementation. Rename the class to better
match the naming scheme we use in any other plugin

4 years agoikev1: Adopt virtual IPs on new IKE_SA during re-authentication
Tobias Brunner [Fri, 20 Feb 2015 15:57:13 +0000 (16:57 +0100)]
ikev1: Adopt virtual IPs on new IKE_SA during re-authentication

Some clients like iOS/Mac OS X don't do a mode config exchange on the
new SA during re-authentication.  If we don't adopt the previous virtual
IP Quick Mode rekeying will later fail.

If a client does do Mode Config we directly reassign the VIPs we migrated
from the old SA, without querying the attributes framework.

Fixes #807, #810.

4 years agoikev1: Mark rekeyed CHILD_SAs as INSTALLED
Tobias Brunner [Wed, 11 Mar 2015 14:48:51 +0000 (15:48 +0100)]
ikev1: Mark rekeyed CHILD_SAs as INSTALLED

Since we keep them around until they finally expire they otherwise would block
IKE_SA rekeying/reauthentication.

4 years agomem-pool: Remove entries without online or offline leases
Tobias Brunner [Wed, 11 Mar 2015 10:27:38 +0000 (11:27 +0100)]
mem-pool: Remove entries without online or offline leases

This avoids filling up the hash table with unused/old identities.

References #841.

4 years agokernel-handler: Log new endpoint if NAT mapping changed
Tobias Brunner [Tue, 17 Mar 2015 12:00:54 +0000 (13:00 +0100)]
kernel-handler: Log new endpoint if NAT mapping changed

4 years agochild-sa: Remove policies before states to avoid acquire events for untrapped policies
Tobias Brunner [Tue, 17 Mar 2015 08:58:00 +0000 (09:58 +0100)]
child-sa: Remove policies before states to avoid acquire events for untrapped policies

4 years agoMerge branch 'vici-python'
Martin Willi [Wed, 18 Mar 2015 14:03:28 +0000 (15:03 +0100)]
Merge branch 'vici-python'

Introduce a Python Egg for the vici plugin, contributed by Björn Schuberg.

4 years agoNEWS: Introduce vici Python Egg
Martin Willi [Fri, 6 Mar 2015 12:33:13 +0000 (13:33 +0100)]
NEWS: Introduce vici Python Egg

4 years agotravis: Install pip to install pytest in "all" tests
Martin Willi [Wed, 18 Mar 2015 13:28:17 +0000 (14:28 +0100)]
travis: Install pip to install pytest in "all" tests

This allows ./configure to detect py.test, and execute python unit tests we
provide in the vici python egg.

4 years agovici: Add support for python 3
Björn Schuberg [Mon, 9 Mar 2015 11:28:02 +0000 (12:28 +0100)]
vici: Add support for python 3

4 years agovici: Execute python tests during "check" if py.test is available
Martin Willi [Wed, 11 Mar 2015 09:18:56 +0000 (10:18 +0100)]
vici: Execute python tests during "check" if py.test is available

4 years agoconfigure: Check optional py.test availability when building with python eggs
Martin Willi [Wed, 11 Mar 2015 09:01:40 +0000 (10:01 +0100)]
configure: Check optional py.test availability when building with python eggs

4 years agovici: Add test of Packet layer in python library
Björn Schuberg [Mon, 9 Mar 2015 10:20:02 +0000 (11:20 +0100)]
vici: Add test of Packet layer in python library

4 years agovici: Add test of Message (de)serialization in python library
Björn Schuberg [Mon, 9 Mar 2015 10:12:30 +0000 (11:12 +0100)]
vici: Add test of Message (de)serialization in python library

4 years agovici: Evaluate Python streamed command results, and raise CommandException
Martin Willi [Mon, 9 Mar 2015 11:16:10 +0000 (12:16 +0100)]
vici: Evaluate Python streamed command results, and raise CommandException

4 years agovici: Catch Python GeneratorExit to properly cancel streamed event iteration
Martin Willi [Mon, 9 Mar 2015 11:06:38 +0000 (12:06 +0100)]
vici: Catch Python GeneratorExit to properly cancel streamed event iteration

4 years agovici: Fall back to heap buffer when vararg printing on stack fails
Martin Willi [Fri, 6 Mar 2015 09:54:34 +0000 (10:54 +0100)]
vici: Fall back to heap buffer when vararg printing on stack fails

This avoids failures when building log event messages including larger hexdumps.

4 years agovici: Return a Python generator instead of a list for streamed responses
Martin Willi [Mon, 2 Mar 2015 14:25:55 +0000 (15:25 +0100)]
vici: Return a Python generator instead of a list for streamed responses

In addition that it may reduce memory usage and improve performance for large
responses, it returns immediate results. This is important for longer lasting
commands, such as initiate/terminate, where immediate log feedback is preferable
when interactively calling such commands.

4 years agovici: Raise a Python CommandException instead of returning a CommandResult
Martin Willi [Mon, 2 Mar 2015 14:19:32 +0000 (15:19 +0100)]
vici: Raise a Python CommandException instead of returning a CommandResult

4 years agovici: Add initial Python egg documentation to README
Martin Willi [Fri, 27 Feb 2015 14:37:40 +0000 (15:37 +0100)]
vici: Add initial Python egg documentation to README

4 years agovici: Use OrderedDict to handle vici responses in Python library
Martin Willi [Fri, 27 Feb 2015 13:30:34 +0000 (14:30 +0100)]
vici: Use OrderedDict to handle vici responses in Python library

The default Python dictionaries are unordered, but order is important for some
vici trees (for example the order of authentication rounds).

4 years agovici: Return authentication rounds with unique names
Martin Willi [Fri, 27 Feb 2015 13:28:47 +0000 (14:28 +0100)]
vici: Return authentication rounds with unique names

To simplify handling of authentication rounds in dictionaries/hashtables on the
client side, we assign unique names to each authentication round when listing
connection.

4 years agovici: Rebuild ruby gem on source file changes
Martin Willi [Fri, 27 Feb 2015 13:05:12 +0000 (14:05 +0100)]
vici: Rebuild ruby gem on source file changes

4 years agovici: Use default Unix vici socket if none passed to ruby constructor
Martin Willi [Fri, 27 Feb 2015 13:03:35 +0000 (14:03 +0100)]
vici: Use default Unix vici socket if none passed to ruby constructor

While we currently have a static path instead of one generated with Autotools,
this at least is congruent to what we have in the Python library.

4 years agovici: Support non-Unix sockets for vici connections using Python
Martin Willi [Fri, 27 Feb 2015 12:59:23 +0000 (13:59 +0100)]
vici: Support non-Unix sockets for vici connections using Python

4 years agovici: Add python egg setuptools building and installation using easy_install
Martin Willi [Wed, 25 Feb 2015 15:20:10 +0000 (16:20 +0100)]
vici: Add python egg setuptools building and installation using easy_install

An uninstall target is currently not supported, as there is no trivial way with
either plain setuptools or with easy_install. pip would probably be the best
choice, but we currently don't depend on it.

4 years agovici: Generate a version specific setup.py for setuptools installation
Martin Willi [Wed, 25 Feb 2015 15:18:29 +0000 (16:18 +0100)]
vici: Generate a version specific setup.py for setuptools installation

4 years agovici: Include python package in distribution
Martin Willi [Wed, 25 Feb 2015 15:04:57 +0000 (16:04 +0100)]
vici: Include python package in distribution

4 years agoconfigure: Add --enable-python-eggs and --with-pythoneggdir options
Martin Willi [Wed, 25 Feb 2015 13:34:27 +0000 (14:34 +0100)]
configure: Add --enable-python-eggs and --with-pythoneggdir options

Detect easy_install for Python egg installation to install any egg we provide
in strongSwan.

4 years agovici: Add python package MIT license
Björn Schuberg [Sun, 15 Feb 2015 23:17:00 +0000 (00:17 +0100)]
vici: Add python package MIT license

4 years agovici: Expose Session as a top-level symbol in python package
Björn Schuberg [Sun, 15 Feb 2015 18:18:52 +0000 (19:18 +0100)]
vici: Expose Session as a top-level symbol in python package

4 years agovici: Introduce main API Session class in python package
Björn Schuberg [Sun, 15 Feb 2015 15:13:44 +0000 (16:13 +0100)]
vici: Introduce main API Session class in python package

4 years agovici: Add a python vici command execution handler
Björn Schuberg [Sat, 14 Feb 2015 14:53:25 +0000 (15:53 +0100)]
vici: Add a python vici command execution handler

4 years agovici: Add vici python protocol handler
Björn Schuberg [Sat, 14 Feb 2015 11:54:31 +0000 (12:54 +0100)]
vici: Add vici python protocol handler

4 years agoMerge branch 'swanctl-pkcs12'
Martin Willi [Wed, 18 Mar 2015 12:36:50 +0000 (13:36 +0100)]
Merge branch 'swanctl-pkcs12'

Add support for loading PKCS#12 containers from a swanctl/pkcs12 directory.

Fixes #815.

4 years agoswanctl: Cache entered PKCS#12 decryption secret
Martin Willi [Wed, 11 Mar 2015 15:52:54 +0000 (16:52 +0100)]
swanctl: Cache entered PKCS#12 decryption secret

It is usually used more than once, but most likely the same for decryption and
MAC verification.

4 years agoswanctl: Support loading PKCS#12 containers from a pkcs12 swanctl directory
Martin Willi [Wed, 11 Mar 2015 15:23:56 +0000 (16:23 +0100)]
swanctl: Support loading PKCS#12 containers from a pkcs12 swanctl directory

4 years agoswanctl: Generalize private key decryption to support other credential types
Martin Willi [Wed, 11 Mar 2015 15:23:11 +0000 (16:23 +0100)]
swanctl: Generalize private key decryption to support other credential types

4 years agoencoding: Verify the length of KE payload data for known groups
Martin Willi [Tue, 3 Feb 2015 15:40:14 +0000 (16:40 +0100)]
encoding: Verify the length of KE payload data for known groups

IKE is very strict in the length of KE payloads, and it should be safe to
strictly verify their length. Not doing so is no direct threat, but allows DDoS
amplification by sending short KE payloads for large groups using the target
as the source address.

4 years agoikev2: Migrate MOBIKE additional peer addresses to new SA after IKE_SA rekeying
Martin Willi [Wed, 18 Mar 2015 12:32:27 +0000 (13:32 +0100)]
ikev2: Migrate MOBIKE additional peer addresses to new SA after IKE_SA rekeying

4 years agoikev2: Immediately initiate queued tasks after establishing rekeyed IKE_SA
Martin Willi [Wed, 11 Mar 2015 10:30:51 +0000 (11:30 +0100)]
ikev2: Immediately initiate queued tasks after establishing rekeyed IKE_SA

If additional tasks get queued before/while rekeying an IKE_SA, these get
migrated to the new IKE_SA. We previously did not trigger initiation of these
tasks, though, leaving the task unexecuted until a new task gets queued.

4 years agoVersion bump to 5.3.0dr2
Andreas Steffen [Mon, 16 Mar 2015 16:15:58 +0000 (17:15 +0100)]
Version bump to 5.3.0dr2

4 years agoReplace kid by aik_id in ITA TBOOT functional component
Andreas Steffen [Mon, 16 Mar 2015 16:15:28 +0000 (17:15 +0100)]
Replace kid by aik_id in ITA TBOOT functional component

4 years agoFixed two BLISS key type identifier strings
Andreas Steffen [Sun, 15 Mar 2015 18:29:25 +0000 (19:29 +0100)]
Fixed two BLISS key type identifier strings

4 years agocharon-systemd: Add missing semicolon
Martin Willi [Mon, 16 Mar 2015 08:31:17 +0000 (09:31 +0100)]
charon-systemd: Add missing semicolon

References #887, fixes f3c83322.

4 years agoosx: Include eap-gtc plugin in build instructions
Martin Willi [Mon, 16 Mar 2015 08:27:18 +0000 (09:27 +0100)]
osx: Include eap-gtc plugin in build instructions

4 years agoAdded availability of TNC AR IP address to IMVs to NEWS 5.3.0dr1
Andreas Steffen [Sun, 15 Mar 2015 11:30:32 +0000 (12:30 +0100)]
Added availability of TNC AR IP address to IMVs to NEWS

4 years agoCreate TPM TBOOT Measurement group
Andreas Steffen [Sun, 15 Mar 2015 11:24:05 +0000 (12:24 +0100)]
Create TPM TBOOT Measurement group

4 years agovici: Use %u to print stats returned by mallinfo(3)
Tobias Brunner [Fri, 13 Mar 2015 14:20:39 +0000 (15:20 +0100)]
vici: Use %u to print stats returned by mallinfo(3)

Fixes #886.

4 years agostroke: Use %u to print stats returned by mallinfo(3)
Tobias Brunner [Fri, 13 Mar 2015 14:20:08 +0000 (15:20 +0100)]
stroke: Use %u to print stats returned by mallinfo(3)

References #886.

4 years agocharon-systemd: Add support to configure user and group via strongswan.conf
Tobias Brunner [Fri, 13 Mar 2015 13:33:13 +0000 (14:33 +0100)]
charon-systemd: Add support to configure user and group via strongswan.conf

Fixes #887.

4 years agoeap-radius: Increase Acct-Session-ID string buffer
Martin Willi [Fri, 13 Mar 2015 08:39:42 +0000 (09:39 +0100)]
eap-radius: Increase Acct-Session-ID string buffer

As the startup timestamp needs 10 characters, we only have left 4 characters
for the IKE_SA unique identifier. This is insufficient when having 10000 IKE_SAs
or more established, resulting in non-unique session identifiers.

Fixes #889.

4 years agotesting: Remove obsolete leftnexthop option from configs
Tobias Brunner [Thu, 12 Mar 2015 14:51:25 +0000 (15:51 +0100)]
testing: Remove obsolete leftnexthop option from configs

4 years agoikev2: Don't set old IKE_SA to REKEYING state during make-before-break reauth
Martin Willi [Wed, 11 Mar 2015 13:41:37 +0000 (14:41 +0100)]
ikev2: Don't set old IKE_SA to REKEYING state during make-before-break reauth

We are actually not in rekeying state, but just trigger a separate, new IKE_SA
as a replacement for the current IKE_SA. Switching to the REKEYING state
disables the invocation of both IKE and CHILD_SA updown hooks as initiator,
preventing the removal of any firewall rules.

Fixes #885.

4 years agoha: Destroy synced IKE_SA if no configuration is found during update
Martin Willi [Tue, 10 Mar 2015 14:08:58 +0000 (15:08 +0100)]
ha: Destroy synced IKE_SA if no configuration is found during update

4 years agoikev1: Don't handle DPD timeout job if IKE_SA got passive
Martin Willi [Tue, 10 Mar 2015 12:59:49 +0000 (13:59 +0100)]
ikev1: Don't handle DPD timeout job if IKE_SA got passive

While a passively installed IKE_SA does not queue a DPD timeout job, one that
switches from active to passive might execute it. Ignore such a queued job if
the IKE_SA is in passive state.

4 years agotesting: Don't check for exact IKEv1 fragment size
Martin Willi [Tue, 10 Mar 2015 09:21:16 +0000 (10:21 +0100)]
testing: Don't check for exact IKEv1 fragment size

Similar to 7a9c0d51, the exact packet size depends on many factors we don't
want to consider in this test case.

4 years agotesting: Fix active/passive role description in ha/both-active test case
Martin Willi [Tue, 10 Mar 2015 09:02:21 +0000 (10:02 +0100)]
testing: Fix active/passive role description in ha/both-active test case

4 years agolibipsec: Pass separate inbound/update flags to the IPsec SA manager
Martin Willi [Mon, 9 Mar 2015 17:08:52 +0000 (18:08 +0100)]
libipsec: Pass separate inbound/update flags to the IPsec SA manager

Similar to other kernel interfaces, the libipsec backends uses the flag for
different purposes, and therefore should get separate flags.

4 years agokernel-interface: Add a separate "update" flag to add_sa()
Martin Willi [Mon, 9 Mar 2015 17:04:54 +0000 (18:04 +0100)]
kernel-interface: Add a separate "update" flag to add_sa()

The current "inbound" flag is used for two purposes: To define the actual
direction of the SA, but also to determine the operation used for SA
installation. If an SPI has been allocated, an update operation is required
instead of an add.

While the inbound flag normally defines the kind of operation required, this
is not necessarily true in all cases. On the HA passive node, we install inbound
SAs without prior SPI allocation.

4 years agotkm: Use the inbound flag do determine peer role in CHILD_SA exchange
Martin Willi [Mon, 9 Mar 2015 16:44:55 +0000 (17:44 +0100)]
tkm: Use the inbound flag do determine peer role in CHILD_SA exchange

This was not available during initial implementation, but fits just fine to
avoid reconstructing the peer role.

4 years agoRevert "child-sa: Remove the obsolete update logic"
Martin Willi [Mon, 9 Mar 2015 16:52:33 +0000 (17:52 +0100)]
Revert "child-sa: Remove the obsolete update logic"

While the the meaning of the "inbound" flag on the kernel_interface->add_sa()
call is not very clear, we still need that update logic to allow installation of
inbound SAs without SPI allocation. This is used in the HA plugin as a passive
node.

This reverts commit 698ed656.

4 years agoRevert "ha: Always install the CHILD_SAs with the inbound flag set to FALSE"
Martin Willi [Mon, 9 Mar 2015 16:47:53 +0000 (17:47 +0100)]
Revert "ha: Always install the CHILD_SAs with the inbound flag set to FALSE"

While this change results in the correct add/update flag during installation,
it exchanges all other values in the child_sa->install() call. We should pass
the correct flag, but determine the add/update flag by other means.

This reverts commit e722ee5d.

4 years agotkm: Disable RFC 7427 signature authentication
Tobias Brunner [Fri, 6 Mar 2015 15:10:41 +0000 (16:10 +0100)]
tkm: Disable RFC 7427 signature authentication

TKM can't verify such signatures so we'd fail in the authorize hook.
Skipping the algorithm identifier doesn't help if the peer uses
anything other than SHA-1, so config changes would be required.

4 years agoikev2: Move code in pubkey authenticator's build() method into separate functions
Tobias Brunner [Mon, 9 Mar 2015 13:50:34 +0000 (14:50 +0100)]
ikev2: Move code in pubkey authenticator's build() method into separate functions

4 years agoikev2: Try all eligible signature schemes
Tobias Brunner [Fri, 6 Mar 2015 14:27:33 +0000 (15:27 +0100)]
ikev2: Try all eligible signature schemes

Previously, we failed without recovery if a private key did not support
a selected signature scheme (based on key strength and the other peer's
supported hash algorithms).

4 years agofiles: Add simple plugin to load files from file:// URIs
Tobias Brunner [Wed, 11 Feb 2015 11:11:04 +0000 (12:11 +0100)]
files: Add simple plugin to load files from file:// URIs

4 years agodaemon: Remove scheduled jobs before unloading plugins
Tobias Brunner [Thu, 5 Mar 2015 09:08:33 +0000 (10:08 +0100)]
daemon: Remove scheduled jobs before unloading plugins

Especially callback jobs might refer to memory that gets invalid after
the plugins got unlaoded, so make sure we destroy these jobs before.

References #840.

4 years agoscheduler: Add method to remove all scheduled jobs
Tobias Brunner [Thu, 5 Mar 2015 09:07:33 +0000 (10:07 +0100)]
scheduler: Add method to remove all scheduled jobs

References #840.

4 years agoplugin-loader: Increase log level for warning about plugin features that failed to...
Tobias Brunner [Wed, 4 Mar 2015 09:48:33 +0000 (10:48 +0100)]
plugin-loader: Increase log level for warning about plugin features that failed to load

Since we can't get rid of all unmet dependencies (at least not in every
possible plugin configuration) the message is more confusing than
helpful.  In particular because a detailed warning about plugin features
that failed to load due to unmet dependencies is only logged on level 2.

4 years agotls-peer: Make sure to use the right trusted public key for peer
Tobias Brunner [Fri, 20 Feb 2015 10:29:02 +0000 (11:29 +0100)]
tls-peer: Make sure to use the right trusted public key for peer

In case a CA certificate uses the same subject DN as the server the
previous code could end up trying to verify the server's signature with
the CA certificate's public key.  By comparing the certificate with the
one sent by the peer we make sure to use the right one.

Fixes #849.

4 years agopkcs11: Convert RFC 3279 ECDSA signatures when verifying
Tobias Brunner [Thu, 5 Mar 2015 14:14:40 +0000 (15:14 +0100)]
pkcs11: Convert RFC 3279 ECDSA signatures when verifying

References #873.

4 years agopkcs11: Properly encode RFC 3279 ECDSA signatures
Tobias Brunner [Thu, 5 Mar 2015 13:36:39 +0000 (14:36 +0100)]
pkcs11: Properly encode RFC 3279 ECDSA signatures

Fixes #873.

4 years agopkcs11: Properly encode EC_POINTs created on a token
Tobias Brunner [Thu, 5 Mar 2015 15:17:36 +0000 (16:17 +0100)]
pkcs11: Properly encode EC_POINTs created on a token

Some tokens might not fail when creating EC public keys in the incorrect
format, but they will later not be able to use them to verify signatures.

References #872.

4 years agopkcs11: Properly handle EC_POINTs returned as ASN.1 octet string
Tobias Brunner [Thu, 5 Mar 2015 13:33:59 +0000 (14:33 +0100)]
pkcs11: Properly handle EC_POINTs returned as ASN.1 octet string

This is the correct encoding but we internally only use unwrapped keys
and some tokens return them unwrapped.

Fixes #872.

4 years agoUpdated products in imv database
Andreas Steffen [Sun, 22 Feb 2015 21:27:35 +0000 (22:27 +0100)]
Updated products in imv database

4 years agoattest: output trusted flag and device description
Andreas Steffen [Sun, 22 Feb 2015 18:07:30 +0000 (19:07 +0100)]
attest: output trusted flag and device description

4 years agoMake access requestor IP address available to TNC server
Andreas Steffen [Thu, 19 Feb 2015 10:44:11 +0000 (11:44 +0100)]
Make access requestor IP address available to TNC server

4 years agotesting: Update modified updown scripts to the latest template
Tobias Brunner [Tue, 17 Feb 2015 14:01:09 +0000 (15:01 +0100)]
testing: Update modified updown scripts to the latest template

This avoids confusion and makes identifying the changes needed for each
scenario easier.

4 years agoRemove obsolete _updown_espmark script
Tobias Brunner [Tue, 17 Feb 2015 13:51:53 +0000 (14:51 +0100)]
Remove obsolete _updown_espmark script

According to NEWS it was created to support kernels < 2.6.16.

4 years ago_updown: Remove obsolete stuff from default script
Tobias Brunner [Tue, 17 Feb 2015 13:46:00 +0000 (14:46 +0100)]
_updown: Remove obsolete stuff from default script

4 years agoikev1: Set protocol ID and SPIs in INITIAL-CONTACT notification payloads
Tobias Brunner [Tue, 10 Feb 2015 18:03:44 +0000 (19:03 +0100)]
ikev1: Set protocol ID and SPIs in INITIAL-CONTACT notification payloads

The payload we sent before is not compliant with RFC 2407 and thus some
peers might abort negotiation (e.g. with an INVALID-PROTOCOL-ID error).

Fixes #819.