1#ifndef SRC_SCANNER_LIB_FILE_LOGGER_H_
2#define SRC_SCANNER_LIB_FILE_LOGGER_H_
29 explicit FileLogger(
const std::filesystem::path& log_path);
37 void LogDetection(
const std::filesystem::path& path,
const std::string& hash,
38 const std::string& verdict)
override;
An implementation of ILogger that writes detections to a file.
Definition file_logger.h:22
std::ofstream log_stream_
Definition file_logger.h:41
std::mutex mutex_
Definition file_logger.h:42
void LogDetection(const std::filesystem::path &path, const std::string &hash, const std::string &verdict) override
Logs a malicious file detection to the file in a thread-safe manner.
Definition file_logger.cpp:17
Defines the contract for a component that logs malicious detections.
Definition interfaces.h:64