improved MOBIKE:

prefer address family already used
  do not change address implicit when mobike supported
  handle multiple simultaneous roaming requests more properly
  proper enabling/disabling of UDP encapsulation
This commit is contained in:
Martin Willi
2007-07-03 12:32:38 +00:00
parent dd0ee786db
commit 3bc62fe70e
10 changed files with 256 additions and 90 deletions
+9 -2
View File
@@ -39,6 +39,11 @@ struct private_roam_job_t {
* public roam_job_t interface
*/
roam_job_t public;
/**
* has the address list changed, or the routing only?
*/
bool address;
};
/**
@@ -75,7 +80,7 @@ static void execute(private_roam_job_t *this)
ike_sa = charon->ike_sa_manager->checkout(charon->ike_sa_manager, id);
if (ike_sa)
{
if (ike_sa->roam(ike_sa) == DESTROY_ME)
if (ike_sa->roam(ike_sa, this->address) == DESTROY_ME)
{
charon->ike_sa_manager->checkin_and_destroy(
charon->ike_sa_manager, ike_sa);
@@ -95,13 +100,15 @@ static void execute(private_roam_job_t *this)
/*
* Described in header
*/
roam_job_t *roam_job_create()
roam_job_t *roam_job_create(bool address)
{
private_roam_job_t *this = malloc_thing(private_roam_job_t);
this->public.job_interface.destroy = (void (*) (job_t *)) destroy;
this->public.job_interface.execute = (void (*) (job_t *)) execute;
this->public.job_interface.destroy = (void (*) (job_t *)) destroy;
this->address = address;
return &this->public;
}
+2 -1
View File
@@ -50,11 +50,12 @@ struct roam_job_t {
/**
* @brief Creates a job to inform IKE_SAs about an updated address list.
*
* @param address TRUE if address list changed, FALSE if routing changed
* @return initiate_ike_sa_job_t object
*
* @ingroup jobs
*/
roam_job_t *roam_job_create();
roam_job_t *roam_job_create(bool address);
#endif /*ROAM_JOB_H_*/