{"id":27641330,"url":"https://github.com/brianoy/sketchobfus","last_synced_at":"2025-04-23T23:44:02.894Z","repository":{"id":289320568,"uuid":"970848269","full_name":"brianoy/SketchObfus","owner":"brianoy","description":"Just scrambles your arduino code variable names to make the code harder to read. Focused on what it does best: making things slightly uglier.","archived":false,"fork":false,"pushed_at":"2025-04-22T17:52:39.000Z","size":21,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-22T17:57:21.158Z","etag":null,"topics":["arduino","arduino-uglier","obfuscate","uglier"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/brianoy.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-04-22T16:16:44.000Z","updated_at":"2025-04-22T17:52:42.000Z","dependencies_parsed_at":"2025-04-22T17:57:22.045Z","dependency_job_id":null,"html_url":"https://github.com/brianoy/SketchObfus","commit_stats":null,"previous_names":["brianoy/sketchobfus"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianoy%2FSketchObfus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianoy%2FSketchObfus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianoy%2FSketchObfus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianoy%2FSketchObfus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/brianoy","download_url":"https://codeload.github.com/brianoy/SketchObfus/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250535057,"owners_count":21446503,"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":["arduino","arduino-uglier","obfuscate","uglier"],"created_at":"2025-04-23T23:43:54.428Z","updated_at":"2025-04-23T23:43:59.595Z","avatar_url":"https://github.com/brianoy.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SketchObfus\nJust scrambles your arduino code variable names to make the code harder to read. Focused on what it does best: making things slightly uglier.\n\n| before | after |\n|:------------:|:-------------:|\n| \u003cimg src=\"https://github.com/user-attachments/assets/414e6332-f762-4df6-8566-de5236304770\" width = \"90%\"\u003e|\u003cimg src=\"https://github.com/user-attachments/assets/d35a7f1d-9488-4be3-93a8-e6e2f5d5d684\" width = \"90%\"\u003e|\n\n## 🔧 Features\n\n- Removes both C-style (`/* */`) and C++-style (`//`) comments\n- Obfuscates:\n  - Global and local variables\n  - Function names\n  - Function parameters\n  - Object instances (e.g., `Servo myServo;`)\n- Ignores Arduino reserved keywords and function names\n- Outputs clean, comment-free obfuscated code\n\n## 📦 Requirements\n\n- Python 3.13\n\n## 🚀 Usage\n\n1. Clone this project\n\n```bash\ngit clone https://github.com/brianoy/SketchObfus.git\n```\n\n2. Start obfuscated\n\n```bash\npython SketchObfus.py your_sketch.ino\n```\n\nThis generates an obfuscated version of the sketch named `your_sketch_obf.ino`.\n\nYou can also specify a custom output filename:\n\n```bash\npython SketchObfus.py your_sketch.ino obfuscated_output.ino\n```\n\n## 📁 Example\n\nBefore:\n```cpp\nint ledPin = 13;\nvoid setup() {\n  pinMode(ledPin, OUTPUT);\n}\nvoid loop() {\n  digitalWrite(ledPin, HIGH);\n  delay(1000);\n  digitalWrite(ledPin, LOW);\n  delay(1000);\n}\n```\n\nAfter:\n```cpp\nint _0xA3B1C2D4 = 13;\nvoid _0x1F9A3B7C() {\n  pinMode(_0xA3B1C2D4, OUTPUT);\n}\nvoid _0x6D9C7A2E() {\n  digitalWrite(_0xA3B1C2D4, HIGH);\n  delay(1000);\n  digitalWrite(_0xA3B1C2D4, LOW);\n  delay(1000);\n}\n```\n\n## 🛡️ Limitations\n\n- Not suitable for sketches that rely on external macro-generated names or dynamically referenced variables.\n- Does not analyze code semantically — relies solely on regex patterns.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrianoy%2Fsketchobfus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbrianoy%2Fsketchobfus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrianoy%2Fsketchobfus/lists"}