https://github.com/aionnetwork/block_signer
https://github.com/aionnetwork/block_signer
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/aionnetwork/block_signer
- Owner: aionnetwork
- Created: 2019-10-30T15:23:13.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-11-06T16:00:32.000Z (over 5 years ago)
- Last Synced: 2023-04-13T08:13:06.415Z (about 3 years ago)
- Language: C
- Size: 36.6 MB
- Stars: 2
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Block Signer
This is a block signer designed to be used with Aion's Unity Hybrid Consensus Protocol. The signer can be used to interact with a Unity-enabled node over RPC.
The signer is largely built on top of the RPC functionality provided by the [Node Test Harness](https://github.com/aionnetwork/node_test_harness "Node Test Harness").
# Launching the signer
The signer can be used directly from the terminal either by passing in the arguments directly or by using a config file.
### Option 1: Command line options
**Usage:**
`java -jar block_signer.jar `
The signer takes the following arguments when launched:
1. **(required)** the private key of the signing address of the registered staker.
2. **(required)** the identity address of the staker.
3. **(required)** the network name. Only `amity` and `mainnet` are supported.
4. *(optional)* the IP address of a Unity-enabled node accepting RPC requests. If this argument isn't provided, `127.0.0.1` is used as default.
5. *(optional)* the port on which this node is accepting RPC requests. If this argument isn't provided, `8545` is used as default.
6. *(optional)* enable or disable verbose logging level. If this argument isn't provided, verbose logging is disabled by default.
If verbose logging is enabled, rpc request and response messages are printed.
### Option 2: Config file
**Usage:**
`java -jar block_signer.jar -config `
The signer takes the following argument when launched:
- **(required)** path to the config file.
---
Note that `java -jar block_signer.jar -h` will print the usage options.
# Behaviour
Once launched, the signer repeatedly queries the node over RPC, and submits signed staking blocks. Note that it aggressively sends a signed block as soon as it produces it; the nodes must reject future blocks if they want to.