#include <arpa/inet.h>
#include <chrono>
#include <cstdlib>
#include <cstring>
#include <filesystem>
#include <fstream>
#include <iomanip>
#include <iostream>
#include <openssl/err.h>
#include <openssl/sha.h>
#include <openssl/ssl.h>
#include <random>
#include <sstream>
#include <string>
#include <thread>
#include <unistd.h>
#include <unordered_map>
Go to the source code of this file.
◆ ATTEMPT_DELAY
#define ATTEMPT_DELAY 2000 |
◆ AUTH_REQUEST
#define AUTH_REQUEST "AUTH" |
◆ BUFFER_SIZE
◆ CA_CERT
#define CA_CERT "server_cert.pem" |
◆ GET_REQUEST
#define GET_REQUEST "GET" |
◆ LIST_REQUEST
#define LIST_REQUEST "LIST" |
◆ MAX_ATTEMPTS
◆ PORT
◆ QUIT_REQUEST
#define QUIT_REQUEST "QUIT" |
◆ SERVER_CERT
#define SERVER_CERT "server_cert.pem" |
◆ SERVER_IP
#define SERVER_IP "127.0.0.1" |
◆ SERVER_KEY
#define SERVER_KEY "server_key.pem" |
◆ STATUS_AUTH_FAILED
#define STATUS_AUTH_FAILED 430 |
◆ STATUS_AUTH_SUCCESS
#define STATUS_AUTH_SUCCESS 230 |
◆ STATUS_CHECKSUM_VERIFY
#define STATUS_CHECKSUM_VERIFY 151 |
◆ STATUS_FILE_NOT_FOUND
#define STATUS_FILE_NOT_FOUND 550 |
◆ STATUS_FILE_TRANSFER
#define STATUS_FILE_TRANSFER 160 |
◆ STATUS_GOODBYE
#define STATUS_GOODBYE 221 |
◆ STATUS_LISTING_FILES
#define STATUS_LISTING_FILES 150 |
◆ STATUS_MISSING_FILE_NAME
#define STATUS_MISSING_FILE_NAME 400 |
◆ STATUS_TRANSFER_COMPLETE
#define STATUS_TRANSFER_COMPLETE 226 |
◆ STATUS_UNKNOWN_COMMAND
#define STATUS_UNKNOWN_COMMAND 500 |
◆ get_error_message()
const char * get_error_message |
( |
int | status_code | ) |
|
◆ send_protocol_message()
void send_protocol_message |
( |
SSL * | ssl, |
|
|
int | status_code ) |