diff options
author | Shinta Sugimoto <shinta.sugimoto@ericsson.com> | 2007-02-08 16:11:42 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2007-02-08 16:11:42 -0500 |
commit | 80c9abaabf4283f7cf4a0b3597cd302506635b7f (patch) | |
tree | 7dd4270a22e039c827114d182c2071a84826f563 /include/linux | |
parent | 9934e81c8c4981342dab3e386aff5d4499bea0d2 (diff) |
[XFRM]: Extension for dynamic update of endpoint address(es)
Extend the XFRM framework so that endpoint address(es) in the XFRM
databases could be dynamically updated according to a request (MIGRATE
message) from user application. Target XFRM policy is first identified
by the selector in the MIGRATE message. Next, the endpoint addresses
of the matching templates and XFRM states are updated according to
the MIGRATE message.
Signed-off-by: Shinta Sugimoto <shinta.sugimoto@ericsson.com>
Signed-off-by: Masahide NAKAMURA <nakam@linux-ipv6.org>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/xfrm.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/linux/xfrm.h b/include/linux/xfrm.h index 9529ea1ae392..15ca89e9961b 100644 --- a/include/linux/xfrm.h +++ b/include/linux/xfrm.h | |||
@@ -178,6 +178,9 @@ enum { | |||
178 | XFRM_MSG_REPORT, | 178 | XFRM_MSG_REPORT, |
179 | #define XFRM_MSG_REPORT XFRM_MSG_REPORT | 179 | #define XFRM_MSG_REPORT XFRM_MSG_REPORT |
180 | 180 | ||
181 | XFRM_MSG_MIGRATE, | ||
182 | #define XFRM_MSG_MIGRATE XFRM_MSG_MIGRATE | ||
183 | |||
181 | __XFRM_MSG_MAX | 184 | __XFRM_MSG_MAX |
182 | }; | 185 | }; |
183 | #define XFRM_MSG_MAX (__XFRM_MSG_MAX - 1) | 186 | #define XFRM_MSG_MAX (__XFRM_MSG_MAX - 1) |
@@ -256,6 +259,7 @@ enum xfrm_attr_type_t { | |||
256 | XFRMA_COADDR, /* xfrm_address_t */ | 259 | XFRMA_COADDR, /* xfrm_address_t */ |
257 | XFRMA_LASTUSED, | 260 | XFRMA_LASTUSED, |
258 | XFRMA_POLICY_TYPE, /* struct xfrm_userpolicy_type */ | 261 | XFRMA_POLICY_TYPE, /* struct xfrm_userpolicy_type */ |
262 | XFRMA_MIGRATE, | ||
259 | __XFRMA_MAX | 263 | __XFRMA_MAX |
260 | 264 | ||
261 | #define XFRMA_MAX (__XFRMA_MAX - 1) | 265 | #define XFRMA_MAX (__XFRMA_MAX - 1) |
@@ -351,6 +355,19 @@ struct xfrm_user_report { | |||
351 | struct xfrm_selector sel; | 355 | struct xfrm_selector sel; |
352 | }; | 356 | }; |
353 | 357 | ||
358 | struct xfrm_user_migrate { | ||
359 | xfrm_address_t old_daddr; | ||
360 | xfrm_address_t old_saddr; | ||
361 | xfrm_address_t new_daddr; | ||
362 | xfrm_address_t new_saddr; | ||
363 | __u8 proto; | ||
364 | __u8 mode; | ||
365 | __u16 reserved; | ||
366 | __u32 reqid; | ||
367 | __u16 old_family; | ||
368 | __u16 new_family; | ||
369 | }; | ||
370 | |||
354 | #ifndef __KERNEL__ | 371 | #ifndef __KERNEL__ |
355 | /* backwards compatibility for userspace */ | 372 | /* backwards compatibility for userspace */ |
356 | #define XFRMGRP_ACQUIRE 1 | 373 | #define XFRMGRP_ACQUIRE 1 |
@@ -375,6 +392,8 @@ enum xfrm_nlgroups { | |||
375 | #define XFRMNLGRP_AEVENTS XFRMNLGRP_AEVENTS | 392 | #define XFRMNLGRP_AEVENTS XFRMNLGRP_AEVENTS |
376 | XFRMNLGRP_REPORT, | 393 | XFRMNLGRP_REPORT, |
377 | #define XFRMNLGRP_REPORT XFRMNLGRP_REPORT | 394 | #define XFRMNLGRP_REPORT XFRMNLGRP_REPORT |
395 | XFRMNLGRP_MIGRATE, | ||
396 | #define XFRMNLGRP_MIGRATE XFRMNLGRP_MIGRATE | ||
378 | __XFRMNLGRP_MAX | 397 | __XFRMNLGRP_MAX |
379 | }; | 398 | }; |
380 | #define XFRMNLGRP_MAX (__XFRMNLGRP_MAX - 1) | 399 | #define XFRMNLGRP_MAX (__XFRMNLGRP_MAX - 1) |