]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
Raise an alert if CHILD_SA proposals mismatch
authorMartin Willi <martin@revosec.ch>
Tue, 6 Nov 2012 10:05:04 +0000 (11:05 +0100)
committerMartin Willi <martin@revosec.ch>
Wed, 19 Dec 2012 09:40:32 +0000 (10:40 +0100)
src/libcharon/bus/bus.h
src/libcharon/sa/ikev2/tasks/child_create.c

index 433658ab766574c0d262af029aa9536abc3bec8d..4cb4ba343c690ea8ffe2cbe35abe4bc06ac68036 100644 (file)
@@ -109,6 +109,8 @@ enum alert_t {
        ALERT_RETRANSMIT_RECEIVE,
        /** IKE proposals do not match, argument is linked_list_t of proposal_t */
        ALERT_PROPOSAL_MISMATCH_IKE,
+       /** CHILD proposals do not match, argument is linked_list_t of proposal_t */
+       ALERT_PROPOSAL_MISMATCH_CHILD,
 };
 
 /**
index 46a165546f4045987b06bf2d635fe5cff9648cc0..f9f719accb73437d568fcb7cbc279689ab564f83 100644 (file)
@@ -377,6 +377,8 @@ static status_t select_and_install(private_child_create_t *this,
        if (this->proposal == NULL)
        {
                DBG1(DBG_IKE, "no acceptable proposal found");
+               charon->bus->alert(charon->bus, ALERT_PROPOSAL_MISMATCH_CHILD,
+                                                  this->proposals);
                return FAILED;
        }
        this->other_spi = this->proposal->get_spi(this->proposal);