StealthHTML
Hey, welcome to StealthHTML! This little tool is all about scrambling your HTML code to make it a bit more... sneaky. Want to keep your code under wraps or just throw off anyone trying to peek under the hood? StealthHTML’s here to help you turn your HTML into a cryptic masterpiece, all while keeping it looking normal on the surface.
What’s This All About?
HTML obfuscation is like putting your code through a blender—it still works and looks the same, but good luck to anyone trying to figure it out. Whether you’re hiding something clever or just having a laugh, StealthHTML throws in tricks like invisible characters, random junk, and shuffled styles to keep things interesting.
Cool Stuff It Does
StealthHTML’s got a bunch of neat features to play with:
- Random Text: Generates innocent-looking filler text from safe word lists.
- Invisible Characters: Slips in zero-width characters to spice things up without changing the look.
- CSS Shuffle: Jumbles your CSS properties so it’s a total guessing game.
- Extra Bits: Adds random classes, IDs, and hidden elements to throw people off.
- Link & Image Twists: Tosses in random link parameters and sneaky invisible images.
- Word Lists: Pick from
general,technical, ormarketingdictionaries to match your style. - Your Rules: Tweak how wild you want the obfuscation to get.
How to Get It Running
Setting up is super simple:
-
Grab the Code:
git clone https://github.com/keklick1337/StealthHTML.git -
Jump In:
cd StealthHTML -
Load It Up:
pip install -r requirements.txt
How to Use It
Once you’re good to go, it’s a piece of cake:
-
Make a Sneaky File:
python stealthhtml.py input.html -o output.htmlThis spits out a scrambled
output.htmlfrom yourinput.html. -
Quick Peek:
python stealthhtml.py input.htmlSee the magic right in your terminal.
Tweak It Your Way
You’ve got options to mess with the obfuscation:
--min_words: Shortest random text length. (Default: 2 words)--max_words: Longest random text length. (Default: 5 words)--invisible_char_prob: Chance of sneaking in invisible characters. (Default: 15%)--span_prob: Odds of tossing in a hidden<span>. (Default: 40%)--comment_count: How many random comments to add. (Default: 1)--meta_count: Number of extra meta tags. (Default: 1)--table_count: How many hidden tables to sneak in. (Default: 1)--style_count: Number of random style tags. (Default: 1)--image_count: How many invisible images to drop. (Default: 1)--script_count: Number of random script tags. (Default: 1)--rare_tag_count: How many weird tags (like<article>) to throw in. (Default: 1)--header_count: Number of hidden headers (like<h1>) to add. (Default: 1)--dictionary: Word list to use:general,technical, ormarketing. (Default:general)
Some Fun Examples
Here’s how you might play around with it:
-
Basic Scramble:
python stealthhtml.py template.html -o obfuscated.htmlTurns
template.htmlinto a sneakyobfuscated.html. -
Custom Chaos:
python stealthhtml.py template.html -o obfuscated.html --comment_count 3 --dictionary technical --invisible_char_prob 0.2Adds 3 comments, uses techy words, and ups the invisible character chance to 20%.
-
Terminal Teaser:
python stealthhtml.py template.htmlShows off the scrambled HTML in your console.
Wanna Chip In?
Love to have you onboard! Here’s how to contribute:
- Fork the repo.
- Start a new branch (
git checkout -b cool-idea). - Make your tweaks and commit (
git commit -m 'Added something awesome'). - Push it up (
git push origin cool-idea). - Open a pull request.
Just keep it clean and maybe toss in some tests if you can.
License
This is under the MIT License. Use it, tweak it, share it—just give a nod back to us.