microsoft / onefuzz

A self-hosted Fuzzing-As-A-Service platform
MIT License
2.82k stars 199 forks source link

`containers download_job` doesn't fix inconsistent path separators for the `--output` parameter #3590

Open kananb opened 9 months ago

kananb commented 9 months ago

Information

Provide detailed reproduction steps (if any)

(This issue may exist for other commands as well)

  1. Run onefuzz containers download_job <...> --output ./temp for any valid job_id that has at least one container

Expected result

All of the job containers are downloaded into ./temp

Actual result

INFO:onefuzz:downloading: setup\oft-setup-omitted_guid
panic: inconsistent path separators. Some are forward, some are back. This is not supported.

goroutine 1 [running]:
github.com/Azure/azure-storage-azcopy/v10/common.DeterminePathSeparator({0xc0000c2100, 0x37})
        /home/vsts/work/1/s/common/extensions.go:140 +0x97
github.com/Azure/azure-storage-azcopy/v10/cmd.cleanLocalPath({0xc0000c2100, 0x37})
        /home/vsts/work/1/s/cmd/zc_traverser_local.go:536 +0x3b
github.com/Azure/azure-storage-azcopy/v10/cmd.(*rawSyncCmdArgs).cook(_)
        /home/vsts/work/1/s/cmd/sync.go:180 +0x869
github.com/Azure/azure-storage-azcopy/v10/cmd.init.20.func2(0xc00055bb80, {0xc0000402d0, 0x2, 0x3})
        /home/vsts/work/1/s/cmd/sync.go:729 +0xa6
github.com/spf13/cobra.(*Command).execute(0xc00055bb80, {0xc000040270, 0x3, 0x3})
        /home/vsts/go/pkg/mod/github.com/spf13/cobra@v1.4.0/command.go:860 +0x5f8
github.com/spf13/cobra.(*Command).ExecuteC(0x13786e0)
        /home/vsts/go/pkg/mod/github.com/spf13/cobra@v1.4.0/command.go:974 +0x3bc
github.com/spf13/cobra.(*Command).Execute(...)
        /home/vsts/go/pkg/mod/github.com/spf13/cobra@v1.4.0/command.go:902
github.com/Azure/azure-storage-azcopy/v10/cmd.Execute({0xc0000ab960, 0xc00008a0e0}, {0xc0000cec90, 0xb2d241}, 0x74, {0x19fd6cc5, 0x61a5, 0x4246, {0x4a, 0xa4, ...}})
        /home/vsts/work/1/s/cmd/root.go:189 +0x107
main.main()
        /home/vsts/work/1/s/main.go:88 +0x49a
ERROR:cli:command failed: 2 ['.\\azcopy.EXE', 'sync', 'omitted_url', './temp\\setup\\oft-setup-omitted_guid', '--recursive=true']

AB#168438