Added a new alert that is raised if peer does not respond to initial IKE message
This commit is contained in:
parent
b00806cf85
commit
1d6dc62727
|
@ -90,6 +90,8 @@ enum alert_t {
|
|||
ALERT_PEER_AUTH_FAILED,
|
||||
/** failed to resolve peer address, no arguments */
|
||||
ALERT_PEER_ADDR_FAILED,
|
||||
/** peer did not respond to initial message, current try (int, 0-based) */
|
||||
ALERT_PEER_INIT_UNREACHABLE,
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
@ -1690,6 +1690,8 @@ METHOD(ike_sa_t, retransmit, status_t,
|
|||
{
|
||||
/* retry IKE_SA_INIT/Main Mode if we have multiple keyingtries */
|
||||
u_int32_t tries = this->peer_cfg->get_keyingtries(this->peer_cfg);
|
||||
charon->bus->alert(charon->bus, ALERT_PEER_INIT_UNREACHABLE,
|
||||
this->keyingtry);
|
||||
this->keyingtry++;
|
||||
if (tries == 0 || tries > this->keyingtry)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue