Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce TLS-JA4 client/server handshake tests #2265

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added tests/ja4-cl-handshake/input.pcap
Binary file not shown.
12 changes: 12 additions & 0 deletions tests/ja4-cl-handshake/suricata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
%YAML 1.1
---

outputs:
- eve-log:
enabled: yes
filetype: regular
filename: eve.json
types:
- tls:
enabled: yes
custom: [ja4, client_handshake]
15 changes: 15 additions & 0 deletions tests/ja4-cl-handshake/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
requires:
min-version: 8
features:
- HAVE_JA4

checks:
- filter:
count: 1
match:
event_type: tls
tls.ja4: t12d280700_d943125447b4_3c5a66c06c35
tls.client_handshake.version: TLS 1.2
tls.client_handshake.ciphers: [49196,49200,159,52393,52392,52394,49195,49199,158,49188,49192,107,49187,49191,103,49162,49172,57,49161,49171,51,157,156,61,60,53,47,255]
tls.client_handshake.exts: [0,11,10,35,22,23,13]
tls.client_handshake.sig_algs: [1027,1283,1539,2055,2056,2057,2058,2059,2052,2053,2054,1025,1281,1537,771,515,769,513,770,514,1026,1282,1538]
Binary file added tests/ja4-sv-handshake/input.pcap
Binary file not shown.
13 changes: 13 additions & 0 deletions tests/ja4-sv-handshake/suricata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
%YAML 1.1
---

outputs:
- eve-log:
enabled: yes
filetype: regular
filename: eve.json
types:
- tls:
enabled: yes
custom: [ja4s, server_handshake]

14 changes: 14 additions & 0 deletions tests/ja4-sv-handshake/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
requires:
min-version: 8
features:
- HAVE_JA4
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we have a test that does not require JA4 ?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you elaborate for me, please? So you want a test that mirrors the above but just with that removed? So are you expecting it to produce no output? Apologies, I've just not quite understood what you want here.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I expected that we can output tls.client_handshake.exts even without ja4 enabled...
Is that wrong ?


checks:
- filter:
count: 1
match:
event_type: tls
tls.ja4s: t120400_c030_12a20535f9be
tls.server_handshake.version: TLS 1.2
tls.server_handshake.cipher: 49200
tls.server_handshake.exts: [65281,11,35,23]