Skip to content

Commit

Permalink
Min change
Browse files Browse the repository at this point in the history
  • Loading branch information
Dean-Coakley committed Nov 16, 2023
1 parent 08b5507 commit 416cd22
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/extensions/nginx-app-protect/nap/nap.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const (
DefaultOptNAPDir = "/opt/app_protect"
DefaultNMSCompilerDir = "/opt/nms-nap-compiler"
compilerDirPrefix = "app_protect-"
dirPerm = 0o644
dirPerm = 0o750
)

var (
Expand Down
4 changes: 2 additions & 2 deletions src/extensions/nginx-app-protect/nap/nap_metadata.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,15 +94,15 @@ func UpdateMetadata(
directory := filepath.Dir(appProtectWAFDetails.GetWafLocation())
_, err = os.Stat(directory)
if os.IsNotExist(err) {
err = os.MkdirAll(directory, 0o755)
err = os.MkdirAll(directory, 0o750)
if err != nil {
return fmt.Errorf("failed to create directory for metadata update: %v", err)
}
}

log.Debugf("Writing NAP Metadata %s", m)

err = os.WriteFile(appProtectWAFDetails.GetWafLocation(), m, 0o664)
err = os.WriteFile(appProtectWAFDetails.GetWafLocation(), m, 0o644)
if err != nil {
return fmt.Errorf("failed to write NAP Metadata update: %v", err)
}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 416cd22

Please sign in to comment.