mirror of
https://github.com/amnezia-vpn/amnezia-client.git
synced 2026-05-17 08:16:06 +03:00
27 lines
623 B
C
27 lines
623 B
C
|
|
#ifndef ALLOWEDDNSCONTROLLER_H
|
||
|
|
#define ALLOWEDDNSCONTROLLER_H
|
||
|
|
|
||
|
|
#include <QStringList>
|
||
|
|
|
||
|
|
#include "core/repositories/secureAppSettingsRepository.h"
|
||
|
|
|
||
|
|
class AllowedDnsController
|
||
|
|
{
|
||
|
|
public:
|
||
|
|
explicit AllowedDnsController(SecureAppSettingsRepository* appSettingsRepository);
|
||
|
|
|
||
|
|
bool addDns(const QString &ip);
|
||
|
|
void addDnsList(const QStringList &dnsServers, bool replaceExisting);
|
||
|
|
void removeDns(int index);
|
||
|
|
QStringList getCurrentDnsServers() const;
|
||
|
|
|
||
|
|
private:
|
||
|
|
void fillDnsServers();
|
||
|
|
|
||
|
|
SecureAppSettingsRepository* m_appSettingsRepository;
|
||
|
|
QStringList m_dnsServers;
|
||
|
|
};
|
||
|
|
|
||
|
|
#endif // ALLOWEDDNSCONTROLLER_H
|
||
|
|
|