diff --git a/CHANGELOG.md b/CHANGELOG.md index 974025bec7..2d5109a9e0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,6 +26,7 @@ Changelog for NeoFS Node - Fix concurrent map writes in `Object.Put` service (#2037) - Malformed request errors' reasons in the responses (#2028) - Session token's IAT and NBF checks in ACL service (#2028) +- Losing meta information on request forwarding (#2040) ### Removed ### Updated diff --git a/pkg/services/object/util/prm.go b/pkg/services/object/util/prm.go index 80dd84b01b..952f128242 100644 --- a/pkg/services/object/util/prm.go +++ b/pkg/services/object/util/prm.go @@ -102,6 +102,12 @@ func CommonPrmFromV2(req interface { GetMetaHeader() *session.RequestMetaHeader }) (*CommonPrm, error) { meta := req.GetMetaHeader() + ttl := meta.GetTTL() + + // unwrap meta header to get original request meta information + for meta.GetOrigin() != nil { + meta = meta.GetOrigin() + } var tokenSession *sessionsdk.Object var err error @@ -116,7 +122,6 @@ func CommonPrmFromV2(req interface { } xHdrs := meta.GetXHeaders() - ttl := meta.GetTTL() prm := &CommonPrm{ local: ttl <= maxLocalTTL,