(Thank you for this project! It's awesome. I noticed this when deploying. Here's what Claude found.)
The systemd service installer (scripts/setup/install_service.sh) doesn't support $ characters in MESHCORE_BASIC_AUTH_PASSWORD. Passwords containing $ get silently truncated or corrupted.
What happens
The password is written directly into the unit file on line 323:
Systemd treats $ as a special character for variable substitution in unit files. A password like p@ss$word gets written as-is, but systemd interprets $word as a variable reference (resolving to empty string), so the app receives p@ss instead.
Expected behavior
Passwords with $ should work correctly, or the installer should warn that $ isn't supported.
Fix
Escape $ as $$ before writing to the unit file (the systemd escape for a literal dollar sign):
The same issue applies to MESHCORE_BASIC_AUTH_USERNAME (line 322) and MESHCORE_BLE_PIN (line 311) — any user-supplied value written into the unit file could contain $.
(Thank you for this project! It's awesome. I noticed this when deploying. Here's what Claude found.)
The systemd service installer (`scripts/setup/install_service.sh`) doesn't support `$` characters in `MESHCORE_BASIC_AUTH_PASSWORD`. Passwords containing `$` get silently truncated or corrupted.
## What happens
The password is written directly into the unit file on line 323:
```bash
echo "Environment=MESHCORE_BASIC_AUTH_PASSWORD=${AUTH_PASSWORD}"
```
Systemd treats `$` as a special character for variable substitution in unit files. A password like `p@ss$word` gets written as-is, but systemd interprets `$word` as a variable reference (resolving to empty string), so the app receives `p@ss` instead.
## Expected behavior
Passwords with `$` should work correctly, or the installer should warn that `$` isn't supported.
## Fix
Escape `$` as `$$` before writing to the unit file (the systemd escape for a literal dollar sign):
```bash
ESCAPED_PASSWORD="${AUTH_PASSWORD//\$/\$\$}"
echo "Environment=MESHCORE_BASIC_AUTH_PASSWORD=${ESCAPED_PASSWORD}"
```
The same issue applies to `MESHCORE_BASIC_AUTH_USERNAME` (line 322) and `MESHCORE_BLE_PIN` (line 311) — any user-supplied value written into the unit file could contain `$`.
<!-- github-sync-id:4204953663 -->
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
(Thank you for this project! It's awesome. I noticed this when deploying. Here's what Claude found.)
The systemd service installer (
scripts/setup/install_service.sh) doesn't support$characters inMESHCORE_BASIC_AUTH_PASSWORD. Passwords containing$get silently truncated or corrupted.What happens
The password is written directly into the unit file on line 323:
Systemd treats
$as a special character for variable substitution in unit files. A password likep@ss$wordgets written as-is, but systemd interprets$wordas a variable reference (resolving to empty string), so the app receivesp@ssinstead.Expected behavior
Passwords with
$should work correctly, or the installer should warn that$isn't supported.Fix
Escape
$as$$before writing to the unit file (the systemd escape for a literal dollar sign):The same issue applies to
MESHCORE_BASIC_AUTH_USERNAME(line 322) andMESHCORE_BLE_PIN(line 311) — any user-supplied value written into the unit file could contain$.lol I KNEW this was gonna be so hairy. Thanks for the bug report.