Update file permissions (#2499)

## Issue Addressed

Resolves #2438 
Resolves #2437 

## Proposed Changes

Changes the permissions for validator client http server api token file and secret key to 600 from 644. Also changes the permission for logfiles generated using the `--logfile` cli option to 600.

Logs the path to the api token instead of the actual api token. Updates docs to reflect the change.
This commit is contained in:
Pawan Dhananjay
2021-09-03 02:41:10 +00:00
parent 50321c6671
commit 6f18f95893
7 changed files with 38 additions and 17 deletions

View File

@@ -125,7 +125,7 @@ pub fn serve<T: 'static + SlotClock + Clone, E: EthSpec>(
}
let authorization_header_filter = ctx.api_secret.authorization_header_filter();
let api_token = ctx.api_secret.api_token();
let api_token_path = ctx.api_secret.api_token_path();
let signer = ctx.api_secret.signer();
let signer = warp::any().map(move || signer.clone());
@@ -505,7 +505,7 @@ pub fn serve<T: 'static + SlotClock + Clone, E: EthSpec>(
log,
"HTTP API started";
"listen_address" => listening_socket.to_string(),
"api_token" => api_token,
"api_token_file" => ?api_token_path,
);
Ok((listening_socket, server))