Rebase and fixes.
This commit is contained in:
parent
dba69f0ddf
commit
5885068c63
|
@ -292,7 +292,7 @@ type
|
|||
name: "rest-port" }: Port
|
||||
|
||||
restAddress* {.
|
||||
defaultValue: defaultAdminListenAddress(config)
|
||||
defaultValue: defaultAdminListenAddress
|
||||
desc: "Listening address of the REST server"
|
||||
name: "rest-address" }: ValidIpAddress
|
||||
|
||||
|
|
|
@ -73,7 +73,7 @@ type
|
|||
|
||||
# Almost validated, pending cryptographic signature check
|
||||
# ----------------------------------------------------------------
|
||||
batchCrypto: ref BatchCrypto
|
||||
batchCrypto*: ref BatchCrypto
|
||||
|
||||
# Missing information
|
||||
# ----------------------------------------------------------------
|
||||
|
|
|
@ -752,8 +752,9 @@ proc installBeaconApiHandlers*(router: var RestRouter, node: BeaconNode) =
|
|||
var failures: seq[RestAttestationsFailureTuple]
|
||||
for atindex, attestation in attestations.pairs():
|
||||
let wallTime = node.processor.getWallTime()
|
||||
let res = node.attestationPool[].validateAttestation(
|
||||
attestation, wallTime, attestation.data.index, true
|
||||
let res = await node.attestationPool.validateAttestation(
|
||||
node.processor.batchCrypto, attestation, wallTime,
|
||||
attestation.data.index, true
|
||||
)
|
||||
if res.isErr():
|
||||
failures.add((index: uint64(atindex), message: $res.error()))
|
||||
|
|
|
@ -323,7 +323,9 @@ proc installValidatorApiHandlers*(router: var RestRouter, node: BeaconNode) =
|
|||
dres.get()
|
||||
|
||||
let wallTime = node.processor.getWallTime()
|
||||
let res = node.attestationPool[].validateAggregate(payload, wallTime)
|
||||
let res = await node.attestationPool.validateAggregate(
|
||||
node.processor.batchCrypto, payload, wallTime
|
||||
)
|
||||
if res.isErr():
|
||||
return RestApiResponse.jsonError(Http400, "Aggregate and proofs " &
|
||||
"verification failed", $res.error())
|
||||
|
|
Loading…
Reference in New Issue