Skip to content

Commit

Permalink
Bypass archive inspection is ignored (#847)
Browse files Browse the repository at this point in the history
  • Loading branch information
yahavi authored Oct 15, 2023
1 parent 7f15abb commit 1038c27
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 13 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@ jobs:
uses: golangci/golangci-lint-action@v3
with:
args: |
--timeout 5m --out-${NO_FUTURE}format colored-line-number --enable errcheck,gosimple,govet,ineffassign,staticcheck,typecheck,unused,gocritic,asasalint,asciicheck,errchkjson,exportloopref,forcetypeassert,makezero,nilerr,unparam,unconvert,wastedassign,usestdlibvars
--timeout 5m --out-${NO_FUTURE}format colored-line-number --enable errcheck,gosimple,govet,ineffassign,staticcheck,typecheck,unused,gocritic,asasalint,asciicheck,errchkjson,exportloopref,forcetypeassert,makezero,nilerr,unparam,unconvert,wastedassign,usestdlibvars
Go-Sec:
runs-on: ubuntu-latest
Expand All @@ -36,7 +35,8 @@ jobs:
with:
go-version: 1.20.x

# Temporarily set version 2.18.0 to workaround https://github.com/securego/gosec/issues/1046
- name: Run Gosec Security Scanner
uses: securego/gosec@master
uses: securego/gosec@v2.18.0
with:
args: -exclude G204,G301,G302,G304,G306 -tests -exclude-dir \.*test\.* ./...
21 changes: 11 additions & 10 deletions artifactory/services/download.go
Original file line number Diff line number Diff line change
Expand Up @@ -394,16 +394,17 @@ func (ds *DownloadService) downloadFile(downloadFileDetails *httpclient.Download
}

concurrentDownloadFlags := httpclient.ConcurrentDownloadFlags{
FileName: downloadFileDetails.FileName,
DownloadPath: downloadFileDetails.DownloadPath,
RelativePath: downloadFileDetails.RelativePath,
LocalFileName: downloadFileDetails.LocalFileName,
LocalPath: downloadFileDetails.LocalPath,
ExpectedSha1: downloadFileDetails.ExpectedSha1,
FileSize: downloadFileDetails.Size,
SplitCount: downloadParams.SplitCount,
Explode: downloadParams.IsExplode(),
SkipChecksum: downloadParams.SkipChecksum}
FileName: downloadFileDetails.FileName,
DownloadPath: downloadFileDetails.DownloadPath,
RelativePath: downloadFileDetails.RelativePath,
LocalFileName: downloadFileDetails.LocalFileName,
LocalPath: downloadFileDetails.LocalPath,
ExpectedSha1: downloadFileDetails.ExpectedSha1,
FileSize: downloadFileDetails.Size,
SplitCount: downloadParams.SplitCount,
Explode: downloadParams.Explode,
BypassArchiveInspection: downloadParams.BypassArchiveInspection,
SkipChecksum: downloadParams.SkipChecksum}

resp, err := ds.client.DownloadFileConcurrently(concurrentDownloadFlags, logMsgPrefix, &httpClientsDetails, ds.Progress)
if err != nil {
Expand Down

0 comments on commit 1038c27

Please sign in to comment.