diff --git a/CHANGELOG.md b/CHANGELOG.md index 738fb38e..954bad84 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ Changelog for FrostFS Node - Take network settings into account during netmap contract update (#100) - Read config files from dir even if config file not provided via `--config` for node (#238) - Expired by more than 1 epoch objects could be returned (#262) +- Notary requests parsing according to `neo-go`'s updates (#268) ### Removed ### Updated diff --git a/pkg/morph/event/notary_preparator.go b/pkg/morph/event/notary_preparator.go index 3d499fec..f7b10d90 100644 --- a/pkg/morph/event/notary_preparator.go +++ b/pkg/morph/event/notary_preparator.go @@ -185,13 +185,15 @@ func (p Preparator) validateNotaryRequest(nr *payload.P2PNotaryRequest) error { } invokerWitness := ln == 4 + multiInvScript := nr.MainTransaction.Scripts[1].InvocationScript + // alphabet node should handle only notary requests - // that have been sent unsigned(by storage nodes) => - // such main TXs should have dummy scripts as an - // invocation script + // that have been sent unsigned (by storage nodes) => + // such main TXs should have either a dummy or an + // empty script as an invocation script // // this check prevents notary flow recursion - if !bytes.Equal(nr.MainTransaction.Scripts[1].InvocationScript, p.dummyInvocationScript) { + if len(multiInvScript) > 0 && !bytes.Equal(nr.MainTransaction.Scripts[1].InvocationScript, p.dummyInvocationScript) { return ErrTXAlreadyHandled }