Creating an external signer for EthSigner
EthSigner supports the addition of more external signers in same way as HashiCorp Vault.
To create an external signer:
Clone the EthSigner repository.
Create a Gradle module for the new signer in the
ethsigner/signerdirectory.To ensure the module for the new signer is built, add the module to the
settings.gradlefile.In the new module, create a concrete child class of
SignerSubCommand.The new
SignerSubCommandmust include the parameters (tagged with PicoCLI annotations) to initialize your signer.Update the
createSigner()function to be the entry point to create and return your signer. Your signer is exposed only as aTransactionSigner.noteThe new signing class is responsible for fulfilling the
TransactionSignerinterface. To fulfill theTransactionSignerinterface, the class must be able to create a signature for a block of bytes and provide the address associated with the key pair in the signer. ::: 6. InEthSignerApp.java, register the newSignerSubCommandwith thecmdLineParseras for existing signers.Update the EthSigner::app module dependency list to include the module created in step 2.