Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
radsecproxy
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Fabian Mauchle
radsecproxy
Commits
536fbcd6
Commit
536fbcd6
authored
Aug 26, 2013
by
Linus Nordberg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Purge the duplication cache once per received packet.
parent
1931a0d5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
0 deletions
+17
-0
radsecproxy.c
radsecproxy.c
+17
-0
No files found.
radsecproxy.c
View file @
536fbcd6
...
...
@@ -1390,6 +1390,22 @@ struct request *newrequest() {
return
rq
;
}
static
void
purgedupcache
(
struct
client
*
client
)
{
struct
request
*
r
;
struct
timeval
now
;
int
i
;
gettimeofday
(
&
now
,
NULL
);
for
(
i
=
0
;
i
<
MAX_REQUESTS
;
i
++
)
{
r
=
client
->
rqs
[
i
];
if
(
r
&&
now
.
tv_sec
-
r
->
created
.
tv_sec
>
r
->
from
->
conf
->
dupinterval
)
{
freerq
(
r
);
client
->
rqs
[
i
]
=
NULL
;
}
}
}
int
addclientrq
(
struct
request
*
rq
)
{
struct
request
*
r
;
struct
timeval
now
;
...
...
@@ -1453,6 +1469,7 @@ int radsrv(struct request *rq) {
goto
exit
;
}
purgedupcache
(
from
);
if
(
!
addclientrq
(
rq
))
goto
exit
;
...
...
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