Closed FreedomPrevails closed 5 years ago
%2B
is urlencoded +
, but telegram only understands "urlsafe" version of base64: all +
should be replaced with -
and all /
with _
:
But it's better to be fixed in source code than manually later:
base64.b64encode(tls_secret)
should be replaced with base64.urlsafe_b64encode(tls_secret)
@seriyps Thanks ! replacing %2B with -
resolved the issue. @alexbers
BTW guys they released the version of the telergam that supports the fake TLS! On Android it's version 5.10 On PC it's version 1.8
BTW guys they released the version of the MTProto proxy that supports the fake TLS! On Android it's version 5.10 On PC it's version 1.8
Confirm! Also works on latest iOS.
Is this feature need any module? I can't even connect to the default secret.
If you are interested I have forked the repo and added TLS_ONLY option and fixed the TLS encoding bug : https://github.com/FreedomPrevails/mtprotoproxy
@FreedomPrevails I tried it but it doesn't work either.
@pouryare May be your IP is blocked or something else, you cant even connect to default secret. Your issue has nothing to do with TLS.
@FreedomPrevails I can connect to non TLS.
@seriyps I found out something interesting, i fixed the function to base64.urlsafe_b64encode
and it generates a secret which includes a -
character. but ios version of telegram, doesnt accept the secret if it has the -
char, I had to change it to +
manually so it would accept the secret !
The android and desktop versions accept the secret with -
char.
it seems there is a bug in the ios client. Hope they will fix it
Yes, I opened an issue an Telegram-iOS github: https://github.com/TelegramMessenger/Telegram-iOS/issues/118
After generating the secret and registering the bot in @MTProxybot it worked.
This issue is resolved.
I was trying to test the new experimental proxy method in Telegram desktop beta 1.7.15 but it says the proxy link -which is generated by mtprotoproxy- is invalid. The normal link works fine. Here are the links:
I see other users have the same issue in other topic https://github.com/alexbers/mtprotoproxy/issues/113