mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-11-03 02:32:35 +01:00
replication: use the side filer read key for manifest downloads and fall back per access level
Manifest chunk resolution still signed proxied downloads with the process-wide read key, so a source filer requiring its own key 401'd on manifest-bearing files. A side security file that set only one access level also produced empty tokens for the other instead of inheriting the process-wide key, and the side file loader ignored the WEED_ environment overrides the filer itself honors. ResolveChunkManifest/ResolveOneChunkManifest keep their signatures; FilerJwt-aware variants thread the provider down to fetchWholeChunk, which prefers it on proxy URLs. The side loader now applies the same environment precedence and falls back to the process-wide signer per missing access level.
This commit is contained in:
1 parent
78893d274a
commit
aa48658739
11 files changed
+181
-29
No files matched your search
@@ -72,6 +72,12 @@ func (fs *FilerSource) SetFilerJwtProvider(provider security.FilerJwtProvider) {
|
||||
fs.jwtForFiler = provider
|
||||
}
|
||||
|
||||
// FilerJwt returns the side-specific filer API credential, or nil when the
|
||||
// process-wide jwt.filer_signing configuration applies.
|
||||
func (fs *FilerSource) FilerJwt() security.FilerJwtProvider {
|
||||
return fs.jwtForFiler
|
||||
}
|
||||
|
||||
func (fs *FilerSource) LookupFileId(ctx context.Context, part string) (fileUrls []string, err error) {
|
||||
|
||||
vid2Locations := make(map[string]*filer_pb.Locations)
|
||||
|
||||
Reference in new issue
Block a user