Skip to content
API Documentation
BastionGuard™
SystemServiceControl.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <filesystem>
4#include <optional>
5#include <string>
6#include <vector>
7
9
17
20 std::string name;
21 std::filesystem::path definition;
22};
23
25 bool success{};
26 std::string message;
27};
28
29[[nodiscard]] InitSystem detectInitSystem() noexcept;
30[[nodiscard]] const char* toString(InitSystem init) noexcept;
31[[nodiscard]] std::optional<ServiceTarget>
32identifySystemService(const std::filesystem::path& path) noexcept;
33[[nodiscard]] ServiceActionResult
34blockSystemService(const std::filesystem::path& path) noexcept;
35[[nodiscard]] ServiceActionResult
36unblockSystemService(const std::filesystem::path& path) noexcept;
37
38} // namespace bastionguard::rootguard
std::optional< ServiceTarget > identifySystemService(const std::filesystem::path &path) noexcept
InitSystem detectInitSystem() noexcept
const char * toString(Mode mode) noexcept
Definition Policy.cpp:6
ServiceActionResult blockSystemService(const std::filesystem::path &path) noexcept
ServiceActionResult unblockSystemService(const std::filesystem::path &path) noexcept