diff --git a/mobile/src/changelog.ts b/mobile/src/changelog.ts index f65f278..a3dc745 100644 --- a/mobile/src/changelog.ts +++ b/mobile/src/changelog.ts @@ -20,7 +20,7 @@ export const CHANGELOG: ChangelogEntry[] = [ id: '2026-08-22b', date: 'August 2026', items: [ - 'Older galaxyporn scenes no longer open a blank page. They now live on a file host whose page is mostly site furniture, so the app strips it down to just the confirm-you-are-human box and the video, with a line telling you what to tap. Once the video appears it takes over the screen.', + 'Older galaxyporn scenes no longer open a blank page. They moved to a file host, and the app now grabs the video file straight from it and plays it in the normal player, so in most cases you will not see that page at all. If the host does ask you to confirm you are human, the page is stripped down to just that box and the video.', ], }, { diff --git a/mobile/src/screens/PlayerScreen.tsx b/mobile/src/screens/PlayerScreen.tsx index 1d33334..80b1e19 100644 --- a/mobile/src/screens/PlayerScreen.tsx +++ b/mobile/src/screens/PlayerScreen.tsx @@ -1197,6 +1197,35 @@ const INJECTED_JS = ` }; document.addEventListener('DOMContentLoaded', vkReady); setInterval(vkReady, 600); + + // Bezposredni adres pliku DA sie przechwycic i nie trzeba do tego ogladac strony. + // Po przejsciu zabezpieczenia strona robi POST na WLASNY adres z cialem + // 'cf-turnstile-response=' i dostaje JSON z polem link, czyli gotowy plik. + // Sam token wymaga silnika JS (bez niego serwer oddaje HTML zamiast JSON-a, + // sprawdzone), ale widget jest w trybie flexible z callbackiem, wiec na zwyklym + // domowym laczu przechodzi sam, bez klikania. Podsluchujemy wiec ten jeden POST i + // gdy tylko link sie pojawi, oddajemy go aplikacji, ktora przechodzi na natywny + // odtwarzacz. Oswojony wyglad strony zostaje jako zabezpieczenie na wypadek, gdyby + // zabezpieczenie jednak zazadalo kliniecia. + var vkOpen = XMLHttpRequest.prototype.open; + var vkSend = XMLHttpRequest.prototype.send; + XMLHttpRequest.prototype.open = function() { return vkOpen.apply(this, arguments); }; + XMLHttpRequest.prototype.send = function() { + var self = this; + try { + self.addEventListener('load', function() { + try { + var j = JSON.parse(self.responseText); + if (j && j.link && window.ReactNativeWebView) { + window.ReactNativeWebView.postMessage( + JSON.stringify({ type: 'video_url', url: j.link }) + ); + } + } catch (e) {} + }); + } catch (e) {} + return vkSend.apply(this, arguments); + }; } } catch (e) {}