Enable Cisco Unity only if Unity vendor id received
This commit is contained in:
parent
6e60807637
commit
284ed1b352
|
@ -341,7 +341,8 @@ METHOD(attribute_handler_t, create_attribute_enumerator, enumerator_t *,
|
|||
ike_sa_t *ike_sa;
|
||||
|
||||
ike_sa = charon->bus->get_sa(charon->bus);
|
||||
if (!ike_sa || ike_sa->get_version(ike_sa) != IKEV1)
|
||||
if (!ike_sa || ike_sa->get_version(ike_sa) != IKEV1 ||
|
||||
!ike_sa->supports_extension(ike_sa, EXT_CISCO_UNITY))
|
||||
{
|
||||
return enumerator_create_empty();
|
||||
}
|
||||
|
|
|
@ -116,7 +116,8 @@ METHOD(listener_t, narrow, bool,
|
|||
private_unity_narrow_t *this, ike_sa_t *ike_sa, child_sa_t *child_sa,
|
||||
narrow_hook_t type, linked_list_t *local, linked_list_t *remote)
|
||||
{
|
||||
if (ike_sa->get_version(ike_sa) == IKEV1)
|
||||
if (ike_sa->get_version(ike_sa) == IKEV1 &&
|
||||
ike_sa->supports_extension(ike_sa, EXT_CISCO_UNITY))
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
|
|
|
@ -108,6 +108,7 @@ METHOD(attribute_provider_t, create_attribute_enumerator, enumerator_t*,
|
|||
|
||||
ike_sa = charon->bus->get_sa(charon->bus);
|
||||
if (!ike_sa || ike_sa->get_version(ike_sa) != IKEV1 ||
|
||||
!ike_sa->supports_extension(ike_sa, EXT_CISCO_UNITY) ||
|
||||
!vips->get_count(vips))
|
||||
{
|
||||
return NULL;
|
||||
|
|
Loading…
Reference in New Issue