mirror of
https://github.com/corda/corda.git
synced 2025-06-16 22:28:15 +00:00
CORDA-521: Backwards compatible Transactions using sub-Merkle trees (#1481)
* tx backwards compatibility + rebase * SHA256d definition
This commit is contained in:
committed by
josecoll
parent
477ea3a5e1
commit
6887947a4d
@ -138,9 +138,9 @@ class BFTNonValidatingNotaryService(override val services: ServiceHubInternal, c
|
||||
fun verifyAndCommitTx(ftx: FilteredTransaction, callerIdentity: Party): BFTSMaRt.ReplicaResponse {
|
||||
return try {
|
||||
val id = ftx.id
|
||||
val inputs = ftx.filteredLeaves.inputs
|
||||
val inputs = ftx.inputs
|
||||
|
||||
validateTimeWindow(ftx.filteredLeaves.timeWindow)
|
||||
validateTimeWindow(ftx.timeWindow)
|
||||
commitInputStates(inputs, id, callerIdentity)
|
||||
log.debug { "Inputs committed successfully, signing $id" }
|
||||
BFTSMaRt.ReplicaResponse.Signature(sign(ftx))
|
||||
|
@ -1,6 +1,7 @@
|
||||
package net.corda.node.services.transactions
|
||||
|
||||
import co.paralleluniverse.fibers.Suspendable
|
||||
import net.corda.core.contracts.ComponentGroupEnum
|
||||
import net.corda.core.flows.NotaryFlow
|
||||
import net.corda.core.flows.TransactionParts
|
||||
import net.corda.core.identity.Party
|
||||
@ -24,7 +25,9 @@ class NonValidatingNotaryFlow(otherSide: Party, service: TrustedAuthorityNotaryS
|
||||
when (it) {
|
||||
is FilteredTransaction -> {
|
||||
it.verify()
|
||||
TransactionParts(it.id, it.filteredLeaves.inputs, it.filteredLeaves.timeWindow)
|
||||
it.checkAllComponentsVisible(ComponentGroupEnum.INPUTS_GROUP)
|
||||
it.checkAllComponentsVisible(ComponentGroupEnum.TIMEWINDOW_GROUP)
|
||||
TransactionParts(it.id, it.inputs, it.timeWindow)
|
||||
}
|
||||
is NotaryChangeWireTransaction -> TransactionParts(it.id, it.inputs, null)
|
||||
else -> {
|
||||
|
Reference in New Issue
Block a user