mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-12-05 18:47:20 +01:00
* volume: check the collection name in handlers that build file paths from it AllocateVolume, VolumeMount, VolumeCopy and the EC rebuild, copy, delete, mount and to-volume handlers joined the request collection into volume file paths, so a collection such as "../x" reached files outside the volume directory. They now apply checkVolumeCollection, as CopyFile and ReceiveFile already do. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * seaweed-volume: check the collection name in handlers that build file paths from it Mirrors the Go volume server: allocate_volume, volume_mount, volume_copy and the EC rebuild, copy, delete, mount and to-volume handlers apply check_volume_collection, as copy_file and receive_file already do. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * volume: check the source's collection before VolumeCopy builds paths from it VolumeCopy names the destination files after the collection the source reports in ReadVolumeFileStatus, so that value needs the same check as the request's collection. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * seaweed-volume: check the source's collection before volume_copy builds paths from it Mirrors the Go VolumeCopy: the collection the source reports in ReadVolumeFileStatus names the destination files, so it gets check_volume_collection too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * volume: stub the source in the VolumeCopy source collection test Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * seaweed-volume: keep check_volume_collection's doc comment as on master Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>