use of tech.pegasys.teku.api.schema.Eth1Data in project web3signer by ConsenSys.
the class Eth2RequestUtils method createBlockRequest.
public static Eth2SigningRequestBody createBlockRequest(final UInt64 slot, final Bytes32 stateRoot) {
final ForkInfo forkInfo = forkInfo();
final BeaconBlock block = new BeaconBlock(slot, UInt64.valueOf(5), Bytes32.fromHexString("0xb2eedb01adbd02c828d5eec09b4c70cbba12ffffba525ebf48aca33028e8ad89"), stateRoot, new BeaconBlockBody(BLSSignature.fromHexString("0xa686652aed2617da83adebb8a0eceea24bb0d2ccec9cd691a902087f90db16aa5c7b03172a35e874e07e3b60c5b2435c0586b72b08dfe5aee0ed6e5a2922b956aa88ad0235b36dfaa4d2255dfeb7bed60578d982061a72c7549becab19b3c12f"), new Eth1Data(Bytes32.fromHexString("0x6a0f9d6cb0868daa22c365563bb113b05f7568ef9ee65fdfeb49a319eaf708cf"), UInt64.valueOf(8), Bytes32.fromHexString("0x4242424242424242424242424242424242424242424242424242424242424242")), Bytes32.fromHexString("0x74656b752f76302e31322e31302d6465762d6338316361363235000000000000"), emptyList(), emptyList(), emptyList(), emptyList(), emptyList()));
final Bytes signingRoot = signingRootUtil.signingRootForSignBlock(block.asInternalBeaconBlock(spec), forkInfo.asInternalForkInfo());
return new Eth2SigningRequestBody(ArtifactType.BLOCK, signingRoot, forkInfo, block, null, null, null, null, null, null, null, null, null, null);
}
Aggregations