Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
97ddbec4
Commit
97ddbec4
authored
Aug 07, 2003
by
Herbert Xu
Committed by
Stephen Hemminger
Aug 07, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[XFRM_USER]: Add inner family field to all SAs and templates.
parent
5dbaaa44
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
include/linux/xfrm.h
include/linux/xfrm.h
+2
-1
net/xfrm/xfrm_user.c
net/xfrm/xfrm_user.c
+3
-3
No files found.
include/linux/xfrm.h
View file @
97ddbec4
...
...
@@ -37,6 +37,7 @@ struct xfrm_selector
__u16
dport_mask
;
__u16
sport
;
__u16
sport_mask
;
__u16
family
;
__u8
prefixlen_d
;
__u8
prefixlen_s
;
__u8
proto
;
...
...
@@ -125,6 +126,7 @@ enum
struct
xfrm_user_tmpl
{
struct
xfrm_id
id
;
__u16
family
;
xfrm_address_t
saddr
;
__u32
reqid
;
__u8
mode
;
...
...
@@ -189,7 +191,6 @@ struct xfrm_userpolicy_info {
struct
xfrm_lifetime_cur
curlft
;
__u32
priority
;
__u32
index
;
__u16
family
;
__u8
dir
;
__u8
action
;
#define XFRM_POLICY_ALLOW 0
...
...
net/xfrm/xfrm_user.c
View file @
97ddbec4
...
...
@@ -527,7 +527,7 @@ static int verify_newpolicy_info(struct xfrm_userpolicy_info *p)
return
-
EINVAL
;
};
switch
(
p
->
family
)
{
switch
(
p
->
sel
.
family
)
{
case
AF_INET
:
break
;
...
...
@@ -594,7 +594,7 @@ static void copy_from_user_policy(struct xfrm_policy *xp, struct xfrm_userpolicy
memcpy
(
&
xp
->
lft
,
&
p
->
lft
,
sizeof
(
xp
->
lft
));
xp
->
action
=
p
->
action
;
xp
->
flags
=
p
->
flags
;
xp
->
family
=
p
->
family
;
xp
->
family
=
p
->
sel
.
family
;
/* XXX xp->share = p->share; */
}
...
...
@@ -605,7 +605,7 @@ static void copy_to_user_policy(struct xfrm_policy *xp, struct xfrm_userpolicy_i
memcpy
(
&
p
->
curlft
,
&
xp
->
curlft
,
sizeof
(
p
->
curlft
));
p
->
priority
=
xp
->
priority
;
p
->
index
=
xp
->
index
;
p
->
family
=
xp
->
family
;
p
->
sel
.
family
=
xp
->
family
;
p
->
dir
=
dir
;
p
->
action
=
xp
->
action
;
p
->
flags
=
xp
->
flags
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment