ios fixes
This commit is contained in:
parent
12b079df65
commit
9ae2e3fba2
28 changed files with 149639 additions and 39 deletions
|
|
@ -47,6 +47,7 @@ QProcessEnvironment OpenVpnConfigurator::prepareEnv()
|
|||
|
||||
ErrorCode OpenVpnConfigurator::initPKI(const QString &path)
|
||||
{
|
||||
#ifndef Q_OS_IOS
|
||||
QProcess p;
|
||||
p.setProcessChannelMode(QProcess::MergedChannels);
|
||||
|
||||
|
|
@ -72,10 +73,14 @@ ErrorCode OpenVpnConfigurator::initPKI(const QString &path)
|
|||
|
||||
if (p.exitCode() == 0) return ErrorCode::NoError;
|
||||
else return ErrorCode::EasyRsaError;
|
||||
#else
|
||||
return ErrorCode::NotImplementedError;
|
||||
#endif
|
||||
}
|
||||
|
||||
ErrorCode OpenVpnConfigurator::genReq(const QString &path, const QString &clientId)
|
||||
{
|
||||
#ifndef Q_OS_IOS
|
||||
QProcess p;
|
||||
p.setProcessChannelMode(QProcess::MergedChannels);
|
||||
|
||||
|
|
@ -108,6 +113,9 @@ ErrorCode OpenVpnConfigurator::genReq(const QString &path, const QString &client
|
|||
|
||||
if (p.exitCode() == 0) return ErrorCode::NoError;
|
||||
else return ErrorCode::EasyRsaError;
|
||||
#else
|
||||
return ErrorCode::NotImplementedError;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@ using namespace QSsh;
|
|||
|
||||
QString SshConfigurator::convertOpenSShKey(const QString &key)
|
||||
{
|
||||
#ifndef Q_OS_IOS
|
||||
QProcess p;
|
||||
p.setProcessChannelMode(QProcess::MergedChannels);
|
||||
|
||||
|
|
@ -49,10 +50,14 @@ QString SshConfigurator::convertOpenSShKey(const QString &key)
|
|||
tmp.open();
|
||||
|
||||
return tmp.readAll();
|
||||
#else
|
||||
return key;
|
||||
#endif
|
||||
}
|
||||
|
||||
void SshConfigurator::openSshTerminal(const ServerCredentials &credentials)
|
||||
{
|
||||
#ifndef Q_OS_IOS
|
||||
QProcess *p = new QProcess();
|
||||
p->setReadChannelMode(QProcess::SeparateChannels);
|
||||
|
||||
|
|
@ -74,6 +79,7 @@ void SshConfigurator::openSshTerminal(const ServerCredentials &credentials)
|
|||
#endif
|
||||
|
||||
p->startDetached();
|
||||
#endif
|
||||
}
|
||||
|
||||
QProcessEnvironment SshConfigurator::prepareEnv()
|
||||
|
|
|
|||
|
|
@ -41,6 +41,8 @@ WireguardConfigurator::ConnectionData WireguardConfigurator::genClientKeys()
|
|||
program = QDir::toNativeSeparators(QApplication::applicationDirPath()) + "/Contents/MacOS/wg";
|
||||
#endif
|
||||
|
||||
#ifndef Q_OS_IOS
|
||||
|
||||
// Priv
|
||||
{
|
||||
QProcess p;
|
||||
|
|
@ -76,7 +78,7 @@ WireguardConfigurator::ConnectionData WireguardConfigurator::genClientKeys()
|
|||
connData.clientPubKey.replace("\r", "");
|
||||
connData.clientPubKey.replace("\n", "");
|
||||
}
|
||||
|
||||
#endif
|
||||
return connData;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue