gossipd: don't try to connect to non-routable addresses.

Someone could try to announce an internal address, and we might probe
it.

This breaks tests, so we add '--dev-allow-localhost' for our tests, so
we don't eliminate that one.  Of course, now we need to skip some more
tests in non-developer mode.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2018-05-07 13:59:22 +09:30
committed by Christian Decker
parent af065417e1
commit d40d22b68e
16 changed files with 66 additions and 38 deletions

View File

@@ -189,6 +189,9 @@ struct lightningd {
/* If we have --dev-fail-on-subdaemon-fail */
bool dev_subdaemon_fail;
/* Allow and accept localhost node_announcement addresses */
bool dev_allow_localhost;
/* Things we've marked as not leaking. */
const void **notleaks;
#endif /* DEVELOPER */