Skip to content

Commit 73fa7cd

Browse files
rustyrussellremyers
authored andcommitted
lightningd: remove --bind-addr and --addr munging on onions and local sockets.
Changelog-Removed: --bind-addr and --addr on onion addresses and local sockets (deprecated v23.08, disabled by default in v24.11). Signed-off-by: Rusty Russell <[email protected]>
1 parent 978f9ad commit 73fa7cd

File tree

2 files changed

+8
-33
lines changed

2 files changed

+8
-33
lines changed

doc/developers-guide/deprecations.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@ hidden: false
77

88
| Name | Type | First Deprecated | Last Supported | Description |
99
|--------------------------------------|--------------------|------------------|----------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
10-
| bind-addr.torv3 | Config | v23.08 | v24.08 | `announce-addr` makes more sense for Tor addresses |
11-
| addr.torv3 | Config | v23.08 | v24.08 | `announce-addr` makes more sense for Tor addresses |
12-
| addr.socket | Config | v23.08 | v24.08 | `bind-addr` makes more sense for local sockets since we cannot announce them |
1310
| announce-addr-dns | Config | v23.08 | v24.08 | Use `bind-addr=dns:` to specify DNS announcements on a per-address basis |
1411
| rest-port.clnrest-prefix | Config | v23.11 | v24.11 | Autodetect where we need to rename `rest-port` to `clnrest-port` (added in v23.11) |
1512
| rest-protocol.clnrest-prefix | Config | v23.11 | v24.11 | Autodetect where we need to rename `rest-protocol` to `clnrest-protocol` (added in v23.11) |

lightningd/options.c

Lines changed: 8 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -267,31 +267,13 @@ static char *opt_add_addr_withtype(const char *arg,
267267
case ADDR_TYPE_TOR_V3:
268268
switch (ala) {
269269
case ADDR_LISTEN:
270-
if (!opt_deprecated_ok(ld, "bind-addr", "torv3",
271-
"v23.08", "v24.08"))
272-
return tal_fmt(tmpctx,
273-
"Don't use --bind-addr=%s, use --announce-addr=%s",
274-
arg, arg);
275-
log_unusual(ld->log,
276-
"You used `--bind-addr=%s` option with an .onion address,"
277-
" You are lucky in this node live some wizards and"
278-
" fairies, we have done this for you and don't announce, Be as hidden as wished",
279-
arg);
280-
/* And we ignore it */
281-
return NULL;
270+
return tal_fmt(tmpctx,
271+
"Don't use --bind-addr=%s, use --announce-addr=%s",
272+
arg, arg);
282273
case ADDR_LISTEN_AND_ANNOUNCE:
283-
if (!opt_deprecated_ok(ld, "addr", "torv3",
284-
"v23.08", "v24.08"))
285-
return tal_fmt(tmpctx,
286-
"Don't use --addr=%s, use --announce-addr=%s",
287-
arg, arg);
288-
log_unusual(ld->log,
289-
"You used `--addr=%s` option with an .onion address,"
290-
" You are lucky in this node live some wizards and"
291-
" fairies, we have done this for you and don't announce, Be as hidden as wished",
292-
arg);
293-
ala = ADDR_LISTEN;
294-
break;
274+
return tal_fmt(tmpctx,
275+
"Don't use --addr=%s, use --announce-addr=%s",
276+
arg, arg);
295277
case ADDR_ANNOUNCE:
296278
break;
297279
}
@@ -326,12 +308,8 @@ static char *opt_add_addr_withtype(const char *arg,
326308
return tal_fmt(tmpctx,
327309
"Cannot announce sockets, try --bind-addr=%s", arg);
328310
case ADDR_LISTEN_AND_ANNOUNCE:
329-
if (!opt_deprecated_ok(ld, "addr", "socket",
330-
"v23.08", "v24.08"))
331-
return tal_fmt(tmpctx, "Don't use --addr=%s, use --bind-addr=%s",
332-
arg, arg);
333-
ala = ADDR_LISTEN;
334-
/* Fall thru */
311+
return tal_fmt(tmpctx, "Don't use --addr=%s, use --bind-addr=%s",
312+
arg, arg);
335313
case ADDR_LISTEN:
336314
break;
337315
}

0 commit comments

Comments
 (0)