Skip to content
API Documentation
BastionGuard™
IdentityLeakConfig.hpp
Go to the documentation of this file.
1/*
2 * BastionGuard™
3 * Copyright (C) 2025–2026 Calogero Scarnà
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, version 3.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <https://www.gnu.org/licenses/>.
16 *
17 * BastionGuard™ is a trademark of Calogero Scarnà.
18 * The BastionGuard™ name and branding are not licensed under the GPL.
19 */
20
21#pragma once
22
23#include <string>
24#include <nlohmann/json.hpp>
25
27public:
28
29 static std::string hibpApiKey();
30 static void setHibpApiKey(const std::string&);
31
32 static std::string leakCheckApiKey();
33 static void setLeakCheckApiKey(const std::string&);
34
35
36 static bool monitorEnabled();
37 static void setMonitorEnabled(bool);
38
39private:
40
41 static std::string configPath();
42
43 static nlohmann::json loadJson();
44 static void saveJson(const nlohmann::json& j);
45};
static std::string configPath()
static std::string hibpApiKey()
static nlohmann::json loadJson()
static void setLeakCheckApiKey(const std::string &)
static void saveJson(const nlohmann::json &j)
static std::string leakCheckApiKey()
static void setHibpApiKey(const std::string &)
static void setMonitorEnabled(bool)