[#2040] node: Do not attach tokens in the assembly process
A container node is expected to have full "get" access to assemble the object. A non-container node is expected to forward any request to a container node. Any token is expected to be issued for an original request sender not for a node so any new request is invalid by design with that token. Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
fd61bdadcb
commit
d5a14041e0
3 changed files with 23 additions and 0 deletions
|
@ -98,6 +98,15 @@ func (p *CommonPrm) SetNetmapLookupDepth(v uint64) {
|
|||
}
|
||||
}
|
||||
|
||||
// ForgetTokens forgets all the tokens read from the request's
|
||||
// meta information before.
|
||||
func (p *CommonPrm) ForgetTokens() {
|
||||
if p != nil {
|
||||
p.token = nil
|
||||
p.bearer = nil
|
||||
}
|
||||
}
|
||||
|
||||
func CommonPrmFromV2(req interface {
|
||||
GetMetaHeader() *session.RequestMetaHeader
|
||||
}) (*CommonPrm, error) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue