dappnode / eth2-keymanager-frontend

Web UI to manage Eth2 keystores to be used with any validator client.
GNU General Public License v3.0
21 stars 7 forks source link

Implement fee recipient API #17

Open pablomendezroyo opened 2 years ago

pablomendezroyo commented 2 years ago

Implement the Fee recipient API to allow setting different addresses for each pubkey, also implement a switch button to set the same one for all of them.

tropicar commented 2 years ago

The fee recipient must be mandatory, by default the client assigns the burnout value instead. In my opinion.

dsimog01 commented 2 years ago

All clients support GET/POST requests to .../feerecipient endpoint

dsimog01 commented 2 years ago

The METHOD_NOT_ALLOWED error was shown because the header "Content-type:application/json" was missing.

dsimog01 commented 2 years ago
Check /feerecipient for all consensus clients: Tables Postman GET Postman POST TS Test GET TS Test POST Browser GET Browser POST
Prysm OK OK OK OK CORS CORS
Teku OK OK OK OK CORS CORS
Nimbus OK OK OK OK CORS CORS
Lighthouse OK OK OK OK OK Error

In order to perform the GET/POST requests to Teku, it is necessary to include a .p12 certificate and passphrase. The module "axios" is required for this task

dsimog01 commented 2 years ago

To read the .p12 certificate, the code must not be executed in the browser. Moreover, there are CORS politics that block requests from the browser.

To solve this, a proxy server can be a feasible alternative.

dsimog01 commented 2 years ago

Performing GET/POST /feerecipient through the proxy server via browser:

X GET POST
Prysm OK OK
Teku OK OK
Nimbus OK OK
Lighthouse OK OK

Note that Teku does not allow to set the burn address (0x00..00) via its API. This must be taken into account