Skip to content

Commit 9b4f200

Browse files
johnsideserfclaude
andauthored
Add proxy config passthrough to signal-cli (#178)
Adds a `proxy` field to config.toml that gets passed through as `--proxy <url>` when spawning signal-cli. Useful for connecting through Signal TLS proxies in censored regions. Closes #165. Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent c9155b2 commit 9b4f200

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/config.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ pub struct Config {
8383
/// Keybinding profile name (matches a built-in or custom profile)
8484
#[serde(default = "default_keybinding_profile")]
8585
pub keybinding_profile: String,
86+
87+
/// Signal TLS proxy URL passed through to signal-cli (e.g., "https://signal-proxy.example.com")
88+
#[serde(default)]
89+
pub proxy: String,
8690
}
8791

8892
fn default_true() -> bool {
@@ -138,6 +142,7 @@ impl Default for Config {
138142
sidebar_on_right: false,
139143
theme: default_theme(),
140144
keybinding_profile: default_keybinding_profile(),
145+
proxy: String::new(),
141146
}
142147
}
143148
}

src/signal/client.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,9 @@ impl SignalClient {
3333
if !config.account.is_empty() {
3434
cmd.arg("-a").arg(&config.account);
3535
}
36+
if !config.proxy.is_empty() {
37+
cmd.arg("--proxy").arg(&config.proxy);
38+
}
3639
cmd.arg("jsonRpc");
3740
cmd.stdin(std::process::Stdio::piped())
3841
.stdout(std::process::Stdio::piped())

0 commit comments

Comments
 (0)