Transparent proxy for OSX capable of injecting JavaScript
For an art project dealing with surveillance on the internet, I need to be able to inject content into all websites served from an open Wi-Fi network. Therefor I need a high performance transparent proxy for OSX that can inject JavaScript into all webpages served though from a router. The end result is that the users while going about their everyday business on the internet are presented with a number of images, pop ups and injected texts dealing with the fear of "algorithms" in society at large.Rough diagram of setup.
INTERNET -> USB MODEM -> OSX -> PROXY FILTER -> ROUTER -> OPEN WIFI -> USER
Requirements:
Modifying content via RegEx or similar
Injecting and executing JavaScript files
Processing images via external script
A comprehensive documentation with examples clear.
Be perform well enough to serve as many pages simultaneously.
Should be capable of running on a Mac Mini or MacBook
Needs to work on battery powered equipment.
Questions:
Will it work on HTTPS addresses?
I fully realise and accept that injection might not work as intended in all cases due to the nature of the internet, and I welcome alternative solutions that might accomplish the same thing.