mirror of
https://github.com/projectdiscovery/httpx.git
synced 2024-08-16 21:10:23 +03:00
fix existing response dir issue (#1451)
* fix existing response dir issue * misc update --------- Co-authored-by: sandeep <8293321+ehsandeep@users.noreply.github.com> Co-authored-by: Sandeep Singh <sandeep@projectdiscovery.io>
This commit is contained in:
parent
91139dbc91
commit
712f8545f6
2
go.sum
2
go.sum
@ -73,6 +73,8 @@ github.com/go-faker/faker/v4 v4.1.1 h1:zkxj/JH/aezB4R6cTEMKU7qcVScGhlB3qRtF3D7K+
|
||||
github.com/go-faker/faker/v4 v4.1.1/go.mod h1:uuNc0PSRxF8nMgjGrrrU4Nw5cF30Jc6Kd0/FUTTYbhg=
|
||||
github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ=
|
||||
github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
|
||||
github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY=
|
||||
github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0=
|
||||
github.com/go-rod/rod v0.114.0 h1:P+zLOqsj+vKf4C86SfjP6ymyPl9VXoYKm+ceCeQms6Y=
|
||||
github.com/go-rod/rod v0.114.0/go.mod h1:aiedSEFg5DwG/fnNbUOTPMTTWX3MRj6vIs/a684Mthw=
|
||||
github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI=
|
||||
|
@ -711,7 +711,11 @@ func (r *Runner) RunEnumeration() {
|
||||
}
|
||||
if r.options.StoreResponseDir != "" {
|
||||
var err error
|
||||
indexPath := filepath.Join(r.options.StoreResponseDir, "response", "index.txt")
|
||||
responseDirPath := filepath.Join(r.options.StoreResponseDir, "response")
|
||||
if err := os.MkdirAll(responseDirPath, 0755); err != nil {
|
||||
gologger.Fatal().Msgf("Could not create response directory '%s': %s\n", responseDirPath, err)
|
||||
}
|
||||
indexPath := filepath.Join(responseDirPath, "index.txt")
|
||||
if r.options.Resume {
|
||||
indexFile, err = os.OpenFile(indexPath, os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0600)
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user