Capture HTTP requests inside flash file


#1

Background
An old web application with lots of legacy .swf files was converted to a newer web app. The actionscript had hardcoded requests to URLs like “/serverlets/AppTracker.SessionCheck”. I had simply bypassed these checks by creating routes in my web application as “http://newapp/serverlets/AppTracker.SessionCheck”, that returns result=true (as expected by the AS inside .swf).

Problem
Now, I am trying to create an offline version of the application by creating an Electron based desktop app. When I try to embed and run the .swf file, the AS obviously sends request to “/serverlets/AppTracker.SessionCheck” and hence the flash fails to load. How do I capture this request to see the full request object? (Can’t see it in the “networks” tab)

Attempts
I have tried to bypass the request by creating a file in the root path as “serverlets/AppTracker.SessionCheck”. When I send a normal XMLHttpRequest from my index.js, it returns “result=true”. But the AS still fails to bypass.


#2

It is a very long time since I played with flash. Back in openlaszo days which was abandoned.

If you have managed to get this to work by using …
as “http://newapp/serverlets/AppTracker.SessionCheck” can you not create a localhost dummy server in similar vein in your desktop app? Just musing. I have no experience here.

On another point you might get some mileage by exploring the haxe/electron libraries discussed here

https://haxe.org/use-cases/desktop/

and OpenFL.