Skip to content

Commit

Permalink
fixed bug:Configs.ConfigJsonMap.Exploit.Logs is "<nil>" #111 By @hkta…
Browse files Browse the repository at this point in the history
…lent 2022-09-17
  • Loading branch information
hktalent committed Sep 17, 2022
1 parent 569b0b9 commit b3452bc
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 2 additions & 0 deletions testbd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,5 @@ rm -rf vendor/github.com/projectdiscovery/nuclei/v2/pkg/protocols/common/interac
wget -c -O vendor/github.com/projectdiscovery/nuclei/v2/pkg/protocols/http/request.go https://github.com/hktalent/scan4all/raw/main/vendor/github.com/projectdiscovery/nuclei/v2/pkg/protocols/http/request.go
wget -c -O vendor/github.com/projectdiscovery/nuclei/v2/pkg/protocols/common/interactsh/interactsh.go https://github.com/hktalent/scan4all/raw/main/vendor/github.com/projectdiscovery/nuclei/v2/pkg/protocols/common/interactsh/interactsh.go
go build

find . -name ".DS_Store" -delete
3 changes: 3 additions & 0 deletions upNuclei.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,6 @@ ls ../nuclei-templates|xargs -I % cp -rf ../nuclei-templates/% config/nuclei-tem
git add config/nuclei-templates pocs_yml/ymlFiles vendor
git checkout vendor/github.com/projectdiscovery/nuclei/v2
git status
find . -name ".DS_Store" -delete
rm -rf logs/*
rm -rf .DbCache
4 changes: 2 additions & 2 deletions webScan/Functions/Loadlog.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import (
func init() {
util.RegInitFunc(func() {
fileValue := util.GetAsAny("Exploit")
Configs.ConfigJsonMap.Exploit.Logs = fmt.Sprintf("%v", util.GetJson4Query(fileValue, ".Logs"))
Configs.ConfigJsonMap.Exploit.Path = fmt.Sprintf("%v", util.GetJson4Query(fileValue, ".Path"))
Configs.ConfigJsonMap.Exploit.Logs = fmt.Sprintf("%v", util.GetJson4Query(fileValue, ".logs"))
Configs.ConfigJsonMap.Exploit.Path = fmt.Sprintf("%v", util.GetJson4Query(fileValue, ".path"))

FileLog, err := os.OpenFile(Configs.ConfigJsonMap.Exploit.Logs, os.O_CREATE|os.O_WRONLY|os.O_APPEND, 0666)
if err != nil {
Expand Down

0 comments on commit b3452bc

Please sign in to comment.