| Wireshark 4.7.3 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
sctp_graph_dialog.h
Go to the documentation of this file.
1
9
10#ifndef SCTP_GRAPH_DIALOG_H
11#define SCTP_GRAPH_DIALOG_H
12
13#include <config.h>
14
15#include <epan/cfile.h>
16
17#include <QDialog>
18
19 namespace Ui {
20 class SCTPGraphDialog;
21}
22
23 class QCPAbstractPlottable;
24 class QCustomPlot;
25
26 struct _sctp_assoc_info;
27
31 struct chunk_header {
33 uint8_t type;
35 uint8_t flags;
37 uint16_t length;
38};
39
43 struct data_chunk_header {
45 uint8_t type;
47 uint8_t flags;
49 uint16_t length;
51 uint32_t tsn;
53 uint16_t sid;
55 uint16_t ssn;
57 uint32_t ppi;
58};
59
63 struct gaps {
65 uint16_t start;
67 uint16_t end;
68};
69
73 struct sack_chunk_header {
75 uint8_t type;
77 uint8_t flags;
79 uint16_t length;
81 uint32_t cum_tsn_ack;
83 uint32_t a_rwnd;
85 uint16_t nr_of_gaps;
87 uint16_t nr_of_dups;
88 struct gaps gaps[1];
89 /* Another unnamed FAM of uint32_t for the TSN duplicates follows the first one */
90};
91
95 struct nr_sack_chunk_header {
97 uint8_t type;
99 uint8_t flags;
101 uint16_t length;
103 uint32_t cum_tsn_ack;
105 uint32_t a_rwnd;
107 uint16_t nr_of_gaps;
109 uint16_t nr_of_nr_gaps;
111 uint16_t nr_of_dups;
113 uint16_t reserved;
114 struct gaps gaps[1];
115};
116
120 class SCTPGraphDialog : public QDialog
121{
122 Q_OBJECT
123
124 public:
132 explicit SCTPGraphDialog(QWidget *parent = 0, const _sctp_assoc_info *assoc = NULL,
133 capture_file *cf = NULL, int dir = 0);
134
138 ~SCTPGraphDialog();
139
145 static void save_graph(QDialog *dlg, QCustomPlot *plot);
146
147 public slots:
152 void setCaptureFile(capture_file *cf) { cap_file_ = cf; }
153
154 private slots:
158 void on_pushButton_clicked();
159
163 void on_pushButton_2_clicked();
164
168 void on_pushButton_3_clicked();
169
173 void on_pushButton_4_clicked();
174
180 void graphClicked(QCPAbstractPlottable* plottable, int, QMouseEvent* event);
181
185 void on_saveButton_clicked();
186
191 void on_relativeTsn_stateChanged(int arg1);
192
193 private:
195 Ui::SCTPGraphDialog *ui;
196
198 uint16_t selected_assoc_id;
199
201 capture_file *cap_file_;
202
204 int frame_num;
205
207 int direction;
208
210 QVector<double> xt, yt, xs, ys, xg, yg, xd, yd, xn, yn;
211
213 QVector<uint32_t> ft, fs, fg, fd, fn;
214
216 QVector<QString> typeStrings;
217
219 bool relative;
220
222 int type;
223
228 void drawGraph(const _sctp_assoc_info* selected_assoc = NULL);
229
234 void drawTSNGraph(const _sctp_assoc_info* selected_assoc);
235
240 void drawSACKGraph(const _sctp_assoc_info* selected_assoc);
241
246 void drawNRSACKGraph(const _sctp_assoc_info* selected_assoc);
247};
248
249#endif // SCTP_GRAPH_DIALOG_H
cfile.h
capture_file
struct _capture_file capture_file
Represents a capture file and its associated metadata.
SCTPGraphDialog::save_graph
static void save_graph(QDialog *dlg, QCustomPlot *plot)
Saves the displayed graph to a file.
Definition sctp_graph_dialog.cpp:490
SCTPGraphDialog::SCTPGraphDialog
SCTPGraphDialog(QWidget *parent=0, const _sctp_assoc_info *assoc=NULL, capture_file *cf=NULL, int dir=0)
Constructs a new SCTPGraphDialog.
Definition sctp_graph_dialog.cpp:30
SCTPGraphDialog::~SCTPGraphDialog
~SCTPGraphDialog()
Destroys the SCTPGraphDialog.
Definition sctp_graph_dialog.cpp:61
SCTPGraphDialog::setCaptureFile
void setCaptureFile(capture_file *cf)
Sets the active capture file for the dialog.
Definition sctp_graph_dialog.h:152
_sctp_assoc_info
Complete statistics and metadata record for a single SCTP association.
Definition tap-sctp-analysis.h:213
chunk_header
SCTP chunk header structure.
Definition sctp_graph_dialog.h:31
chunk_header::length
uint16_t length
Definition sctp_graph_dialog.h:37
chunk_header::type
uint8_t type
Definition sctp_graph_dialog.h:33
chunk_header::flags
uint8_t flags
Definition sctp_graph_dialog.h:35
data_chunk_header
SCTP data chunk header structure.
Definition sctp_graph_dialog.h:43
data_chunk_header::ssn
uint16_t ssn
Definition sctp_graph_dialog.h:55
data_chunk_header::ppi
uint32_t ppi
Definition sctp_graph_dialog.h:57
data_chunk_header::flags
uint8_t flags
Definition sctp_graph_dialog.h:47
data_chunk_header::sid
uint16_t sid
Definition sctp_graph_dialog.h:53
data_chunk_header::length
uint16_t length
Definition sctp_graph_dialog.h:49
data_chunk_header::tsn
uint32_t tsn
Definition sctp_graph_dialog.h:51
data_chunk_header::type
uint8_t type
Definition sctp_graph_dialog.h:45
gaps
Gap block structure for SACK and NR-SACK chunks.
Definition sctp_graph_dialog.h:63
gaps::end
uint16_t end
Definition sctp_graph_dialog.h:67
gaps::start
uint16_t start
Definition sctp_graph_dialog.h:65
nr_sack_chunk_header
SCTP NR-SACK chunk header structure.
Definition sctp_graph_dialog.h:95
nr_sack_chunk_header::gaps
struct gaps gaps[1]
Definition sctp_graph_dialog.h:114
nr_sack_chunk_header::a_rwnd
uint32_t a_rwnd
Definition sctp_graph_dialog.h:105
nr_sack_chunk_header::length
uint16_t length
Definition sctp_graph_dialog.h:101
nr_sack_chunk_header::nr_of_dups
uint16_t nr_of_dups
Definition sctp_graph_dialog.h:111
nr_sack_chunk_header::nr_of_nr_gaps
uint16_t nr_of_nr_gaps
Definition sctp_graph_dialog.h:109
nr_sack_chunk_header::cum_tsn_ack
uint32_t cum_tsn_ack
Definition sctp_graph_dialog.h:103
nr_sack_chunk_header::reserved
uint16_t reserved
Definition sctp_graph_dialog.h:113
nr_sack_chunk_header::nr_of_gaps
uint16_t nr_of_gaps
Definition sctp_graph_dialog.h:107
nr_sack_chunk_header::flags
uint8_t flags
Definition sctp_graph_dialog.h:99
nr_sack_chunk_header::type
uint8_t type
Definition sctp_graph_dialog.h:97
sack_chunk_header
SCTP SACK chunk header structure.
Definition sctp_graph_dialog.h:73
sack_chunk_header::nr_of_gaps
uint16_t nr_of_gaps
Definition sctp_graph_dialog.h:85
sack_chunk_header::flags
uint8_t flags
Definition sctp_graph_dialog.h:77
sack_chunk_header::a_rwnd
uint32_t a_rwnd
Definition sctp_graph_dialog.h:83
sack_chunk_header::type
uint8_t type
Definition sctp_graph_dialog.h:75
sack_chunk_header::nr_of_dups
uint16_t nr_of_dups
Definition sctp_graph_dialog.h:87
sack_chunk_header::cum_tsn_ack
uint32_t cum_tsn_ack
Definition sctp_graph_dialog.h:81
sack_chunk_header::length
uint16_t length
Definition sctp_graph_dialog.h:79
sack_chunk_header::gaps
struct gaps gaps[1]
Definition sctp_graph_dialog.h:88