mirror of
https://github.com/phishingclub/phishingclub.git
synced 2026-10-04 22:46:49 +02:00
added script support in remote browser script
Signed-off-by: RonniSkansing <rskansing@gmail.com>
This commit is contained in:
9 files changed
+234
No files matched your search
@@ -765,6 +765,15 @@ interface RequestInfo {
|
||||
* var s = newSession({ proxy: r.country === 'DE' ? 'de-proxy' : 'us-proxy' });
|
||||
*/
|
||||
declare function request(): RequestInfo;
|
||||
/**
|
||||
* Run a saved Script by name, passing data as its input, and return the object
|
||||
* the Script returns. Synchronous (blocks until the Script finishes). Useful for
|
||||
* reusable snippets and talking to external services. Requires the Scripts
|
||||
* feature to be enabled.
|
||||
* var geo = runScript('enrich-ip', { ip: request().ip });
|
||||
* var s = newSession({ proxy: geo.proxy });
|
||||
*/
|
||||
declare function runScript(name: string, data?: object): any;
|
||||
/** Send an event to the victim page (visible to the victim's JS) */
|
||||
declare function emit(key: string, value?: any): void;
|
||||
/** Log a message to the test runner */
|
||||
|
||||
@@ -111,6 +111,14 @@ declare const event: {
|
||||
data: Record<string, any>;
|
||||
};
|
||||
|
||||
/**
|
||||
* input is the data object passed when this script is run in callable mode,
|
||||
* e.g. from a remote browser script via runScript('name', data). It is an empty
|
||||
* object for campaign event triggered runs. Return an object to send data back
|
||||
* to the caller (callable mode only).
|
||||
*/
|
||||
declare const input: Record<string, any>;
|
||||
|
||||
interface FetchOptions {
|
||||
/** HTTP method: GET (default), POST, PUT, PATCH, DELETE, ... */
|
||||
method?: string;
|
||||
|
||||
Reference in new issue
Block a user