You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Call individual scripts from CLI depending on needs:
21
-
*`ws_server.py`: a WS server that sends json messages at random intervals,
22
-
*`ws_server_stdin.py`: a WS server that gets data from stdin coming from [TShark](https://www.wireshark.org/docs/man-pages/tshark.html) and sends them as json,
23
-
```shell
24
-
# Capture net traffic, export data as CSV, transform it to json, send it
... Firefox and Chrome can export TLS keys **for later decryption** by wireshark or TShark (i.e. no live decryption).
58
-
See "[Decrypting SSL/TLS traffic with Wireshark](https://resources.infosecinstitute.com/topic/decrypting-ssl-tls-traffic-with-wireshark/)" and "[TShark TLS Encrypted](https://tshark.dev/export/export_tls/)"for operational details.
59
-
As a quick hint, call Firefox, after the capture setup, with `SSLKEYLOGFILE=~/.ssl-key.log firefox`for keys exports (*don't forget to delete the file for security purposes*).
60
-
61
-
* `ws_server_har.py`: a WS server that parse a HAR file for 3 facets (Browser=>URL, URL=>Server, Browser=>Server) and sends data as json,
21
+
Call individual scripts from CLI depending on needs ...
22
+
23
+
### Message generator at random intervals
24
+
25
+
=> `ws_server.py`: a WS server that sends json messages at random intervals,
26
+
27
+
### Forward TSHARK messages
28
+
29
+
=> `ws_server_stdin.py`: a WS server that gets data from stdin coming from [TShark](https://www.wireshark.org/docs/man-pages/tshark.html) and sends them as json,
62
30
63
31
```shell
64
-
tshark -Q -a duration:30 \
65
-
-f "tcp port http or https" \
66
-
-w /tmp/http_https_netsniff.pcapng
67
-
& \
68
-
SSLKEYLOGFILE=/tmp/ssl-key.log firefox
32
+
# Capture net traffic, export data as CSV, transform it to json, send it
Unless using modified scripts, the WS is served at `ws://127.0.0.1:5678`.
91
-
92
-
## HTTP Archive files (HAR)
66
+
### Format and forward HAR file content
93
67
94
-
As an alternative to network traffic sniffing (e.g. tshark, tcpflow, tcpdump, etc.), because of TLS encryption or any other reason, browsing activity can be analyzed through HAR dumps.
68
+
As an alternative to network traffic sniffing (e.g. tshark, tcpflow, tcpdump, etc.), because of TLS encryption or any other reason, browsing activity can be analyzed through HTTP Archive (HAR) files.
95
69
96
70
The [Haralyzer](https://github.com/haralyzer/haralyzer) package allows for HAR file parsing in Python.
97
71
72
+
=> `ws_server_har.py`: a WS server that parse a HAR file for 3 facets (Browser=>URL, URL=>Server, Browser=>Server) and sends data as json,
73
+
74
+
### A posteriori decryption of TSHARK dumps
75
+
76
+
Firefox and Chrome can export TLS keys **for later decryption** by wireshark or TShark (i.e. no live decryption).
77
+
See "[Decrypting SSL/TLS traffic with Wireshark](https://resources.infosecinstitute.com/topic/decrypting-ssl-tls-traffic-with-wireshark/)" and "[TShark TLS Encrypted](https://tshark.dev/export/export_tls/)" for operational details.
78
+
As a quick hint, call Firefox, after the capture setup, with `SSLKEYLOGFILE=~/.ssl-key.log firefox` for keys exports (*don't forget to delete the file for security purposes*).
79
+
80
+
```shell
81
+
# Start Firefox instance with SSL key export
82
+
# and a 30 seconds capture of http/https traffic to local file in background with TShark
83
+
tshark -Q -a duration:30 \
84
+
-f "tcp port http or https" \
85
+
-w /tmp/http_https_netsniff.pcapng & \
86
+
SSLKEYLOGFILE=/tmp/ssl-key.log firefox
87
+
```
88
+
89
+
```shell
90
+
# Read and decrypt local traffic dump file,
91
+
# export data as CSV, transform it to json, send it
# This software is distributed under the BSD-4-Clause, the text of which is available at https://spdx.org/licenses/ or see the "LICENSE.txt" file for more details.
10
+
#
11
+
# Author: Lionel TAILHARDAT
12
+
# Software description: The DynaGraph framework: a system combining classical traces dumping tools (i.e. the tshark tool and Firefox's Network Monitor component) and a ReactJS web app for live 3D graph rendering of streamed graph data derived from traces.
13
+
#
14
+
15
+
# Capture net traffic, export data as CSV, transform it to json, send it
0 commit comments