parser beta 0.1
This commit is contained in:
19
src/parser.hpp
Normal file
19
src/parser.hpp
Normal file
@@ -0,0 +1,19 @@
|
||||
#pragma once
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
#include <unistd.h>
|
||||
#include <getopt.h> // Для struct option
|
||||
|
||||
struct Options {
|
||||
std::string attack_type; // Обязательный параметр
|
||||
std::string domain; // Обязательный параметр
|
||||
std::string ip; // Обязательный параметр
|
||||
std::string port; // Обязательный параметр (не обязательный для скана)
|
||||
std::string log_file = "/var/logs/DosAtk"; // Значение по умолчанию, не обязательный
|
||||
std::string telegram_id; // Не обязательный параметр
|
||||
std::string telegram_token; // Не обязательный параметр
|
||||
};
|
||||
|
||||
// Прототип функции парсинга
|
||||
int parse_params(int argc, char** argv, Options& opts);
|
||||
Reference in New Issue
Block a user