From eac4785340cbeeb1f623ceb774a351578ab6cf4e Mon Sep 17 00:00:00 2001 From: Exp1o1 <166666343+Exp1o1@users.noreply.github.com> Date: Mon, 3 Jun 2024 16:59:02 -0500 Subject: [PATCH] Create consoleInjector.ts --- consoleInjector.ts | 56 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 consoleInjector.ts diff --git a/consoleInjector.ts b/consoleInjector.ts new file mode 100644 index 0000000..44227f0 --- /dev/null +++ b/consoleInjector.ts @@ -0,0 +1,56 @@ +```typescript +// consoleInjector.ts +function injectConsole(html: string) { + const consoleScript = ` + + `; + + return html.replace(/<\/body>/, `${consoleScript}`); +} + +export default injectConsole; +``` +This code injects a simple console element into the proxied website's HTML, allowing users to execute JavaScript code on the page. + +**Important:** This is a basic example and may not work as-is in your environment. You may need to modify the code to fit your specific proxy setup and requirements. + +Please note that this is just a starting point, and you should consider security implications and restrictions when injecting code into proxied websites.