Home

Awesome

<p align="center"> <img src="./.github/banner.png" width="80%"><br> A browser extension that allows you to monitor, intercept, and debug JavaScript sinks based on customizable configurations. <br> <img alt="GitHub release (latest by date)" src="https://img.shields.io/github/v/release/kevin-mizu/DOMLoggerpp"> <a href="https://twitter.com/intent/follow?screen_name=kevin_mizu" title="Follow"><img src="https://img.shields.io/twitter/follow/podalirius_?label=kevin_mizu&style=social"></a> <br> </p>

πŸ“¦ Installation

From extension stores:

Manual installation:

Download the latest release: https://github.com/kevin-mizu/domloggerpp/releases/

<p align="center"> <img src="./.github/images/firefox_manual.png"> </p> <p align="center"> <img src="./.github/images/chromium_manual.png"> </p>

if you want to build the extension by yourself, check the app folder.

<br>

🌟 Features

<br>

πŸ“ Usage example

https://github.com/kevin-mizu/domloggerpp/assets/48991194/d6ac9f90-0f44-4cd2-a5e6-890cd44b0aeb

<br>

πŸ› οΈ Devtools

  1. Custom filter buttons: Dynamically generated from your custom settings, these buttons facilitate log filtering.
  2. Data/Canary search bar: Easily filter and highlight logs using specific criteria related to a sink's args data.
  3. Advanced column search: Tailor your search to specific column criteria, like sink=innerHTML;frame=top, for more refined results.
  4. Global search bar: This default datatable feature enables searching across all columns.
  5. Debug button: Navigate directly to the page triggering the sink, with an automatic breakpoint for debugging.
  6. Log data management buttons:
    • Import JSON log data.
    • Clear existing log data.
    • Export log data in JSON format.
<br>

πŸ’¬ Popup

<p align="center"> <img src="./.github/images/popup.png" width="262" height="450"> </p>

βš™οΈ Settings

https://github.com/kevin-mizu/domloggerpp/assets/48991194/0827eef3-6c16-42fc-b84d-d8ea16def6bf

<br>

πŸ”— Hooking configuration

Global JSON structure

{
    "_description": "JSON config example",

    "hooks": {
        "category": {
            "type_1": [ "sink_1", "sink_2" ],
            "type_2": [ "sink_1", "sink_2" ]
        }
    },

    "config": {
        "*": {},
        "sink_1": {
            "match": [ "regex_1", "regex_2", "exec:return 'regex_3'" ],
            "!match": [ "regex_1", "regex_2", "exec:return 'regex_3'" ],
            "matchTrace": [ "regex_1", "regex_2", "exec:return 'regex_3'" ],
            "!matchTrace": [ "regex_1", "regex_2", "exec:return 'regex_3'" ],
            "hookFunction": "return args",
            "requiredHook": [ "type_2" ],
            "alert": {
                "match": [ "regex_1", "regex_2", "exec:return 'regex_3'" ],
                "!match": [ "regex_1", "regex_2", "exec:return 'regex_3'" ],
                "notification": true
            },
            "hideThis": true
        }
    },

    "globals": {
        "Blacklist": [ "api", "app" ]
    },

    "onload": "console.log(1)",

    "removeHeaders": [ "content-security-policy" ]
}

None of the specified keys in the configuration are mandatory; they can be manage to fit specific needs or omitted as desired.

_Description

This key aims to provide a way to insert notes within the configuration JSON itself. The value can be whatever you want as long as the JSON remains valid.

Hooks

Config

Since version 1.0.4, it is now possible to use the exec: regex directive, which allows you to generate a regex from JavaScript execution. For instance: exec:return document.location.pathname.

For more detailed examples and insights, please refer to the configs folder.

globals

The content of this key will be accessible in the domlogger.globals variable. It is designed to facilitate the modification of specific variables used in the exec: or hookFunction directives. An example of its usage can be found in the cspt.json configuration file.

onload

This key should contain a raw JavaScript function that will be executed after DOMLogger++ has loaded.

removeHeaders

Thanks to this key, you'll be able to provide a list of response headers (in lower case) that you want to remove if the remove headers feature is enabled. This is especially useful for removing security headers during tests.

<br>

🧰 Workshops

<br>

πŸ–₯️ Backend

Not yet developed.

<br>

πŸ—ΊοΈ Road map

<br>

🀝 Contributors

Many people helped and help DOMLogger++ become what it is and need to be acknowledged here!

@xanhacks, @kire_devs_hacks, aristosMiliaressis, @MtnBer, @FeelProud_sec, @jonathan404_, @PikuHaku, @aituglo, @xnl_h4ck3r, AetherBlack, @me0wday, @k1ng_pr4wn

Special thanks to @BitK_ for the well-structured code in Pwnfox, it helped me a lot to understand browsers extensions ❀️