v0.0.39 - Remove qrexec one-shot (option 4) from interactive transport menu — only persistent listeners remain

This commit is contained in:
Laan Tungir
2026-07-11 13:42:59 -04:00
parent d28f691aae
commit 922a45ce3a

View File

@@ -503,8 +503,8 @@ int socket_name_random(char *out, size_t out_len);
/* Version information (auto-updated by build/version tooling) */ /* Version information (auto-updated by build/version tooling) */
#define NSIGNER_VERSION_MAJOR 0 #define NSIGNER_VERSION_MAJOR 0
#define NSIGNER_VERSION_MINOR 0 #define NSIGNER_VERSION_MINOR 0
#define NSIGNER_VERSION_PATCH 38 #define NSIGNER_VERSION_PATCH 39
#define NSIGNER_VERSION "v0.0.38" #define NSIGNER_VERSION "v0.0.39"
/* NSIGNER_HEADERLESS_DECLS_END */ /* NSIGNER_HEADERLESS_DECLS_END */
@@ -1626,9 +1626,7 @@ static int prompt_transport_selection(void) {
(selected & TRANSPORT_QREXEC_BRIDGE) ? "x" : " "); (selected & TRANSPORT_QREXEC_BRIDGE) ? "x" : " ");
printf(" [%s] 3. TCP listener (FIPS mesh or local network)\n", printf(" [%s] 3. TCP listener (FIPS mesh or local network)\n",
(selected & TRANSPORT_TCP) ? "x" : " "); (selected & TRANSPORT_TCP) ? "x" : " ");
printf(" [%s] 4. Qrexec one-shot (legacy, one request per invocation)\n", printf("\n [a] select all Enter = confirm\n");
(selected & TRANSPORT_QREXEC_ONESHOT) ? "x" : " ");
printf("\n [a] select all (except 4) Enter = confirm\n");
printf("> "); printf("> ");
fflush(stdout); fflush(stdout);
@@ -1651,15 +1649,6 @@ static int prompt_transport_selection(void) {
printf("At least one transport must be selected.\n"); printf("At least one transport must be selected.\n");
continue; continue;
} }
/* Qrexec one-shot is mutually exclusive with persistent listeners */
if ((selected & TRANSPORT_QREXEC_ONESHOT) && (selected & ~TRANSPORT_QREXEC_ONESHOT)) {
printf("Qrexec one-shot cannot combine with other transports. Deselecting it.\n");
selected &= ~TRANSPORT_QREXEC_ONESHOT;
if (selected == 0) {
selected = TRANSPORT_UNIX;
}
continue;
}
break; break;
} }
@@ -1674,10 +1663,8 @@ static int prompt_transport_selection(void) {
selected ^= TRANSPORT_QREXEC_BRIDGE; selected ^= TRANSPORT_QREXEC_BRIDGE;
} else if (input[0] == '3') { } else if (input[0] == '3') {
selected ^= TRANSPORT_TCP; selected ^= TRANSPORT_TCP;
} else if (input[0] == '4') {
selected ^= TRANSPORT_QREXEC_ONESHOT;
} else { } else {
printf("Invalid input. Type 1-4, 'a', or Enter to confirm.\n"); printf("Invalid input. Type 1-3, 'a', or Enter to confirm.\n");
} }
} }
@@ -1982,30 +1969,24 @@ int main(int argc, char *argv[]) {
return 1; return 1;
} }
/* Qrexec one-shot: use existing single-listener path */ /* Persistent listeners — configure from menu selection */
if (transport_mask & TRANSPORT_QREXEC_ONESHOT) { multi_listen = 1;
listen_mode = NSIGNER_LISTEN_QREXEC;
listen_mode_explicit = 1;
} else {
/* Persistent listeners — configure from menu selection */
multi_listen = 1;
/* Unix socket (with or without bridge-source-trusted) */ /* Unix socket (with or without bridge-source-trusted) */
if (transport_mask & (TRANSPORT_UNIX | TRANSPORT_QREXEC_BRIDGE)) { if (transport_mask & (TRANSPORT_UNIX | TRANSPORT_QREXEC_BRIDGE)) {
/* Use fixed name "nsigner" for scripted access */ /* Use fixed name "nsigner" for scripted access */
socket_name = "nsigner"; socket_name = "nsigner";
socket_name_explicit = 1; socket_name_explicit = 1;
listen_mode = NSIGNER_LISTEN_UNIX; listen_mode = NSIGNER_LISTEN_UNIX;
listen_target = socket_name; listen_target = socket_name;
if (transport_mask & TRANSPORT_QREXEC_BRIDGE) { if (transport_mask & TRANSPORT_QREXEC_BRIDGE) {
bridge_source_trusted = 1; bridge_source_trusted = 1;
}
} }
}
/* TCP listener */ /* TCP listener */
if (transport_mask & TRANSPORT_TCP) { if (transport_mask & TRANSPORT_TCP) {
/* Will be started as a second listener */ /* Will be started as a second listener */
}
} }
} }