mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-03 00:31:50 +00:00
Add privacy option (#2016)
Adds a `--privacy` CLI flag to the beacon node that users may opt into. This does two things: - Removes client identifying information from the identify libp2p protocol - Changes the default graffiti to "" if no graffiti is set.
This commit is contained in:
@@ -305,6 +305,8 @@ pub fn get_config<E: EthSpec>(
|
||||
}
|
||||
|
||||
graffiti.as_bytes()
|
||||
} else if cli_args.is_present("private") {
|
||||
b""
|
||||
} else {
|
||||
lighthouse_version::VERSION.as_bytes()
|
||||
};
|
||||
@@ -577,6 +579,10 @@ pub fn set_network_config(
|
||||
config.upnp_enabled = false;
|
||||
}
|
||||
|
||||
if cli_args.is_present("private") {
|
||||
config.private = true;
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user