diff --git a/CHANGELOG.md b/CHANGELOG.md index a13e18156a..f8b6134b9d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ Changelog for NeoFS Node - Concurrent morph cache misses (#1248) - Double voting for validators on IR startup (#2365) - Skip unexpected notary events on notary request parsing step (#2315) +- Session inactivity on object PUT request relay (#2460) ### Removed - Deprecated `morph.rpc_endpoint` SN and `morph.endpoint.client` IR config sections (#2400) diff --git a/pkg/services/object/acl/v2/service.go b/pkg/services/object/acl/v2/service.go index f3948d88e4..298b1a8f7b 100644 --- a/pkg/services/object/acl/v2/service.go +++ b/pkg/services/object/acl/v2/service.go @@ -479,16 +479,12 @@ func (p putStreamBasicChecker) Send(request *objectV2.PutRequest) error { } } - var sTok *sessionSDK.Object - - if tokV2 := request.GetMetaHeader().GetSessionToken(); tokV2 != nil { - sTok = new(sessionSDK.Object) - - err = sTok.ReadFromV2(*tokV2) - if err != nil { - return fmt.Errorf("invalid session token: %w", err) - } + sTok, err := originalSessionToken(request.GetMetaHeader()) + if err != nil { + return err + } + if sTok != nil { if sTok.AssertVerb(sessionSDK.VerbObjectDelete) { // if session relates to object's removal, we don't check // relation of the tombstone to the session here since user