-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcapui.h
More file actions
91 lines (83 loc) · 1.71 KB
/
capui.h
File metadata and controls
91 lines (83 loc) · 1.71 KB
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
// Copyright 2021, Pejman Taslimi
// You may distribute under the terms of either the GNU General Public
// License or the Artistic License, as specified in the MYLICENSE file.
/*
* FILENAME :
* DESCRIPTION :
*
* Author : Mani Tasl
* Date : Jun 2021.
*
*/
#include<string>
#include<codecvt>
#include<locale>
#include<vector>
using convert_t = std::codecvt_utf8<wchar_t>;
std::wstring_convert<convert_t, wchar_t> strconverter;
std::string to_string(std::wstring wstr){
return strconverter.to_bytes(wstr);
}
std::wstring to_wstring(std::string str){
return strconverter.from_bytes(str);
}
struct sLabels{
int iInterface = 0, iTraffic = 0,
iSoftware = 0, iVpn = 0, iOs = 0, iInternet = 0;
};
struct sStatus{
int iPacketCount, iDurationSec, iCaptureTime;
std::wstring wCaptureID, wCaptureTime, wFilename, wStatus;
sLabels Labels;
};
std::vector<std::wstring> Label_Interface;
std::vector<std::wstring> Label_Traffic = {
L"WebBrowse",
L"InstaBrowse",
L"SendEmail",
L"FileDL",
L"TorrentDL",
L"WatchVideo",
L"TextMessage",
L"TextChat",
L"VoiceCall",
L"VideoCall",
L"NoTask",
};
std::vector<std::wstring> Label_Software = {
L"Firefox",
L"Chrome",
L"Instagram",
L"qBittorrent",
L"Youtube",
L"Whatsapp",
L"Imo",
L"Skype",
L"Zoom",
};
std::vector<std::wstring> Label_VPN = {
L"None",
L"Lentern",
L"HotspotShield",
L"TunnelBear",
L"UltraSurf",
};
std::vector<std::wstring> Label_OS = {
L"Win10",
L"Win7",
L"Fedroa",
L"Android",
L"IOS",
L"AndrEmuWin10",
L"AndrEmuWin7",
L"AndrEmuFedora",
};
std::vector<std::wstring> Label_Internet = {
L"MCI",
L"Irancell",
L"AdslParsonline",
L"AdslShatel",
L"AdslTCl",
L"FibreTCI",
L"ITRC"
};