Make the clientos configurable and improve Reset Settings (#80)

* Set the gateway

* Make clientos configurable

* Update readme.md

* Update README.md
This commit is contained in:
Kevin Yue
2021-08-21 18:44:16 +08:00
committed by GitHub
parent 42cae3ff26
commit 6352e1fb2b
18 changed files with 205 additions and 52 deletions

View File

@@ -15,7 +15,6 @@ LoginParams::LoginParams()
params.addQueryItem("direct", "yes");
params.addQueryItem("clientVer", "4100");
params.addQueryItem("os-version", QUrl::toPercentEncoding(QSysInfo::prettyProductName()));
params.addQueryItem("clientos", "Linux");
params.addQueryItem("portal-userauthcookie", "");
params.addQueryItem("portal-prelogonuserauthcookie", "");
params.addQueryItem("prelogin-cookie", "");
@@ -56,6 +55,11 @@ void LoginParams::setPreloginCookie(const QString cookie)
updateQueryItem("prelogin-cookie", cookie);
}
void LoginParams::setClientos(const QString clientos)
{
updateQueryItem("clientos", clientos);
}
QByteArray LoginParams::toUtf8() const
{
return params.toString().toUtf8();