From ff0a7769856d8ad29ef07ff330f58380502fe47a Mon Sep 17 00:00:00 2001 From: Calvin Lau Date: Wed, 24 Nov 2021 15:46:02 +0800 Subject: [PATCH 1/3] Problem: gRPC server is recommended to be enabled by default Solution: Update to recommend disable gRPC server --- docs/resources/node-and-rpc-setup-notes.md | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/docs/resources/node-and-rpc-setup-notes.md b/docs/resources/node-and-rpc-setup-notes.md index fbf95495..e642f8ce 100644 --- a/docs/resources/node-and-rpc-setup-notes.md +++ b/docs/resources/node-and-rpc-setup-notes.md @@ -13,7 +13,7 @@ $ sed -i.bak -E 's#^(timeout_commit[[:space:]]+=[[:space:]]+).*$#\1"5s"#' ~/.cro ``` -### Enable API and gRPC server +### Enable API server Edit `~/.cronos/config/app.toml` and update the following section ```toml @@ -29,14 +29,19 @@ swagger = true address = "tcp://0.0.0.0:1317" ... +``` + +### Disable gRPC server +\:::warning Important: +We recommend to disable gRPC server on public nodes to reduce the attack vector +::: +``` +Edit `~/.cronos/config/app.toml` and update the following section [grpc] # Enable defines if the gRPC server should be enabled. -enable = true - -# Address defines the gRPC server address to bind to. -address = "0.0.0.0:9090" +enable = false ``` ### Start the node From fd59f7d81375c487e57029aae03afc201474b470 Mon Sep 17 00:00:00 2001 From: Calvin Lau Date: Sun, 28 Nov 2021 21:10:20 +0800 Subject: [PATCH 2/3] Update text --- docs/resources/node-and-rpc-setup-notes.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/resources/node-and-rpc-setup-notes.md b/docs/resources/node-and-rpc-setup-notes.md index e642f8ce..8efadfbb 100644 --- a/docs/resources/node-and-rpc-setup-notes.md +++ b/docs/resources/node-and-rpc-setup-notes.md @@ -27,17 +27,16 @@ swagger = true # Address defines the API server to listen on. address = "tcp://0.0.0.0:1317" - -... ``` -### Disable gRPC server -\:::warning Important: +### Disable gRPC server on public nodes + +\:::warning Recommendation: We recommend to disable gRPC server on public nodes to reduce the attack vector ::: -``` Edit `~/.cronos/config/app.toml` and update the following section +```toml [grpc] # Enable defines if the gRPC server should be enabled. From aeb74c974d79eef5784566d838b1e481b730475b Mon Sep 17 00:00:00 2001 From: Calvin Lau Date: Sun, 28 Nov 2021 23:16:16 +0800 Subject: [PATCH 3/3] Fix warning tag --- docs/resources/node-and-rpc-setup-notes.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/resources/node-and-rpc-setup-notes.md b/docs/resources/node-and-rpc-setup-notes.md index 8efadfbb..6a26ebf9 100644 --- a/docs/resources/node-and-rpc-setup-notes.md +++ b/docs/resources/node-and-rpc-setup-notes.md @@ -31,7 +31,7 @@ address = "tcp://0.0.0.0:1317" ### Disable gRPC server on public nodes -\:::warning Recommendation: +:::warning Recommendation: We recommend to disable gRPC server on public nodes to reduce the attack vector :::