{"id":50773374,"url":"https://github.com/gaidardzhiev/bundle","last_synced_at":"2026-06-11T21:01:41.141Z","repository":{"id":363060354,"uuid":"1163476468","full_name":"gaidardzhiev/bundle","owner":"gaidardzhiev","description":"A self extracting archive generator that reads files and emits a POSIX shell script which, when executed, reconstructs the originals byte for byte.","archived":false,"fork":false,"pushed_at":"2026-06-07T09:10:33.000Z","size":41,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-07T09:21:38.866Z","etag":null,"topics":["archiver","ioccc","obfuscated","posix","self-extracting-script","shell"],"latest_commit_sha":null,"homepage":"","language":"Shell","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/gaidardzhiev.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING","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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-21T17:33:47.000Z","updated_at":"2026-06-07T09:10:38.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/gaidardzhiev/bundle","commit_stats":null,"previous_names":["gaidardzhiev/bundle"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/gaidardzhiev/bundle","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaidardzhiev%2Fbundle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaidardzhiev%2Fbundle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaidardzhiev%2Fbundle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaidardzhiev%2Fbundle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gaidardzhiev","download_url":"https://codeload.github.com/gaidardzhiev/bundle/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaidardzhiev%2Fbundle/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34217312,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-11T02:00:06.485Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["archiver","ioccc","obfuscated","posix","self-extracting-script","shell"],"created_at":"2026-06-11T21:01:40.054Z","updated_at":"2026-06-11T21:01:41.126Z","avatar_url":"https://github.com/gaidardzhiev.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"### BUNDLE\nThis program reads one or more files from the command line and emits a self extracting POSIX shell script that, when executed, reconstructs the input files with their original contents intact.\nIt functions as a bundle generator, embedding file contents within executable archives that restore originals upon execution.\n\n### Obfuscation layers (applied cumulatively)\n- Identifier mutation: Every function, variable, and macro name is meaningless junk; `main` is now a trampoline into `m0xF1aB`.\n- Encrypted strings: All human readable text is XORed with a key; the key and ciphertexts themselves are stored base64 encoded after a rotate right by 3 on each byte, then decoded and decrypted once at startup.\n- Control flow flattening: The entire program runs as a single `switch` driven state machine loop; conventional `if`/`while` logic is replaced with explicit state transitions plus opaque predicates to obscure reachability.\n- Data obfuscation: Buffer sizes are defined via bit soup macros; constants are assembled from split bitfields. A hidden, unreachable state contains a secret signature as an Easter egg.\n- Macro layer: Macros wrap flow keywords (`LOOP`, `SWITCH`, `CASE`, `NEXT`, `RET`) and inject a red herring XOR macro (`A/B`) plus unused predicate scaffolding (`Z`, `W`, `PRED`) to complicate static reading.\n\nRuntime flow:\n1) One time decode step rebuilds key and message tables, rotates them back, then XOR decrypts to get usable strings.\n2) State machine path:\n   - States 0–3: argument count check, usage print, optional self shebang replay, exit.\n   - States 4–13: emit shell header, iterate inputs, emit here doc wrappers, stream file bytes, close docs; missing files trigger a decrypted warning; the hidden unreachable 13th state contains the Easter egg code.\n\n### Testing\n- Verify with `make clobber`, `make`, and `./try.sh` or manually; the generated bundle faithfully reproduces the files byte for byte against the originals.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgaidardzhiev%2Fbundle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgaidardzhiev%2Fbundle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgaidardzhiev%2Fbundle/lists"}