Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions scripts/runOpenTaint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env bash

# Check for install/updates at https://github.com/seqra/opentaint

source scripts/requireCommand.sh

requireCommand docker

docker pull ghcr.io/seqra/opentaint

benchmark_version=$(scripts/getBenchmarkVersion.sh 2>/dev/null | tail -1)
opentaint_version=$(docker run --rm ghcr.io/seqra/opentaint opentaint --version | grep -oE 'v[0-9]+\.[0-9]+\.[0-9]+' || docker run --rm ghcr.io/seqra/opentaint opentaint --version | awk '{print $NF}')
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You've got a problem and want to solve it with RegEx? Now you got two problems 😅

Just drop it and use the awk code 🤷‍♂️

result_file="/project/results/Benchmark_$benchmark_version-OpenTaint-$opentaint_version.sarif"

docker run --rm -v $(pwd):/project \
ghcr.io/seqra/opentaint:latest \
opentaint scan \
--severity error \
--severity warning \
--severity note \
--output "$result_file" /project
Loading