Star 历史趋势
数据来源: GitHub API · 生成自 Stargazers.cn
README.md

LightSaber

0xjohnnydev.github.io/lightsaber

⚠ LightSaber is moving to Cyanide

Cyanide is built on a full kernel exploit instead of this WebKit + sandbox-escape chain — no Safari freezes, no failed retries, no kernel panics from a flaky userland exploit. The same tweaks install in one shot from a signed app and persist until respring/reboot. Use LightSaber only if your device can't run Cyanide.

iOS 18.4 - 18.6.2 userland exploit chain with JavaScript injection that modifies SpringBoard and other system processes at runtime, derived from DarkSword with all malware communication stripped. This is runtime JS modification through an exploit chain, not dylib injection like a full jailbreak — changes persist until respring or reboot.

Supported devices

Every arm64e iPhone (A12 - A18 Pro) running iOS 18.4 - 18.6.2.

How it works

LightSaber chains a WebContent RCE into kernel R/W via sandbox escape, then uses a JSC + objc_msgSend / dlsym native bridge to inject JavaScript into other processes (SpringBoard, mediaplaybackd, thermalmonitord, etc.).

Chain stages

StageWhereWhat
index.htmlSafari main pageInstall card UI, tweak picker, gating
rce_loader.jsWebContent iframeURL parser, postMessage routing, exploit bootstrap
rce_worker*.jsWebContent workerJavaScriptCore exploit, addrof/fakeobj/read64/write64 primitives
rce_module*.jsWebContent workerHeap shaping, PAC gadget signing
sbx0_main_18.4.jsWebContent workerSandbox escape
sbx1_main.jsmediaplaybackdPrelude builder, kernel R/W, process injection bridge
pe_main.jsmediaplaybackdPayload dispatch, inject*Payload helpers
*_light.jsTarget processesTweak payloads (run via the native bridge)

Available tweaks

  • SBCustomizer — runtime SpringBoard layout customization: dock icon count, home screen columns and rows, hide icon labels. Patched once during chain execution.
  • Powercuff — port of rpetrich's Powercuff. Underclocks CPU/GPU via thermalmonitord for extended battery life. Four levels: nominal, light, moderate, heavy. Lasts until reboot.

Usage

Visit 0xjohnnydev.github.io/lightsaber in Safari on a supported device. Pick your tweaks, tap Install Selected, and keep Safari in the foreground for up to 60 seconds while the chain runs.

If it fails (page flash, "A problem repeatedly occurred", or "webpage crashed" banner): clear Safari's cache (book icon > Clear), reload, and retry. If it keeps failing, reboot, clear cache again, and try once more.

Debugging with syslog.py

syslog.py is a filtered device syslog viewer that shows only chain-relevant log lines. Requires a Mac with idevicesyslog installed (brew install libimobiledevice) and the device connected via USB.

python3 syslog.py

Each run creates a timestamped log file in logs/ (e.g. logs/syslog_2026-04-09_15-37-00.txt). Log tags are color-coded:

  • Green [PE] [PE-DBG] - post-exploit / kernel phase
  • Magenta [SBX1] SBX0 - sandbox escape stages
  • Cyan [SBC] [POWERCUFF] [MG] [APPLIMIT] [THREEAPP] - tweak payloads
  • Red - crashes, PAC violations, JS errors

See logs/example_successful_run.txt for what a successful chain run looks like.

Project structure

index.html              Main install page (Safari UI)
frame.html              Exploit iframe shell
rce_loader.js           Iframe-side bootstrap + postMessage router
rce_worker.js           WebContent worker (iOS 18.4)
rce_worker_18.6.js      WebContent worker (iOS 18.5-18.6.2)
rce_module.js           Heap shaping module (18.4)
rce_module_18.6.js      Heap shaping module (18.5-18.6.2)
sbx0_main_18.4.js       Sandbox escape
sbx1_main.js            Kernel R/W + process injection bridge
pe_main.js              Payload dispatch in mediaplaybackd
powercuff_light.js      Powercuff payload
sbcustomizer_light.js   SBCustomizer payload
colorbanners_light.js   ColorBanners payload (WIP)
syslog.py               Device syslog capture helper
respring.html           Resprings your device without an exploit

Credits

License

MIT License. See LICENSE for details.

关于 About

iOS 18.4-18.6.2 userland exploit chain with JS injection into SpringBoard and other processes. Derived from DarkSword.

语言 Languages

JavaScript91.2%
HTML8.4%
Python0.4%

提交活跃度 Commit Activity

代码提交热力图
过去 52 周的开发活跃度
456
Total Commits
峰值: 323次/周
Less
More

核心贡献者 Contributors