Commit Graph

  • b03c700d08 IKEv1 XAuth: Changed the xauth_request task to use the new MIGRATE status. Clavister OpenSource 2011-11-24 16:57:10 +01:00
  • b94f248ea9 IKEv1 XAuth: Added new MIGRATE status type to status_t. When a task returns this status from a build or process method, it is a signal to the task manager that it should treat it as if the task returned SUCCESS. Additionally it will migrate all remaining tasks from the current queue to a different one, calling swap_initiator for each applicable task. Finally, the task manager will call "initiate", if applicable, to kick off tasks in the "queued_tasks" queue. Task queue relocation mapping: passive_tasks moves to queued_tasks (which is then fed to active by the initiate call). active_tasks moves to passive_tasks Clavister OpenSource 2011-11-24 16:48:41 +01:00
  • 46897273d7 IKEv1 XAuth: Added new "swap_initiator" method to the standard task_t interface. This is needed for when we move a task from the passive queue to the active one. I'm not a huge fan of this method of doing things. Perhaps we should change task_t to have build_i, build_r, process_i, and process_r methods, and call the appropriate one from the task manager, since we have these methods for most tasks anyways. Clavister OpenSource 2011-11-24 16:35:22 +01:00
  • cc50df9e6c IKEv1 XAuth: XAuthInitPreShared working for XAuth initiator (Main Mode responder). Creates USER/PASS request, retrieves the result and sends status. Clavister OpenSource 2011-11-24 11:46:02 +01:00
  • 2d97ec0d35 IKEv1 XAuth: Added ability to initiate the XAuth transactions under a flag, default not to initiate XAuth. Clavister OpenSource 2011-11-24 11:40:55 +01:00
  • 8b30286fcf IKEv1 XAuth: Add XAUTH authentication types to the enum. Added the ability to switch between hardcoded PSK and XAUTH_INIT_PSK authentications using a flag, default to PSK. Clavister OpenSource 2011-11-24 11:37:36 +01:00
  • ece4ed3fcd IKEv1 ConfigMode: Fix configuration_attribute encoding rules for IKEv1 to use the attribute type instead of the internal only payload type. Clavister OpenSource 2011-11-24 11:33:38 +01:00
  • 0b6811b4a7 IKEv1 ConfigMode: Fixed cp_payload to use CONFIGURATION_ATTRIBUTE_V1 in all appropriate places, so the parsing is done correctly. Clavister OpenSource 2011-11-24 11:30:19 +01:00
  • 01685247b0 IKEv1 XAuth: Added ike_vendor task to the ID_PROT exchange type processing. We need to process vendor payloads to check to see if our peer understands XAuth before using any of these payload types. Clavister OpenSource 2011-11-24 11:26:04 +01:00
  • e3bb68841a IKEv1 XAuth: Added temporary "initiate_xauth" public method to ike_sa_t. This allows us to initiate an XAuth password authentication exchange after responding to the final message of Main Mode. This change should be reverted once we have a better method to initiate this exchange. Clavister OpenSource 2011-11-24 11:21:43 +01:00
  • adf7b76f4c IKEv1 XAuth: Temporarilty add an "initiate_later" flag to the task manager. When set to TRUE it will cause "initiate" to be called when the current process_response call is finished. This change should be reverted once we have a better method in place. Clavister OpenSource 2011-11-24 11:12:59 +01:00
  • 9cc38c8efb Use quick mode task initiator flag instead of passing it as parameter Martin Willi 2011-11-24 10:33:43 +01:00
  • 4e0bc9af22 Add quick mode ID payloads only if establishing a non-host2host tunnel Martin Willi 2011-11-24 10:28:49 +01:00
  • c4b8539f93 Refactored traffic selector handling in quick mode Martin Willi 2011-11-24 10:20:59 +01:00
  • 818330aafe Refactored NONCE payload handling in quick mode Martin Willi 2011-11-24 09:51:40 +01:00
  • 78f7728c30 No need to build a HASH payload in XAUTH task. Tobias Brunner 2011-11-23 16:08:40 +01:00
  • c4c5950458 Create host-to-host traffic selectors if quick mode identities missing Martin Willi 2011-11-23 15:55:00 +01:00
  • 97265a8927 Removed redundant '=>' when logging binary data in parser and generator. Tobias Brunner 2011-11-23 15:30:41 +01:00
  • f4e21faa98 Fixed encryption of IKEv2 messages. Tobias Brunner 2011-11-23 15:23:20 +01:00
  • d020d4d695 Print message payload names after prepending IKEv1 HASH payload Martin Willi 2011-11-23 14:41:07 +01:00
  • da063ec95e Fixed task_manager_v1 compiler warnings Martin Willi 2011-11-23 14:33:03 +01:00
  • 3e246c4883 Generate a new mid only after we start a new task (and exchange) Martin Willi 2011-11-23 14:31:17 +01:00
  • a7910b1c6e Derive IKEv1 CHILD_SA keymat twice, once for each IPsec SA Martin Willi 2011-11-23 14:26:24 +01:00
  • 85f5c478bf Fix seed construction for IKEv1 key derivation Martin Willi 2011-11-23 14:05:19 +01:00
  • 9cc8bd4fd2 Use a dedicated message hash to detect IKEv1 retransmissions Martin Willi 2011-11-23 13:56:51 +01:00
  • 7a7f486df6 Include hardcoded tunnel mode attribute in porposal, remove ESN attribute Martin Willi 2011-11-23 13:56:21 +01:00
  • cd200cb821 Authenticate and verify Phase 2 IKEv1 messages with appropriate hashes. Tobias Brunner 2011-11-23 13:17:46 +01:00
  • 1e5dd62bb2 Fixed verification of DELETE_V1 payloads. Tobias Brunner 2011-11-23 12:35:58 +01:00
  • f3cc8589b1 Fixed header length calculation of DELETE payload. Tobias Brunner 2011-11-23 12:35:10 +01:00
  • d6cec44b24 Fixed conftests after extending CERT payload. Tobias Brunner 2011-11-23 12:11:49 +01:00
  • b6016fcab3 Fixed a config reference leak in IKEv2 initiate Martin Willi 2011-11-23 11:27:47 +01:00
  • 384c1a32a2 XAUTH is initiated based on configuration, no need to call externally Martin Willi 2011-11-23 11:27:03 +01:00
  • 017d98bf39 Merged IKEv1 attribute payload/data into configuration payload/attribute Martin Willi 2011-11-23 11:26:04 +01:00
  • df99e976be Temp fix for compile error with XAUTH code. Clavister OpenSource 2011-11-23 10:15:52 +01:00
  • 23f4e4b42d IKEv1 XAUTH: Added ability to configure XAUTH+PSK. Added task to handle XAUTH requests. Modified task_manager_v1 to enable it to initiate new tasks immediately after finishing a response. Clavister OpenSource 2011-11-23 08:55:59 +01:00
  • 79e9f776dc Updates ike_cert_post task with modifications needed for dealing with updated cert_payload class. Clavister OpenSource 2011-11-23 08:40:18 +01:00
  • c71760570e IKEv1 ConfigMode: Added the payload handlers for attribute_payload and data_attribute payload types. Clavister OpenSource 2011-11-23 08:36:22 +01:00
  • 54a8a94fa9 IKEv1 ConfigMode: Added TRANSACTION exchange type. Added attribute_payload (IKEv2 equiv cp_payload) and data_attribute (IKEv2 equiv configuration_attribute) payload types. Did not combine with IKEv2 because it wasn't trivial to do so. This might be a task worth investigating in the future, because there is a decent amount of shared code here. Clavister OpenSource 2011-11-23 08:29:54 +01:00
  • 9769b76cab Updated the CERT payload to work for both IKEv1 and IKEv2. Clavister OpenSource 2011-11-23 08:04:52 +01:00
  • d50152a70b Parse proposal substructure with multiple IKEv1 transforms to multiple proposals Martin Willi 2011-11-22 17:04:07 +01:00
  • 62a27ba347 Encode multiple IKEv1 proposals in a single transform substructure Martin Willi 2011-11-22 16:47:17 +01:00
  • f9450fc9f7 Remove public sa_payload.add_proposal() method Martin Willi 2011-11-22 16:28:44 +01:00
  • cd89f1a074 Only add the first algorithm of a kind to IKEv1 transforms Martin Willi 2011-11-22 16:16:19 +01:00
  • 5351d63c79 Install negotiated IKEv1 CHILD_SA negotiated in quick mode Martin Willi 2011-11-22 15:24:24 +01:00
  • ff2a2ad33a Implemented IKEv1 keymat CHILD_SA key derivation function Martin Willi 2011-11-22 14:58:17 +01:00
  • 6cd72730bf Moved keymat key length lookup functions to keymat.c Martin Willi 2011-11-22 14:54:50 +01:00
  • d4f6686c69 Extended PRF+ by a non-counting variant as used by IKEv1 Martin Willi 2011-11-22 14:38:43 +01:00
  • f5c0096086 Hardcode some SA lifetimes until we can configure them dynamically Martin Willi 2011-11-22 12:37:08 +01:00
  • 4c6dfbb26b Added missing comma after ME_CONNECT declaration. Tobias Brunner 2011-11-22 09:46:31 +01:00
  • 8c5e78ae4f Fixed creation of endpoint notifies. Tobias Brunner 2011-11-22 09:44:09 +01:00
  • 21da1087a5 Fixed diagram of IKEv1 encrypted "payload". Tobias Brunner 2011-11-22 09:41:58 +01:00
  • a0b52db079 Refactored main mode NONCE/KE payload processing Martin Willi 2011-11-22 09:32:30 +01:00
  • a0f851cfe0 Refactored main mode HASH payload processing Martin Willi 2011-11-22 09:14:57 +01:00
  • 73380c8685 Skip any payloads in front of SA to extract initiators SA bytes Martin Willi 2011-11-22 08:56:01 +01:00
  • 21b7db99c6 Implemented quick mode protocol handling, no CHILD_SA or HASH payloads yet Martin Willi 2011-11-21 17:56:39 +01:00
  • cc9629d87c Partially implemented IKEv1 ESP proposal en-/decoding Martin Willi 2011-11-21 17:40:42 +01:00
  • 12b6a68a5f Add missing keymat cast to avoid compiler warning Martin Willi 2011-11-21 17:32:19 +01:00
  • 17ec1c74de Don't compare initiator flag in IKE_SA manager, pass initiator parameter to IKE_SA constructor Martin Willi 2011-11-21 17:18:43 +01:00
  • 1b99befac3 Create and verify PSK HASH payloads in IKEv1 main mode Martin Willi 2011-11-21 17:16:39 +01:00
  • 4eee34ac49 Added keymat_v1_t.get_hash() to calculate authentication hashes Martin Willi 2011-11-21 16:41:48 +01:00
  • e1f9d6476e Register HASH_V1 in payload factory Martin Willi 2011-11-21 16:41:16 +01:00
  • 059d694a6b Derive IKE keys as IKEv1 initiator, too Martin Willi 2011-11-21 14:36:05 +01:00
  • 7fcd26f4fc Fix payload length of id_payload created from a traffic selector Martin Willi 2011-11-21 13:43:48 +01:00
  • 42a69b05ab String for ENCRYPTED_DATA fixed. Tobias Brunner 2011-11-21 15:18:40 +01:00
  • 780ce7724d Strings for ENCRYPTED_V1 payload added. Tobias Brunner 2011-11-21 15:16:51 +01:00
  • d66199884f Set flags on message according to IKE version when parsing header. Tobias Brunner 2011-11-21 13:26:27 +01:00
  • c92f2cf36d Encrypt IKEv1 messages. Tobias Brunner 2011-11-21 13:24:17 +01:00
  • 477e856a15 Decrypt IKEv1 messages. Tobias Brunner 2011-11-21 13:19:19 +01:00
  • b6f0029497 Added IV generation to keymat_v1_t. Tobias Brunner 2011-11-21 13:11:16 +01:00
  • 6f5f8ee4b5 Use modified encryption payload to encrypt/decrypt complete IKEv1 messages. Tobias Brunner 2011-11-21 11:53:23 +01:00
  • 0463674971 Use key derivation in IKEv1 main mode (PSK authentication). Tobias Brunner 2011-11-21 11:46:18 +01:00
  • aadb9e8355 Added a simple AEAD wrapper for IKEv1 encryption/decryption. Tobias Brunner 2011-11-21 11:43:43 +01:00
  • b05d91edd7 Added IKEv1 key derivation with support for AUTH_CLASS_PSK. Tobias Brunner 2011-11-21 11:41:37 +01:00
  • 3d59c5c382 Update cached hosts on ike_sa_t when processing IKEv1 messages. Tobias Brunner 2011-11-21 11:24:38 +01:00
  • 0cec72df40 Provide keymat_t to message_t to encrypt/decrypt data. Tobias Brunner 2011-11-21 11:18:08 +01:00
  • 50d493808c Avoid compiler warnings due to extended enums. Tobias Brunner 2011-11-21 11:05:43 +01:00
  • a0563846b0 Moved version specific keymat functions to specific interfaces. Tobias Brunner 2011-11-18 10:56:48 +01:00
  • a09972df2b Added a generic TASK_ prefix to all task types Martin Willi 2011-11-21 12:18:24 +01:00
  • 744c080153 Initiate and respond to quick mode task (stub) Martin Willi 2011-11-21 11:56:58 +01:00
  • 3bd5fcc832 Print message ID as unsigned integer Martin Willi 2011-11-21 11:54:29 +01:00
  • 9e40e3e9fa Added message encoding rules for quick mode Martin Willi 2011-11-21 11:51:16 +01:00
  • 9124e3425b Fixed reference counting bugs in main mode Martin Willi 2011-11-21 11:42:53 +01:00
  • 73aaf76be3 Implemented basic message id handling for IKEv1 Martin Willi 2011-11-21 11:21:21 +01:00
  • 2b04aa46ea Added a quick mode task stub Martin Willi 2011-11-21 11:20:34 +01:00
  • cbb6d765bc Fixed length calculation of delete payload Martin Willi 2011-11-21 10:22:50 +01:00
  • 4ea258538e Update header length after each parsed rule, as it might change when parsing SPI size Martin Willi 2011-11-21 10:10:48 +01:00
  • 5789320f5c Fix rule selection in transform substructure Martin Willi 2011-11-21 10:10:29 +01:00
  • 5f1aef65ce Fixed proposal numbering check in sa_payload Martin Willi 2011-11-21 09:10:50 +01:00
  • c311d22d0f Don't clone chunk in message.get_packet_data Martin Willi 2011-11-18 17:49:53 +01:00
  • 31fc14e394 Verify IKEv1 nonce size, send 32 byte nonces Martin Willi 2011-11-18 17:14:36 +01:00
  • 6c2b7d4ed9 Partially implemented third main mode exchange (identities) Martin Willi 2011-11-18 16:12:15 +01:00
  • e4a8fd72cb Added IKEv1 ID payload <-> traffic selector conversion functions Martin Willi 2011-11-18 14:31:13 +01:00
  • 764ee21d83 ts.get_subnet() returns TRUE if the selector actually is a subnet Martin Willi 2011-11-18 14:30:15 +01:00
  • 26b55dc6c8 Implemented first two exchanges of Main Mode as initiator Martin Willi 2011-11-18 10:56:02 +01:00
  • 9cc63d2cf0 Added enum name for MAIN_MODE task Martin Willi 2011-11-18 10:55:23 +01:00
  • cf1772f685 Do not ignore configs for IKEv1 in charon anymore Martin Willi 2011-11-18 10:08:18 +01:00
  • 558f79f76d Added missing task manager factory declaration Martin Willi 2011-11-18 09:50:22 +01:00
  • 72b3146092 Re-enable static inclusion of PSK auth method into IKEv1 proposal Martin Willi 2011-11-18 09:16:54 +01:00
  • cf6cd5aa4b Added IKEv1 support to delete payload Martin Willi 2011-11-17 18:14:51 +01:00
  • 04ee2b7fed Added IKEv1 support to notify payload Martin Willi 2011-11-17 18:01:41 +01:00