Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GNS3_unikernel_testbed
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
NGUYEN Do Duc Anh
GNS3_unikernel_testbed
Commits
b1140b77
Commit
b1140b77
authored
1 month ago
by
NGUYEN Do Duc Anh
Browse files
Options
Downloads
Patches
Plain Diff
fix bug: correctly check a packet is first seen if option length is 12 and only have 1 node ID
parent
9a8383b6
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
simple-IDS/ids.ml
+1
-6
1 addition, 6 deletions
simple-IDS/ids.ml
ubuntu_base/op_ebpf.c
+1
-1
1 addition, 1 deletion
ubuntu_base/op_ebpf.c
with
2 additions
and
7 deletions
simple-IDS/ids.ml
+
1
−
6
View file @
b1140b77
...
...
@@ -28,13 +28,8 @@ let detect_and_output_private packet header frame inter_num output_private outpu
true
in
let
options
=
ipv4_hdr
.
options
in
(* match Ipaddr.V4.compare ipv4_hdr.src default_ignored_ip != 0 with *)
(* | false -> *)
(* Custom_option.read_custom_opt ipv4_hdr.src options (!node_id, inter_num); *)
(* output_private frame *)
(* | true -> ( *)
let
decision_list
=
Custom_option
.
get_decision_list
ipv4_hdr
.
dst
!
attacker_ip_lst
in
match
(
decision_list
<>
[]
,
is_attack
,
Cstruct
.
length
options
=
12
)
with
match
(
decision_list
<>
[]
,
is_attack
,
(
Cstruct
.
length
options
=
12
&&
Cstruct
.
get_uint8
options
11
=
0
)
)
with
|
false
,
false
,
_
->
(* If the packet is NOT in the path of attacks, just look for registration request *)
Custom_option
.
read_custom_opt
ipv4_hdr
.
src
options
;
...
...
This diff is collapsed.
Click to expand it.
ubuntu_base/op_ebpf.c
+
1
−
1
View file @
b1140b77
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment