-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpycapmap.py
More file actions
42 lines (32 loc) · 985 Bytes
/
Copy pathpycapmap.py
File metadata and controls
42 lines (32 loc) · 985 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
########################################
# imports
########################################
import networkx as nx
import matplotlib.pyplot as plt
from py_func.packet_size_func import *
from py_func.draw_func import *
from py_func.graph_func import *
from py_func.start import *
########################################
# config
########################################
protocols = {}
file_count = 0
source_ips = {}
dest_ips = {}
source_ports = {}
dest_ports = {}
conversation_lengths = {}
capture = start.capture
########################################
# main
########################################
main_func(capture, file_count, conversation_lengths)
########################################
# graph
########################################
G, incoming_edges, outgoing_edges = graph_func(source_ips, dest_ips, conversation_lengths)
########################################
# draw map
########################################
draw_func(G, incoming_edges, outgoing_edges)