Repository navigation
vps-psiphon 1.2
A new option, --impersonate, for nodes that send only Gemini through the tunnel: it sees the captcha Google shows browsers on an exit and rotates away from it.
A captcha that cannot be solved
Where Gemini leaves through the tunnel and www.google.com from another address — a popular split, with YouTube left on the node's own address — Google can flag the exit for browsers alone. Gemini then redirects a browser to www.google.com/sorry, and that captcha is bound to the flagged address. Opened from the other address, it offers nothing to solve, only "Please try your request again later" and
IP address: <opener> ≠ <flagged>
Gemini stays closed on that exit until the exit changes. The watchdog never saw it, because plain curl gets the page through the same exit. On one such exit every browser TLS handshake — Chrome, Firefox, Safari — was redirected, with or without a browser's headers, while plain curl, with or without them, was not.
--impersonate
The installer fetches curl-impersonate, its latest release, checked against the sha256 GitHub publishes for it, into the instance's own /opt directory. The Gemini check then fetches its page as the newest Chrome the build knows. A redirect to /sorry is a new verdict, exit status 3, and the watchdog rotates at once:
gemini: CAPTCHA — Google sends a browser on this exit to /sorry, Gemini not asked
No request is added: it is the page the check fetches anyway, only the handshake differs. The message itself is still sent by plain curl.
The release and its digest are read from github.com, not from the GitHub API, whose anonymous limit of 60 requests an hour per address is shared with everything an exit's users run. If the latest release cannot be read, fetched, verified or run, v2.3.2 is taken, its digests written into the installer. --no-impersonate turns the option off and removes the build; the setting survives reinstalls.
It is off by default and best left off where all of Google goes through the tunnel: there the captcha can be solved, and rotating would lose a usable exit.
Upgrading is a reinstall over the running instance; the stored settings are kept, and nothing changes unless --impersonate is given.
По-русски
Новая опция --impersonate — для узлов, которые пускают через тоннель только Gemini: она видит капчу, которую Google показывает браузерам на выходе, и уводит с такого выхода.
Капча, которую не пройти
Если Gemini уходит через тоннель, а www.google.com — с другого адреса (популярная схема, где YouTube оставлен на собственном адресе узла), Google может пометить выход только для браузеров. Тогда Gemini перенаправляет браузер на www.google.com/sorry, а эта капча привязана к помеченному адресу. Открытая с другого адреса, она не предлагает ничего, только «Please try your request again later» и
IP address: <открывший> ≠ <помеченный>
Gemini закрыт на этом выходе, пока выход не сменится. Вотчдог этого не видел: обычный curl через тот же выход получает страницу. На одном таком выходе любое TLS-рукопожатие браузера — Chrome, Firefox, Safari — перенаправлялось, с заголовками браузера и без, а обычный curl, с ними и без, — нет.
--impersonate
Установщик скачивает curl-impersonate, его последний релиз, сверенный с sha256, который GitHub для него публикует, в собственный каталог экземпляра в /opt. Проверка Gemini после этого загружает свою страницу как самый новый Chrome из тех, что знает сборка. Перенаправление на /sorry — новый вердикт, код выхода 3, и вотчдог ротирует сразу:
gemini: CAPTCHA — Google sends a browser on this exit to /sorry, Gemini not asked
Запросов не добавляется: это та же страница, которую проверка загружает и так, меняется только рукопожатие. Само сообщение по-прежнему отправляет обычный curl.
Релиз и его digest берутся с github.com, а не из API GitHub: анонимный лимит API — 60 запросов в час на адрес — выход делит со всем, что запускают его пользователи. Если последний релиз не удалось прочитать, скачать, сверить или запустить, берётся v2.3.2, чьи digest-ы записаны в установщик. --no-impersonate выключает опцию и удаляет сборку; настройка переживает переустановку.
По умолчанию опция выключена, и там, где через тоннель идёт весь Google, её лучше не включать: там капча проходима, и ротация выбросила бы годный выход.
Обновление — переустановка поверх работающего экземпляра; сохранённые настройки остаются, и без --impersonate ничего не меняется.
🤖 Generated with Claude Code