FuelLabs/forc-wallet

Write prototype to share keys / accounts between forc-wallet and other local clients

cr-fuel opened this issue · 0 comments

The main idea of this prototype is to create a local webserver (http for now, https later if the prototype is accepted). This webserver will expose the private key of the wallet, previous authorization from the user (in the CLI).

The workflow is quite simple, from the clients' point of view.

  1. Clients will make a request to localhost:999/forc-wallet. This will fail or timeout unless forc-wallet is listening for requests (most likely it will be opt-in, maybe we can create a service).
  2. If localhost:9999/forc-wallet comes back successfully the client will request for the private keys.
  3. The forc-wallet will prompt the user X client from Browser Y is requesting access to your account. Would you grant it? If the user has a single account and accepts it, it will be shared, otherwise, the user will be prompted to which account they'd like to share.
  4. Clients will more likely be browser extension and VSCode, but any forc client that speaks HTTPs and is running locally can benefit from this feature.