{"id":15655581,"url":"https://github.com/mufeedvh/log4jail","last_synced_at":"2025-05-05T14:42:09.055Z","repository":{"id":114485588,"uuid":"438375603","full_name":"mufeedvh/log4jail","owner":"mufeedvh","description":"A firewall reverse proxy for preventing Log4J (Log4Shell aka CVE-2021-44228) attacks.","archived":false,"fork":false,"pushed_at":"2021-12-14T21:14:33.000Z","size":11,"stargazers_count":24,"open_issues_count":0,"forks_count":3,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-30T15:24:06.619Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mufeedvh.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2021-12-14T19:29:11.000Z","updated_at":"2023-06-30T21:38:46.000Z","dependencies_parsed_at":"2023-05-16T23:00:28.328Z","dependency_job_id":null,"html_url":"https://github.com/mufeedvh/log4jail","commit_stats":{"total_commits":6,"total_committers":1,"mean_commits":6.0,"dds":0.0,"last_synced_commit":"56f57808c11aa6aa7103a4938820da37149bb5b5"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mufeedvh%2Flog4jail","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mufeedvh%2Flog4jail/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mufeedvh%2Flog4jail/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mufeedvh%2Flog4jail/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mufeedvh","download_url":"https://codeload.github.com/mufeedvh/log4jail/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252421274,"owners_count":21745210,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-03T12:59:53.880Z","updated_at":"2025-05-05T14:42:09.038Z","avatar_url":"https://github.com/mufeedvh.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `log4jail` 🛡️\n\nA fast firewall reverse proxy with TLS (HTTPS) and swarm support for preventing Log4J (Log4Shell aka CVE-2021-44228) attacks.\n\n## 📖 Table of Contents\n\n- [Introduction](#%E2%84%B9%EF%B8%8F-introduction)\n- [Installation](#installation)\n- [Quick Start](#quick-start)\n- [Proof of Concept](#proof-of-concept)\n- [For Pentesters](#for-pentesters)\n\n## ℹ️ Introduction\n\n**log4jail** is a quick and dirty solution to block Log4Shell exploit attempts by acting as a reverse proxy scanning complete request body including all headers and request parameters for log4shell payloads.\n\n💡 You can run multiple instances at once by mapping them by port and target in the configuration file.\n\n\u003e The firewall follows the [mitigation strategies from Google Cloud](https://cloud.google.com/blog/products/identity-security/recommendations-for-apache-log4j2-vulnerability).\n\n## Installation\n\nDownload the binary for your OS from [**Releases**](https://github.com/mufeedvh/log4jail/releases) OR Install with `cargo`:\n\n    $ cargo install --git https://github.com/mufeedvh/log4jail.git\n    \n[Install Rust/Cargo](https://rust-lang.org/tools/install)\n\n## Build From Source\n\n**Prerequisites:**\n\n* [Git](https://git-scm.org/downloads)\n* [Rust](https://rust-lang.org/tools/install)\n* Cargo (Automatically installed when installing Rust)\n* A C linker (Only for Linux, generally comes pre-installed)\n\n```\n$ git clone https://github.com/mufeedvh/log4jail.git\n$ cd log4jail/\n$ cargo build --release\n```\n\nThe first command clones this repository into your local machine and the last two commands enters the directory and builds the source in release mode.\n\n## Quick Start\n\nJust run the command and there will be a boilerplate configuration file in the same working directory called `log4jail.json`.\n\n    $ log4jail\n    \nThe configuration file looks like this:    \n    \n```json\n{\n  \"host\": \"127.0.0.1\",\n  \"enable_https\": false,\n  \"tls_cert_path\": \"cert.pem\",\n  \"tls_key_path\": \"key.rsa\",\n  \"reject_response_status\": 403,\n  \"reject_response_body\": \"This request has been blocked.\",\n  \"proxy_mapping\": {\n    \"1337\": \"http://127.0.0.1:8080/\",\n    \"6969\": \"http://127.0.0.1:9000/\"\n  }\n}\n```\n\nConfigure the values for your environment and run the command again to spin up the proxy!\n\n## Proof of Concept\n\n`log4jail` blocks all attack vectors from [`log4j-scan`](https://github.com/fullhunt/log4j-scan) with WAF Bypass mode enabled:\n\n    $ python3 log4j-scan.py -u http://127.0.0.1:1337/ --run-all-tests --waf-bypass\n    \n![Screenshot from 2021-12-15 01-34-30](https://user-images.githubusercontent.com/26198477/146071752-2e105a65-aec5-4f67-81ea-8dd9caeff3a6.png)\n\n## For Pentesters\n\nIf you have found any working Log4Shell payloads that can bypass this firewall, please [open an issue](https://github.com/mufeedvh/log4jail/issues/new).\n\nJust run `log4jail` on any port and include the payload in the HTTP request for fuzz testing.\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmufeedvh%2Flog4jail","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmufeedvh%2Flog4jail","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmufeedvh%2Flog4jail/lists"}