finding: boot.ps1 keyboard pad reads unfocused keystrokes; NVIDIA ucode.elf lands in the repo root #1552

Closed
opened 2026-11-26 09:56:20 +00:00 by github-bot · 2 comments
Owner

@⁠QemmHD on GitHub · 2026-11-25 04:18 UTC · original

Two hazards in scripts/windows-boot/boot.ps1 runs, found while booting on Windows 11 / RTX 4070 SUPER. (Posted as an issue because #14 has reached GitHub's 2,500-comment limit and no longer takes comments.)

  1. The keyboard pad reads the real keyboard when the game isn't focused. boot.ps1 sets LEONIDA_KEYBOARD_PAD=always, which reads the physical keyboard even when the title window isn't focused. In one run, 15 real key presses typed into other programs (Q/E, Y, X, Backspace, Enter) were logged as pad buttons. An Enter while the title sits on a first-run consent page could tick a consent box in the user's name. LEONIDA_KEYBOARD_PAD=1 (focus-gated) avoids it, and scripted presses still work. This overlaps milk4sale's RT-KEYBOARD-PAD-SCRIPT.
  2. ucode.elf lands in the repository root (a no-game-data trap). On every boot, gta6rt's process leaves an NVIDIA-format ucode.elf (ELF, e_machine 190) in its working directory, and boot.ps1 sets that to the repository root. It isn't covered by .gitignore. It's derived from a translated title shader, so anyone who runs git add -A after a boot would commit title-derived data. It's probably written by the NVIDIA driver when LEONIDA_DEVICE_FAULT=1 enables VK_NV_device_diagnostics_config (a hypothesis, not verified). Suggested fixes: add ucode.elf (or *.elf at the root) to .gitignore, and run the boot from a scratch working directory.

Counts only; no game data attached.

AI-assisted (Claude Code, Claude Opus 5.5).

**@⁠QemmHD** on GitHub · 2026-11-25 04:18 UTC · [original](https://github.com/ubiquitarianism/leonida/issues/1552) Two hazards in `scripts/windows-boot/boot.ps1` runs, found while booting on Windows 11 / RTX 4070 SUPER. (Posted as an issue because #14 has reached GitHub's 2,500-comment limit and no longer takes comments.) 1. **The keyboard pad reads the real keyboard when the game isn't focused.** `boot.ps1` sets `LEONIDA_KEYBOARD_PAD=always`, which reads the physical keyboard even when the title window isn't focused. In one run, 15 real key presses typed into other programs (Q/E, Y, X, Backspace, Enter) were logged as pad buttons. An Enter while the title sits on a first-run consent page could tick a consent box in the user's name. `LEONIDA_KEYBOARD_PAD=1` (focus-gated) avoids it, and scripted presses still work. This overlaps milk4sale's RT-KEYBOARD-PAD-SCRIPT. 2. **`ucode.elf` lands in the repository root (a no-game-data trap).** On every boot, gta6rt's process leaves an NVIDIA-format `ucode.elf` (ELF, e_machine 190) in its working directory, and `boot.ps1` sets that to the repository root. It isn't covered by `.gitignore`. It's derived from a translated title shader, so anyone who runs `git add -A` after a boot would commit title-derived data. It's probably written by the NVIDIA driver when `LEONIDA_DEVICE_FAULT=1` enables VK_NV_device_diagnostics_config (a hypothesis, not verified). Suggested fixes: add `ucode.elf` (or `*.elf` at the root) to `.gitignore`, and run the boot from a scratch working directory. Counts only; no game data attached. AI-assisted (Claude Code, Claude Opus 5.5).
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:56:20 +00:00
Author
Owner

@⁠lixonik on GitHub · 2026-11-25 06:17 UTC · original

Thanks for recording this while #14 was full. I added the finding and a link to this report in #1608, the continuation of #14. If you no longer need this issue to track either hazard independently, would you consider closing it?

**@⁠lixonik** on GitHub · 2026-11-25 06:17 UTC · [original](https://github.com/ubiquitarianism/leonida/issues/1552#issuecomment-7154634597) Thanks for recording this while #14 was full. I added the finding and a link to this report in [#1608, the continuation of #14](https://git.gtahub.st/github/ubiquitarianism--leonida/issues/1608). If you no longer need this issue to track either hazard independently, would you consider closing it?
Author
Owner

@⁠QemmHD on GitHub · 2026-11-25 06:22 UTC · original

Closing as suggested: both hazards are recorded in #1608 (lixonik's comment 7154627786), and the keyboard part overlaps RT-KEYBOARD-PAD-SCRIPT. Thanks, lixonik.

AI-assisted (Claude Code, Claude Opus 5.5).

**@⁠QemmHD** on GitHub · 2026-11-25 06:22 UTC · [original](https://github.com/ubiquitarianism/leonida/issues/1552#issuecomment-7154729929) Closing as suggested: both hazards are recorded in #1608 (lixonik's comment 7154627786), and the keyboard part overlaps RT-KEYBOARD-PAD-SCRIPT. Thanks, lixonik. AI-assisted (Claude Code, Claude Opus 5.5).
This discussion has been locked. Commenting is limited to contributors.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/ubiquitarianism--leonida#1552
No description provided.