Skip to content

Commit

Permalink
Filter out Suricata rules when assembling zdeps on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
philrz committed Oct 16, 2023
1 parent 115b79c commit 8c9bbf0
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion apps/zui/scripts/download-zdeps/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,24 @@ async function zedDevBuild(destPath) {
}
}

// Suricata rules are dropped from the Windows build to fix a false positive
// malware flagging. See https://github.com/brimdata/zui/issues/2857.
const filterBrimcapZdeps = (src, dest) => {
if (process.platform == "win32" &&
(/suricata\.rules$/.test(src) || /emerging\.rules\.tar\.gz$/.test(src)) &&
fs.statSync(src).isFile()) {
return false
} else {
return true
}
}

async function main() {
try {
fs.copySync(
path.resolve("..", "..", "node_modules", "brimcap", "build", "dist"),
zdepsPath
zdepsPath,
{ filter: filterBrimcapZdeps }
)
const brimcapVersion = child_process
.execSync(path.join(zdepsPath, "brimcap") + " -version")
Expand Down

0 comments on commit 8c9bbf0

Please sign in to comment.