oasis-core
oasis-core copied to clipboard
go/common/crypto/signature/signers: Sort out the RPC situation
We now have 2 flavors of RPC backed signers:
signers/plugin- A simplifiednet/rpcinterface for use withgo-pluginsigners/remote- A more fully fleshed out gRPC interface for the remote-signer API.
We could consider unifying these as go-plugin supports plugins that use gRPC as the transport (though I do not know how nicely it plays with our custom codec situation).
The rationale for using net/rpc for the plugin signer was purely one of expediency, and I have no strong attachment to the interface, beyond "it works, so why mess with it". As the plugin package supports versioning I expect the transition to be fairly painless.
One side benefit of transitioning the plugin signer to gRPC would be the ability to write plugins in non-Go languages, but that also does not seem all that urgent.
I'd like to voice support for gRPC so that I can continue to not write Go.
Patches accepted (This isn't going to happen anywhere in the near future).
nvm. go-grpc doesn't seem to want to allow custom dialers. I could more easily modify the remote signer, but those changes (custom dialer + making TLS certs optional) will never get upstreamed. I guess I'll make a net/rpc->gRPC plugin...
Since the SDK cli can interact with ledger devices, and I added the ability to use the SDK cli binary as a signers/remote endpoint over AF_LOCAL, I think that the answer here is to deprecate signers/plugin, though this depends on #3220 and the CLI getting an actual releng process.