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
7d55f076
Commit
7d55f076
authored
May 08, 2003
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[NETFILTER]: Fix ip_nat_core.c:manip_pkt return value checks.
parent
deaaa245
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
11 deletions
+11
-11
net/ipv4/netfilter/ip_nat_core.c
net/ipv4/netfilter/ip_nat_core.c
+11
-11
No files found.
net/ipv4/netfilter/ip_nat_core.c
View file @
7d55f076
...
@@ -773,9 +773,9 @@ do_bindings(struct ip_conntrack *ct,
...
@@ -773,9 +773,9 @@ do_bindings(struct ip_conntrack *ct,
?
"SRC"
:
"DST"
,
?
"SRC"
:
"DST"
,
NIPQUAD
(
info
->
manips
[
i
].
manip
.
ip
),
NIPQUAD
(
info
->
manips
[
i
].
manip
.
ip
),
htons
(
info
->
manips
[
i
].
manip
.
u
.
all
));
htons
(
info
->
manips
[
i
].
manip
.
u
.
all
));
if
(
manip_pkt
(
proto
,
pskb
,
0
,
if
(
!
manip_pkt
(
proto
,
pskb
,
0
,
&
info
->
manips
[
i
].
manip
,
&
info
->
manips
[
i
].
manip
,
info
->
manips
[
i
].
maniptype
)
<
0
)
{
info
->
manips
[
i
].
maniptype
)
)
{
READ_UNLOCK
(
&
ip_nat_lock
);
READ_UNLOCK
(
&
ip_nat_lock
);
return
NF_DROP
;
return
NF_DROP
;
}
}
...
@@ -927,11 +927,11 @@ icmp_reply_translation(struct sk_buff **pskb,
...
@@ -927,11 +927,11 @@ icmp_reply_translation(struct sk_buff **pskb,
?
"DST"
:
"SRC"
,
?
"DST"
:
"SRC"
,
NIPQUAD
(
info
->
manips
[
i
].
manip
.
ip
),
NIPQUAD
(
info
->
manips
[
i
].
manip
.
ip
),
ntohs
(
info
->
manips
[
i
].
manip
.
u
.
udp
.
port
));
ntohs
(
info
->
manips
[
i
].
manip
.
u
.
udp
.
port
));
if
(
manip_pkt
(
inside
->
ip
.
protocol
,
pskb
,
if
(
!
manip_pkt
(
inside
->
ip
.
protocol
,
pskb
,
(
*
pskb
)
->
nh
.
iph
->
ihl
*
4
(
*
pskb
)
->
nh
.
iph
->
ihl
*
4
+
sizeof
(
inside
->
icmp
),
+
sizeof
(
inside
->
icmp
),
&
info
->
manips
[
i
].
manip
,
&
info
->
manips
[
i
].
manip
,
!
info
->
manips
[
i
].
maniptype
)
<
0
)
!
info
->
manips
[
i
].
maniptype
)
)
goto
unlock_fail
;
goto
unlock_fail
;
/* Outer packet needs to have IP header NATed like
/* Outer packet needs to have IP header NATed like
...
@@ -943,9 +943,9 @@ icmp_reply_translation(struct sk_buff **pskb,
...
@@ -943,9 +943,9 @@ icmp_reply_translation(struct sk_buff **pskb,
info
->
manips
[
i
].
maniptype
==
IP_NAT_MANIP_SRC
info
->
manips
[
i
].
maniptype
==
IP_NAT_MANIP_SRC
?
"SRC"
:
"DST"
,
?
"SRC"
:
"DST"
,
NIPQUAD
(
info
->
manips
[
i
].
manip
.
ip
));
NIPQUAD
(
info
->
manips
[
i
].
manip
.
ip
));
if
(
manip_pkt
(
0
,
pskb
,
0
,
if
(
!
manip_pkt
(
0
,
pskb
,
0
,
&
info
->
manips
[
i
].
manip
,
&
info
->
manips
[
i
].
manip
,
info
->
manips
[
i
].
maniptype
)
<
0
)
info
->
manips
[
i
].
maniptype
)
)
goto
unlock_fail
;
goto
unlock_fail
;
}
}
}
}
...
...
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