Docker workflow proved unsuitable — commit to be removed
This commit is contained in:
@@ -14,3 +14,11 @@ QLDB_MINIO_ENDPOINT=minio.store:9000
|
|||||||
QLDB_MINIO_ID=${MINIO_ROOT_USER}
|
QLDB_MINIO_ID=${MINIO_ROOT_USER}
|
||||||
QLDB_MINIO_SECRET=${MINIO_ROOT_PASSWORD}
|
QLDB_MINIO_SECRET=${MINIO_ROOT_PASSWORD}
|
||||||
MRVA_MINIO_VIRTUAL_HOST=0
|
MRVA_MINIO_VIRTUAL_HOST=0
|
||||||
|
#
|
||||||
|
# temporary:
|
||||||
|
#
|
||||||
|
MRVA_HEPC_DATAVIACLI=0
|
||||||
|
MRVA_HEPC_REFROOT=/refroot/
|
||||||
|
MRVA_HEPC_OUTDIR=WedMay7
|
||||||
|
MRVA_HEPC_TOOL=codeql-javascript
|
||||||
|
MRVA_HEPC_COMMAND=spigot-cli
|
||||||
|
|||||||
124
bin/ma.send-request
Executable file
124
bin/ma.send-request
Executable file
@@ -0,0 +1,124 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
#* Start container and check gh-mrva tool
|
||||||
|
# Start an interactive bash shell inside the running Docker container
|
||||||
|
docker exec -it mrva-ghmrva bash
|
||||||
|
|
||||||
|
# Check if the gh-mrva tool is installed and accessible
|
||||||
|
cd ~/work-gh/mrva/gh-mrva/
|
||||||
|
gh-mrva -h
|
||||||
|
|
||||||
|
|
||||||
|
#* Set up gh-mrva configuration
|
||||||
|
# Create configuration directory and generate config file for gh-mrva
|
||||||
|
mkdir -p ~/.config/gh-mrva
|
||||||
|
cat > ~/.config/gh-mrva/config.yml <<EOF
|
||||||
|
# Configuration file for the gh-mrva tool
|
||||||
|
# codeql_path: Path to the CodeQL distribution (not used in this setup)
|
||||||
|
# controller: Placeholder for a controller NWO (not relevant in this setup)
|
||||||
|
# list_file: Path to the repository selection JSON file
|
||||||
|
|
||||||
|
codeql_path: not-used/codeql-path
|
||||||
|
controller: not-used/mirva-controller
|
||||||
|
list_file: $HOME/work-gh/mrva/gh-mrva/gh-mrva-selection.json
|
||||||
|
EOF
|
||||||
|
|
||||||
|
#* Create repository selection list
|
||||||
|
# Create a directory and generate the JSON file specifying repositories
|
||||||
|
mkdir -p ~/work-gh/mrva/gh-mrva
|
||||||
|
cat > ~/work-gh/mrva/gh-mrva/gh-mrva-selection.json <<eof
|
||||||
|
{
|
||||||
|
"mirva-list": [
|
||||||
|
"Serial-Studio/Serial-Studio",
|
||||||
|
"UEFITool/UEFITool",
|
||||||
|
"aircrack-ng/aircrack-ng",
|
||||||
|
"bulk-builder/bulk-builder",
|
||||||
|
"tesseract/tesseract"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
eof
|
||||||
|
|
||||||
|
#* Create and submit the first query (FlatBuffersFunc.ql)
|
||||||
|
# Generate a sample CodeQL query for functions of interest
|
||||||
|
cat > ~/work-gh/mrva/gh-mrva/FlatBuffersFunc.ql <<eof
|
||||||
|
/**
|
||||||
|
* @name pickfun
|
||||||
|
* @description Pick function from FlatBuffers
|
||||||
|
* @kind problem
|
||||||
|
* @id cpp-flatbuffer-func
|
||||||
|
* @problem.severity warning
|
||||||
|
*/
|
||||||
|
|
||||||
|
import cpp
|
||||||
|
|
||||||
|
from Function f
|
||||||
|
where
|
||||||
|
f.getName() = "MakeBinaryRegion" or
|
||||||
|
f.getName() = "microprotocols_add"
|
||||||
|
select f, "definition of MakeBinaryRegion"
|
||||||
|
eof
|
||||||
|
|
||||||
|
# Submit the MRVA job with the first query
|
||||||
|
cd ~/work-gh/mrva/gh-mrva/
|
||||||
|
gh-mrva submit --language cpp --session mirva-session-2372 \
|
||||||
|
--list mirva-list \
|
||||||
|
--query ~/work-gh/mrva/gh-mrva/FlatBuffersFunc.ql
|
||||||
|
|
||||||
|
# Check the status of the submitted session
|
||||||
|
gh-mrva status --session mirva-session-2372
|
||||||
|
|
||||||
|
# Download SARIF files and databases if there are results. For the current
|
||||||
|
# query / database combination there are zero result hence no downloads
|
||||||
|
cd ~/work-gh/mrva/gh-mrva/
|
||||||
|
gh-mrva download --session mirva-session-2372 \
|
||||||
|
--download-dbs \
|
||||||
|
--output-dir mirva-session-2372
|
||||||
|
|
||||||
|
|
||||||
|
#** Set up QLPack for the next query
|
||||||
|
# Create a qlpack.yml file required for the next query
|
||||||
|
cat > ~/work-gh/mrva/gh-mrva/qlpack.yml <<eof
|
||||||
|
library: false
|
||||||
|
name: codeql-dataflow-ii-cpp
|
||||||
|
version: 0.0.1
|
||||||
|
dependencies:
|
||||||
|
codeql/cpp-all: 0.5.3
|
||||||
|
eof
|
||||||
|
|
||||||
|
#** Create and submit the second query (Fprintf.ql)
|
||||||
|
# Generate a CodeQL query to find calls to fprintf
|
||||||
|
cat > ~/work-gh/mrva/gh-mrva/Fprintf.ql <<eof
|
||||||
|
/**
|
||||||
|
* @name findPrintf
|
||||||
|
* @description Find calls to plain fprintf
|
||||||
|
* @kind problem
|
||||||
|
* @id cpp-fprintf-call
|
||||||
|
* @problem.severity warning
|
||||||
|
*/
|
||||||
|
|
||||||
|
import cpp
|
||||||
|
|
||||||
|
from FunctionCall fc
|
||||||
|
where
|
||||||
|
fc.getTarget().getName() = "fprintf"
|
||||||
|
select fc, "call of fprintf"
|
||||||
|
eof
|
||||||
|
|
||||||
|
# Submit a new MRVA job with the second query
|
||||||
|
cd ~/work-gh/mrva/gh-mrva/
|
||||||
|
gh-mrva submit \
|
||||||
|
--language cpp --session mirva-session-2261 \
|
||||||
|
--list mirva-list \
|
||||||
|
--query ~/work-gh/mrva/gh-mrva/Fprintf.ql
|
||||||
|
|
||||||
|
|
||||||
|
# Check the status of the second session
|
||||||
|
gh-mrva status --session mirva-session-2261
|
||||||
|
|
||||||
|
# Download SARIF files and databases for the second query
|
||||||
|
cd ~/work-gh/mrva/gh-mrva/
|
||||||
|
gh-mrva download --session mirva-session-2261 \
|
||||||
|
--download-dbs \
|
||||||
|
--output-dir mirva-session-2261
|
||||||
|
|
||||||
|
ls -l mirva-session-2261
|
||||||
|
|
||||||
@@ -57,7 +57,7 @@ services:
|
|||||||
network_mode: "service:server" # Share the 'server' network namespace
|
network_mode: "service:server" # Share the 'server' network namespace
|
||||||
environment:
|
environment:
|
||||||
- SERVER_URL=http://localhost:8080 # 'localhost' now refers to 'server'
|
- SERVER_URL=http://localhost:8080 # 'localhost' now refers to 'server'
|
||||||
|
|
||||||
code-server:
|
code-server:
|
||||||
# ./containers/vscode/Dockerfile
|
# ./containers/vscode/Dockerfile
|
||||||
container_name: mrva-code-server
|
container_name: mrva-code-server
|
||||||
|
|||||||
1
mitmproxy-config.yaml
Normal file
1
mitmproxy-config.yaml
Normal file
@@ -0,0 +1 @@
|
|||||||
|
web_password: mr
|
||||||
Reference in New Issue
Block a user