ZaStoGram_desktop/Telegram/SourceFiles/mtproto/proxy/data.h
loop-uh 5bce8c10e5 Merge upstream dev through a1ea1ddd8c (7.2.9)
Keeps the ZaStoGram MTProto layout and its unaligned-access fixes, the
Forgejo update checker and the rich-page layout contract; takes the
upstream IV editor edge restore, horizontal overflow width, round video
seek, tlottie renderer and the lib_ui text shaper.
2026-09-23 16:21:17 +03:00

34 lines
1.1 KiB
C++

/*
This file is part of Telegram Desktop,
the official desktop application for the Telegram messaging service.
For license and copyright information please follow this link:
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
*/
#pragma once
#include "mtproto/runtime/proxy_data.h"
#include <QtNetwork/QNetworkProxy>
namespace MTP {
[[nodiscard]] ProxyData ToDirectIpProxy(
const ProxyData &proxy,
int ipIndex = 0);
[[nodiscard]] QNetworkProxy ToNetworkProxy(const ProxyData &proxy);
[[nodiscard]] QString NormalizeWebProxyHost(const QString &value);
[[nodiscard]] QString WebProxyBridgeCapability(const ProxyData &proxy);
[[nodiscard]] QString EncodeWebProxyLinkSecret(const ProxyData &proxy);
[[nodiscard]] QString DecodeWebProxyLinkSecret(
const QString &value,
bool hasBasePath);
[[nodiscard]] QString WebProxyBridgePath(const ProxyData &proxy);
[[nodiscard]] QString WebProxyBridgeUrl(const ProxyData &proxy);
[[nodiscard]] ProxyStealthOptions CompatStrictProxyStealthOptions(
ProxyStealthOptions result);
[[nodiscard]] ProxyStealthOptions ApplyProxyStealthLevel(
ProxyStealthOptions result,
ProxyStealthLevel level);
} // namespace MTP