Files
fuzzforge_ai/test_projects/vulnerable_app/baseline-test.sarif
tduhamel42 60ca088ecf CI/CD Integration with Ephemeral Deployment Model (#14)
* feat: Complete migration from Prefect to Temporal

BREAKING CHANGE: Replaces Prefect workflow orchestration with Temporal

## Major Changes
- Replace Prefect with Temporal for workflow orchestration
- Implement vertical worker architecture (rust, android)
- Replace Docker registry with MinIO for unified storage
- Refactor activities to be co-located with workflows
- Update all API endpoints for Temporal compatibility

## Infrastructure
- New: docker-compose.temporal.yaml (Temporal + MinIO + workers)
- New: workers/ directory with rust and android vertical workers
- New: backend/src/temporal/ (manager, discovery)
- New: backend/src/storage/ (S3-cached storage with MinIO)
- New: backend/toolbox/common/ (shared storage activities)
- Deleted: docker-compose.yaml (old Prefect setup)
- Deleted: backend/src/core/prefect_manager.py
- Deleted: backend/src/services/prefect_stats_monitor.py
- Deleted: Docker registry and insecure-registries requirement

## Workflows
- Migrated: security_assessment workflow to Temporal
- New: rust_test workflow (example/test workflow)
- Deleted: secret_detection_scan (Prefect-based, to be reimplemented)
- Activities now co-located with workflows for independent testing

## API Changes
- Updated: backend/src/api/workflows.py (Temporal submission)
- Updated: backend/src/api/runs.py (Temporal status/results)
- Updated: backend/src/main.py (727 lines, TemporalManager integration)
- Updated: All 16 MCP tools to use TemporalManager

## Testing
-  All services healthy (Temporal, PostgreSQL, MinIO, workers, backend)
-  All API endpoints functional
-  End-to-end workflow test passed (72 findings from vulnerable_app)
-  MinIO storage integration working (target upload/download, results)
-  Worker activity discovery working (6 activities registered)
-  Tarball extraction working
-  SARIF report generation working

## Documentation
- ARCHITECTURE.md: Complete Temporal architecture documentation
- QUICKSTART_TEMPORAL.md: Getting started guide
- MIGRATION_DECISION.md: Why we chose Temporal over Prefect
- IMPLEMENTATION_STATUS.md: Migration progress tracking
- workers/README.md: Worker development guide

## Dependencies
- Added: temporalio>=1.6.0
- Added: boto3>=1.34.0 (MinIO S3 client)
- Removed: prefect>=3.4.18

* feat: Add Python fuzzing vertical with Atheris integration

This commit implements a complete Python fuzzing workflow using Atheris:

## Python Worker (workers/python/)
- Dockerfile with Python 3.11, Atheris, and build tools
- Generic worker.py for dynamic workflow discovery
- requirements.txt with temporalio, boto3, atheris dependencies
- Added to docker-compose.temporal.yaml with dedicated cache volume

## AtherisFuzzer Module (backend/toolbox/modules/fuzzer/)
- Reusable module extending BaseModule
- Auto-discovers fuzz targets (fuzz_*.py, *_fuzz.py, fuzz_target.py)
- Recursive search to find targets in nested directories
- Dynamically loads TestOneInput() function
- Configurable max_iterations and timeout
- Real-time stats callback support for live monitoring
- Returns findings as ModuleFinding objects

## Atheris Fuzzing Workflow (backend/toolbox/workflows/atheris_fuzzing/)
- Temporal workflow for orchestrating fuzzing
- Downloads user code from MinIO
- Executes AtherisFuzzer module
- Uploads results to MinIO
- Cleans up cache after execution
- metadata.yaml with vertical: python for routing

## Test Project (test_projects/python_fuzz_waterfall/)
- Demonstrates stateful waterfall vulnerability
- main.py with check_secret() that leaks progress
- fuzz_target.py with Atheris TestOneInput() harness
- Complete README with usage instructions

## Backend Fixes
- Fixed parameter merging in REST API endpoints (workflows.py)
- Changed workflow parameter passing from positional args to kwargs (manager.py)
- Default parameters now properly merged with user parameters

## Testing
 Worker discovered AtherisFuzzingWorkflow
 Workflow executed end-to-end successfully
 Fuzz target auto-discovered in nested directories
 Atheris ran 100,000 iterations
 Results uploaded and cache cleaned

* chore: Complete Temporal migration with updated CLI/SDK/docs

This commit includes all remaining Temporal migration changes:

## CLI Updates (cli/)
- Updated workflow execution commands for Temporal
- Enhanced error handling and exceptions
- Updated dependencies in uv.lock

## SDK Updates (sdk/)
- Client methods updated for Temporal workflows
- Updated models for new workflow execution
- Updated dependencies in uv.lock

## Documentation Updates (docs/)
- Architecture documentation for Temporal
- Workflow concept documentation
- Resource management documentation (new)
- Debugging guide (new)
- Updated tutorials and how-to guides
- Troubleshooting updates

## README Updates
- Main README with Temporal instructions
- Backend README
- CLI README
- SDK README

## Other
- Updated IMPLEMENTATION_STATUS.md
- Removed old vulnerable_app.tar.gz

These changes complete the Temporal migration and ensure the
CLI/SDK work correctly with the new backend.

* fix: Use positional args instead of kwargs for Temporal workflows

The Temporal Python SDK's start_workflow() method doesn't accept
a 'kwargs' parameter. Workflows must receive parameters as positional
arguments via the 'args' parameter.

Changed from:
  args=workflow_args  # Positional arguments

This fixes the error:
  TypeError: Client.start_workflow() got an unexpected keyword argument 'kwargs'

Workflows now correctly receive parameters in order:
- security_assessment: [target_id, scanner_config, analyzer_config, reporter_config]
- atheris_fuzzing: [target_id, target_file, max_iterations, timeout_seconds]
- rust_test: [target_id, test_message]

* fix: Filter metadata-only parameters from workflow arguments

SecurityAssessmentWorkflow was receiving 7 arguments instead of 2-5.
The issue was that target_path and volume_mode from default_parameters
were being passed to the workflow, when they should only be used by
the system for configuration.

Now filters out metadata-only parameters (target_path, volume_mode)
before passing arguments to workflow execution.

* refactor: Remove Prefect leftovers and volume mounting legacy

Complete cleanup of Prefect migration artifacts:

Backend:
- Delete registry.py and workflow_discovery.py (Prefect-specific files)
- Remove Docker validation from setup.py (no longer needed)
- Remove ResourceLimits and VolumeMount models
- Remove target_path and volume_mode from WorkflowSubmission
- Remove supported_volume_modes from API and discovery
- Clean up metadata.yaml files (remove volume/path fields)
- Simplify parameter filtering in manager.py

SDK:
- Remove volume_mode parameter from client methods
- Remove ResourceLimits and VolumeMount models
- Remove Prefect error patterns from docker_logs.py
- Clean up WorkflowSubmission and WorkflowMetadata models

CLI:
- Remove Volume Modes display from workflow info

All removed features are Prefect-specific or Docker volume mounting
artifacts. Temporal workflows use MinIO storage exclusively.

* feat: Add comprehensive test suite and benchmark infrastructure

- Add 68 unit tests for fuzzer, scanner, and analyzer modules
- Implement pytest-based test infrastructure with fixtures
- Add 6 performance benchmarks with category-specific thresholds
- Configure GitHub Actions for automated testing and benchmarking
- Add test and benchmark documentation

Test coverage:
- AtherisFuzzer: 8 tests
- CargoFuzzer: 14 tests
- FileScanner: 22 tests
- SecurityAnalyzer: 24 tests

All tests passing (68/68)
All benchmarks passing (6/6)

* fix: Resolve all ruff linting violations across codebase

Fixed 27 ruff violations in 12 files:
- Removed unused imports (Depends, Dict, Any, Optional, etc.)
- Fixed undefined workflow_info variable in workflows.py
- Removed dead code with undefined variables in atheris_fuzzer.py
- Changed f-string to regular string where no placeholders used

All files now pass ruff checks for CI/CD compliance.

* fix: Configure CI for unit tests only

- Renamed docker-compose.temporal.yaml → docker-compose.yml for CI compatibility
- Commented out integration-tests job (no integration tests yet)
- Updated test-summary to only depend on lint and unit-tests

CI will now run successfully with 68 unit tests. Integration tests can be added later.

* feat: Add CI/CD integration with ephemeral deployment model

Implements comprehensive CI/CD support for FuzzForge with on-demand worker management:

**Worker Management (v0.7.0)**
- Add WorkerManager for automatic worker lifecycle control
- Auto-start workers from stopped state when workflows execute
- Auto-stop workers after workflow completion
- Health checks and startup timeout handling (90s default)

**CI/CD Features**
- `--fail-on` flag: Fail builds based on SARIF severity levels (error/warning/note/info)
- `--export-sarif` flag: Export findings in SARIF 2.1.0 format
- `--auto-start`/`--auto-stop` flags: Control worker lifecycle
- Exit code propagation: Returns 1 on blocking findings, 0 on success

**Exit Code Fix**
- Add `except typer.Exit: raise` handlers at 3 critical locations
- Move worker cleanup to finally block for guaranteed execution
- Exit codes now propagate correctly even when build fails

**CI Scripts & Examples**
- ci-start.sh: Start FuzzForge services with health checks
- ci-stop.sh: Clean shutdown with volume preservation option
- GitHub Actions workflow example (security-scan.yml)
- GitLab CI pipeline example (.gitlab-ci.example.yml)
- docker-compose.ci.yml: CI-optimized compose file with profiles

**OSS-Fuzz Integration**
- New ossfuzz_campaign workflow for running OSS-Fuzz projects
- OSS-Fuzz worker with Docker-in-Docker support
- Configurable campaign duration and project selection

**Documentation**
- Comprehensive CI/CD integration guide (docs/how-to/cicd-integration.md)
- Updated architecture docs with worker lifecycle details
- Updated workspace isolation documentation
- CLI README with worker management examples

**SDK Enhancements**
- Add get_workflow_worker_info() endpoint
- Worker vertical metadata in workflow responses

**Testing**
- All workflows tested: security_assessment, atheris_fuzzing, secret_detection, cargo_fuzzing
- All monitoring commands tested: stats, crashes, status, finding
- Full CI pipeline simulation verified
- Exit codes verified for success/failure scenarios

Ephemeral CI/CD model: ~3-4GB RAM, ~60-90s startup, runs entirely in CI containers.

* fix: Resolve ruff linting violations in CI/CD code

- Remove unused variables (run_id, defaults, result)
- Remove unused imports
- Fix f-string without placeholders

All CI/CD integration files now pass ruff checks.
2025-10-14 10:13:45 +02:00

2548 lines
78 KiB
JSON

{
"$schema": "https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"runs": [
{
"invocations": [
{
"endTimeUtc": "2025-10-13T13:56:22.175424Z",
"executionSuccessful": true
}
],
"originalUriBaseIds": {
"WORKSPACE": {
"description": "The workspace root directory",
"uri": "file:///cache/800afd77-0c92-44ba-ac10-b76a5c36090c/workspace/"
}
},
"results": [
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": ".env",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at .env"
},
"properties": {
"findingId": "0bf9e5f4-b9dd-45ff-bfe2-1e7e1de6e875",
"metadata": {
"file_size": 1546,
"file_type": "application/octet-stream"
},
"title": "Potentially sensitive file: .env"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": ".git-credentials",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at .git-credentials"
},
"properties": {
"findingId": "bb454561-76c1-4e15-b5ca-7c1e4cd7ca15",
"metadata": {
"file_size": 168,
"file_type": "application/octet-stream"
},
"title": "Potentially sensitive file: .git-credentials"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "private_key.pem",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at private_key.pem"
},
"properties": {
"findingId": "03653809-53b1-4538-ad4e-a4ca0a772edf",
"metadata": {
"file_size": 381,
"file_type": "application/pem-certificate-chain"
},
"title": "Potentially sensitive file: private_key.pem"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "wallet.json",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at wallet.json"
},
"properties": {
"findingId": "6eff764b-88a8-4d59-9785-dcad4cd7df60",
"metadata": {
"file_size": 1206,
"file_type": "application/json"
},
"title": "Potentially sensitive file: wallet.json"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": ".npmrc",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at .npmrc"
},
"properties": {
"findingId": "30228e73-1f2b-493c-9cc2-ae2c85ffe9ac",
"metadata": {
"file_size": 238,
"file_type": "application/octet-stream"
},
"title": "Potentially sensitive file: .npmrc"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": ".fuzzforge/.env",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at .fuzzforge/.env"
},
"properties": {
"findingId": "4aca32ef-a59c-4ccd-bcfc-d674ed1e97af",
"metadata": {
"file_size": 897,
"file_type": "application/octet-stream"
},
"title": "Potentially sensitive file: .env"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": ".fuzzforge/.env.template",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at .fuzzforge/.env.template"
},
"properties": {
"findingId": "46e5a5f6-86c4-45c3-9a9b-7f7e96578dfa",
"metadata": {
"file_size": 569,
"file_type": "application/octet-stream"
},
"title": "Potentially sensitive file: .env.template"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "data/credentials.json",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at data/credentials.json"
},
"properties": {
"findingId": "5eb292a4-625a-44b9-be09-1a3bce6a413b",
"metadata": {
"file_size": 1057,
"file_type": "application/json"
},
"title": "Potentially sensitive file: credentials.json"
},
"ruleId": "sensitive_file_medium"
},
{
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "data/api_keys.txt",
"uriBaseId": "WORKSPACE"
}
}
}
],
"message": {
"text": "Found potentially sensitive file at data/api_keys.txt"
},
"properties": {
"findingId": "90c57980-728d-4aa3-93cd-d6fa161fb119",
"metadata": {
"file_size": 1138,
"file_type": "text/plain"
},
"title": "Potentially sensitive file: api_keys.txt"
},
"ruleId": "sensitive_file_medium"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "app.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "query = f\"SELECT * FROM users WHERE id = {user_id}\""
},
"startLine": 32
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via F-string in SQL query"
},
"properties": {
"findingId": "964eedf8-3a34-4bcf-aaa8-297ee33f490e",
"metadata": {
"vulnerability_type": "F-string in SQL query"
},
"title": "Potential SQL Injection: F-string in SQL query"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded API Key and use environment variables or secure vault"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "STRIPE_API_KEY = \"sk_live_4eC39HqLyjWDarjtT1zdp7dc\""
},
"startLine": 25
}
}
}
],
"message": {
"text": "Found potential hardcoded API Key in src/api_handler.py"
},
"properties": {
"findingId": "1ad3b265-0805-4074-af5c-8f9de17987c2",
"metadata": {
"secret_type": "API Key"
},
"title": "Hardcoded API Key detected"
},
"ruleId": "hardcoded_secret_high"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Authentication Token and use environment variables or secure vault"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "SECRET_TOKEN = \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9"
},
"startLine": 21
}
}
}
],
"message": {
"text": "Found potential hardcoded Authentication Token in src/api_handler.py"
},
"properties": {
"findingId": "2618afcd-e4da-49d7-bfd3-c6a8b399656f",
"metadata": {
"secret_type": "Authentication Token"
},
"title": "Hardcoded Authentication Token detected"
},
"ruleId": "hardcoded_secret_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to eval()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "result = eval(user_data) # Code injection vulnerability"
},
"startLine": 34
}
}
}
],
"message": {
"text": "Use of potentially dangerous function eval(): Arbitrary code execution"
},
"properties": {
"findingId": "5bb9c1aa-830e-48b1-ac3d-beabe84c3605",
"metadata": {
"function": "eval()",
"risk": "Arbitrary code execution"
},
"title": "Dangerous function: eval()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to eval()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "func = eval(f\"lambda x: {code}\") # Dangerous eval"
},
"startLine": 54
}
}
}
],
"message": {
"text": "Use of potentially dangerous function eval(): Arbitrary code execution"
},
"properties": {
"findingId": "b06b814d-88a0-45b7-81aa-cc4398a22b66",
"metadata": {
"function": "eval()",
"risk": "Arbitrary code execution"
},
"title": "Dangerous function: eval()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to exec()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "exec(compiled, data) # Code execution vulnerability"
},
"startLine": 49
}
}
}
],
"message": {
"text": "Use of potentially dangerous function exec(): Arbitrary code execution"
},
"properties": {
"findingId": "12646361-1f36-4e35-b14f-eb44abaf3f29",
"metadata": {
"function": "exec()",
"risk": "Arbitrary code execution"
},
"title": "Dangerous function: exec()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to os.system()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "os.system(\"cat \" + filename) # Command injection"
},
"startLine": 44
}
}
}
],
"message": {
"text": "Use of potentially dangerous function os.system(): Command injection risk"
},
"properties": {
"findingId": "da239acf-1c81-49f2-9232-d20c7af09348",
"metadata": {
"function": "os.system()",
"risk": "Command injection risk"
},
"title": "Dangerous function: os.system()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to os.system()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "os.system(f\"echo '{log_message}' >> /var/log/app.log\") # Command injection via logs"
},
"startLine": 71
}
}
}
],
"message": {
"text": "Use of potentially dangerous function os.system(): Command injection risk"
},
"properties": {
"findingId": "c0105aff-8273-42aa-906c-c2c79003822d",
"metadata": {
"function": "os.system()",
"risk": "Command injection risk"
},
"title": "Dangerous function: os.system()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to subprocess with shell=True"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/api_handler.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "result = subprocess.call(command, shell=True) # Command injection risk"
},
"startLine": 39
}
}
}
],
"message": {
"text": "Use of potentially dangerous function subprocess with shell=True: Command injection risk"
},
"properties": {
"findingId": "4e339aab-1325-4cb2-8293-5ed2a8a04c02",
"metadata": {
"function": "subprocess with shell=True",
"risk": "Command injection risk"
},
"title": "Dangerous function: subprocess with shell=True"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "query = \"SELECT * FROM users WHERE username = '\" + user_input + \"'\""
},
"startLine": 43
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via String concatenation in SQL"
},
"properties": {
"findingId": "9fd4b1d7-7a65-4f03-8867-2d55b5514d7d",
"metadata": {
"vulnerability_type": "String concatenation in SQL"
},
"title": "Potential SQL Injection: String concatenation in SQL"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "query = f\"SELECT * FROM products WHERE name LIKE '%{search_term}%' AND category = '{category}'\""
},
"startLine": 50
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via String formatting in SQL"
},
"properties": {
"findingId": "025d8f27-5e65-48e6-89d0-f181dcf30ffb",
"metadata": {
"vulnerability_type": "String formatting in SQL"
},
"title": "Potential SQL Injection: String formatting in SQL"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "query = \"UPDATE users SET profile = '%s' WHERE id = %s\" % (data, user_id)"
},
"startLine": 57
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via String formatting in SQL"
},
"properties": {
"findingId": "0d832606-5578-41b5-a247-981a2bda8c21",
"metadata": {
"vulnerability_type": "String formatting in SQL"
},
"title": "Potential SQL Injection: String formatting in SQL"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "query = f\"SELECT * FROM products WHERE name LIKE '%{search_term}%' AND category = '{category}'\""
},
"startLine": 50
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via F-string in SQL query"
},
"properties": {
"findingId": "426e398a-13c9-48fe-9f1f-f26f65249b46",
"metadata": {
"vulnerability_type": "F-string in SQL query"
},
"title": "Potential SQL Injection: F-string in SQL query"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "query = \"SELECT * FROM users WHERE username = '\" + user_input + \"'\""
},
"startLine": 43
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via Dynamic query building"
},
"properties": {
"findingId": "16408845-486a-4b9b-8766-b36a815a4d21",
"metadata": {
"vulnerability_type": "Dynamic query building"
},
"title": "Potential SQL Injection: Dynamic query building"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "final_query = base_query + where_clause"
},
"startLine": 75
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via Dynamic query building"
},
"properties": {
"findingId": "a491d896-0ec1-4644-8af9-c5fc98ddad35",
"metadata": {
"vulnerability_type": "Dynamic query building"
},
"title": "Potential SQL Injection: Dynamic query building"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to os.system()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "os.system(f\"mysqldump -u {DB_USER} -p{DB_PASSWORD} production > {backup_name}\")"
},
"startLine": 69
}
}
}
],
"message": {
"text": "Use of potentially dangerous function os.system(): Command injection risk"
},
"properties": {
"findingId": "6f1e42b9-2e1f-432d-b5f8-efe8dc9d0c93",
"metadata": {
"function": "os.system()",
"risk": "Command injection risk"
},
"title": "Dangerous function: os.system()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to pickle.load()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/database.py",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "user_prefs = pickle.loads(data) # Dangerous pickle deserialization"
},
"startLine": 64
}
}
}
],
"message": {
"text": "Use of potentially dangerous function pickle.load(): Deserialization vulnerability"
},
"properties": {
"findingId": "570808dd-5c48-4209-afd1-7aeee71526dd",
"metadata": {
"function": "pickle.load()",
"risk": "Deserialization vulnerability"
},
"title": "Dangerous function: pickle.load()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Private Key and use environment variables or secure vault"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "const BITCOIN_PRIVATE_KEY = \"5KJvsngHeMpm884wtkJNzQGaCErckhHJBGFsvd3VyK5qMZXj3hS\";"
},
"startLine": 81
}
}
}
],
"message": {
"text": "Found potential hardcoded Private Key in scripts/backup.js"
},
"properties": {
"findingId": "316a81e3-4d3a-4644-83dc-922dea76a3ba",
"metadata": {
"secret_type": "Private Key"
},
"title": "Hardcoded Private Key detected"
},
"ruleId": "hardcoded_secret_high"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Potential Secret Hash and use environment variables or secure vault"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "const BITCOIN_PRIVATE_KEY = \"5KJvsngHeMpm884wtkJNzQGaCErckhHJBGFsvd3VyK5qMZXj3hS\";"
},
"startLine": 81
}
}
}
],
"message": {
"text": "Found potential hardcoded Potential Secret Hash in scripts/backup.js"
},
"properties": {
"findingId": "69965f9c-07c9-4469-8ba9-97fd5bdfc658",
"metadata": {
"secret_type": "Potential Secret Hash"
},
"title": "Hardcoded Potential Secret Hash detected"
},
"ruleId": "hardcoded_secret_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to eval()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "eval(userInput); // Code injection vulnerability"
},
"startLine": 23
}
}
}
],
"message": {
"text": "Use of potentially dangerous function eval(): Arbitrary code execution"
},
"properties": {
"findingId": "097851fb-abae-42eb-b6c9-c8132518883d",
"metadata": {
"function": "eval()",
"risk": "Arbitrary code execution"
},
"title": "Dangerous function: eval()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to new Function()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "return new Function(code); // Code injection vulnerability"
},
"startLine": 28
}
}
}
],
"message": {
"text": "Use of potentially dangerous function new Function(): Arbitrary code execution"
},
"properties": {
"findingId": "98629361-7024-4274-a677-d5d348812d8d",
"metadata": {
"function": "new Function()",
"risk": "Arbitrary code execution"
},
"title": "Dangerous function: new Function()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to innerHTML"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "document.body.innerHTML = message; // XSS vulnerability"
},
"startLine": 33
}
}
}
],
"message": {
"text": "Use of potentially dangerous function innerHTML: XSS vulnerability"
},
"properties": {
"findingId": "558e9f51-d9d2-4c2e-9953-a9cee6835e6e",
"metadata": {
"function": "innerHTML",
"risk": "XSS vulnerability"
},
"title": "Dangerous function: innerHTML"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to innerHTML"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "document.getElementById('content').innerHTML = html; // XSS vulnerability"
},
"startLine": 37
}
}
}
],
"message": {
"text": "Use of potentially dangerous function innerHTML: XSS vulnerability"
},
"properties": {
"findingId": "01c0e6f2-37cb-4a22-b2f5-a666278ae8af",
"metadata": {
"function": "innerHTML",
"risk": "XSS vulnerability"
},
"title": "Dangerous function: innerHTML"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to document.write()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/backup.js",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "document.write(data); // XSS vulnerability"
},
"startLine": 42
}
}
}
],
"message": {
"text": "Use of potentially dangerous function document.write(): XSS vulnerability"
},
"properties": {
"findingId": "c2363aa8-0571-4e73-b59f-4c449e6a6942",
"metadata": {
"function": "document.write()",
"risk": "XSS vulnerability"
},
"title": "Dangerous function: document.write()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Private Key and use environment variables or secure vault"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/Main.java",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "private static final String PRIVATE_KEY = \"-----BEGIN RSA PRIVATE KEY-----\\nMIIEpAIBAAKCAQ...\";"
},
"startLine": 77
}
}
}
],
"message": {
"text": "Found potential hardcoded Private Key in src/Main.java"
},
"properties": {
"findingId": "8b380c03-e59d-42a8-8eac-faac04557d88",
"metadata": {
"secret_type": "Private Key"
},
"title": "Hardcoded Private Key detected"
},
"ruleId": "hardcoded_secret_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/Main.java",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "String query = \"SELECT * FROM users WHERE id = \" + userId; // SQL injection"
},
"startLine": 23
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via String concatenation in SQL"
},
"properties": {
"findingId": "2f5d9ee7-05a8-4e8a-bd6f-8bf3175e95ce",
"metadata": {
"vulnerability_type": "String concatenation in SQL"
},
"title": "Potential SQL Injection: String concatenation in SQL"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/Main.java",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "String query = \"SELECT * FROM products WHERE name LIKE '%\" + searchTerm + \"%'\";"
},
"startLine": 29
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via String concatenation in SQL"
},
"properties": {
"findingId": "ac5d89e3-17f6-45f2-b254-01a8a2d45ba9",
"metadata": {
"vulnerability_type": "String concatenation in SQL"
},
"title": "Potential SQL Injection: String concatenation in SQL"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/Main.java",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "String query = \"SELECT * FROM users WHERE id = \" + userId; // SQL injection"
},
"startLine": 23
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via Dynamic query building"
},
"properties": {
"findingId": "ba76d0d9-d13a-43ef-bcf8-4e2a3677a8c5",
"metadata": {
"vulnerability_type": "Dynamic query building"
},
"title": "Potential SQL Injection: Dynamic query building"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Use parameterized queries or prepared statements instead"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/Main.java",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "String query = \"SELECT * FROM products WHERE name LIKE '%\" + searchTerm + \"%'\";"
},
"startLine": 29
}
}
}
],
"message": {
"text": "Detected potential SQL injection vulnerability via Dynamic query building"
},
"properties": {
"findingId": "f07f4cd1-194f-4051-9cc3-68c56410d44b",
"metadata": {
"vulnerability_type": "Dynamic query building"
},
"title": "Potential SQL Injection: Dynamic query building"
},
"ruleId": "sql_injection_high"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to eval()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "eval($code); // Code execution vulnerability"
},
"startLine": 28
}
}
}
],
"message": {
"text": "Use of potentially dangerous function eval(): Arbitrary code execution"
},
"properties": {
"findingId": "ad255a22-7163-4725-86dd-74e0210c7241",
"metadata": {
"function": "eval()",
"risk": "Arbitrary code execution"
},
"title": "Dangerous function: eval()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to exec()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "exec(\"cat \" . $_POST['file']);"
},
"startLine": 22
}
}
}
],
"message": {
"text": "Use of potentially dangerous function exec(): Command execution"
},
"properties": {
"findingId": "ac507bd3-d872-4bfc-8dcb-f420fb925f45",
"metadata": {
"function": "exec()",
"risk": "Command execution"
},
"title": "Dangerous function: exec()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to exec()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "shell_exec(\"ping \" . $_GET['host']);"
},
"startLine": 23
}
}
}
],
"message": {
"text": "Use of potentially dangerous function exec(): Command execution"
},
"properties": {
"findingId": "c7a788d4-911d-446f-b0da-384d80cc09f8",
"metadata": {
"function": "exec()",
"risk": "Command execution"
},
"title": "Dangerous function: exec()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to system()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "system(\"ls -la \" . $_GET['directory']);"
},
"startLine": 21
}
}
}
],
"message": {
"text": "Use of potentially dangerous function system(): Command execution"
},
"properties": {
"findingId": "c783b431-10d5-42e6-8864-9e2534942ad1",
"metadata": {
"function": "system()",
"risk": "Command execution"
},
"title": "Dangerous function: system()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to shell_exec()"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "shell_exec(\"ping \" . $_GET['host']);"
},
"startLine": 23
}
}
}
],
"message": {
"text": "Use of potentially dangerous function shell_exec(): Command execution"
},
"properties": {
"findingId": "bd70c615-556e-4e8f-8f5a-ba8317daac0c",
"metadata": {
"function": "shell_exec()",
"risk": "Command execution"
},
"title": "Dangerous function: shell_exec()"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$user_id = $_GET['id'];"
},
"startLine": 12
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "f2613945-a3af-4aef-ac3c-c3bf9a1e6b6b",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "system(\"ls -la \" . $_GET['directory']);"
},
"startLine": 21
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "51ac47fc-933d-4564-94ba-19f5e0163226",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "shell_exec(\"ping \" . $_GET['host']);"
},
"startLine": 23
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "fa75ecf2-04ca-483c-88e9-737db4296f95",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "passthru(\"ps aux | grep \" . $_GET['process']);"
},
"startLine": 24
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "76a1dfd3-2a0c-4b6f-b377-bf38bad29295",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "include($_GET['page'] . '.php');"
},
"startLine": 31
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "87f0e990-e1eb-49f8-a54b-e9e1b7fb1fb7",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "echo \"Welcome, \" . $_GET['name'];"
},
"startLine": 45
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "6ca5a574-9a27-4732-a0b7-fca0f9d9202d",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$_SESSION['user'] = $_GET['user'];"
},
"startLine": 50
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "89b0d644-5694-422e-8e89-de7558e9e8d0",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_GET usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$file = $_GET['file'];"
},
"startLine": 57
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_GET usage: Input validation missing"
},
"properties": {
"findingId": "5c1feb32-4872-47ef-b7e6-544be9ad0b46",
"metadata": {
"function": "Direct $_GET usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_GET usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$username = $_POST['username'];"
},
"startLine": 13
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "d45aaa98-4a69-4c77-98e8-cb1f2d839b38",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "exec(\"cat \" . $_POST['file']);"
},
"startLine": 22
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "bdfa9adc-fa0a-49b0-85fd-bc19cab18779",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$code = $_POST['code'];"
},
"startLine": 27
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "1d66b8d0-2cee-47af-a3b4-0d1b20945da2",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "require_once($_POST['template']);"
},
"startLine": 32
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "4440648e-e2fd-4aba-a084-39bf0ab495bd",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$search = $_POST['search'];"
},
"startLine": 40
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "1807a81a-ccb4-42ad-948c-48e62a575703",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "print(\"Your search: \" . $_POST['query']);"
},
"startLine": 46
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "da13eaf1-0e6a-4f02-8e53-5d430468f5a7",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$password = md5($_POST['password']); // Weak hashing"
},
"startLine": 53
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "c61a1aff-7574-448c-b857-7819e44aac29",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$encrypted = base64_encode($_POST['sensitive_data']); // Not encryption"
},
"startLine": 54
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "e5c36f20-f3e2-483b-9643-b6cc8288a601",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$username = $_POST['username'];"
},
"startLine": 61
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "09d5d5e7-2514-4824-949f-fc1738aa51e6",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Consider safer alternatives to Direct $_POST usage"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "scripts/deploy.php",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "$password = $_POST['password'];"
},
"startLine": 62
}
}
}
],
"message": {
"text": "Use of potentially dangerous function Direct $_POST usage: Input validation missing"
},
"properties": {
"findingId": "3d8d9924-01d4-467b-a4e6-fe95151fe31e",
"metadata": {
"function": "Direct $_POST usage",
"risk": "Input validation missing"
},
"title": "Dangerous function: Direct $_POST usage"
},
"ruleId": "dangerous_function_medium"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded API Key and use environment variables or secure vault"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/utils.rb",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "ELASTICSEARCH_API_KEY = \"elastic_api_key_789xyz\""
},
"startLine": 64
}
}
}
],
"message": {
"text": "Found potential hardcoded API Key in src/utils.rb"
},
"properties": {
"findingId": "4c565b36-27b3-464f-b99b-d8e2d85f50e0",
"metadata": {
"secret_type": "API Key"
},
"title": "Hardcoded API Key detected"
},
"ruleId": "hardcoded_secret_high"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Hardcoded Password and use environment variables or secure vault"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/utils.rb",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "REDIS_PASSWORD = \"redis_cache_password_456\""
},
"startLine": 63
}
}
}
],
"message": {
"text": "Found potential hardcoded Hardcoded Password in src/utils.rb"
},
"properties": {
"findingId": "f8e2edc4-38c2-4d67-b829-c084a16d5a48",
"metadata": {
"secret_type": "Hardcoded Password"
},
"title": "Hardcoded Hardcoded Password detected"
},
"ruleId": "hardcoded_secret_medium"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Private Key and use environment variables or secure vault"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/app.go",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "const BitcoinPrivateKey = \"5KJvsngHeMpm884wtkJNzQGaCErckhHJBGFsvd3VyK5qMZXj3hS\""
},
"startLine": 59
}
}
}
],
"message": {
"text": "Found potential hardcoded Private Key in src/app.go"
},
"properties": {
"findingId": "6a154086-37d9-4b8d-961f-f4c6b45023d9",
"metadata": {
"secret_type": "Private Key"
},
"title": "Hardcoded Private Key detected"
},
"ruleId": "hardcoded_secret_high"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Private Key and use environment variables or secure vault"
}
}
],
"level": "error",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/app.go",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "const EthereumPrivateKey = \"0x4c0883a69102937d6231471b5dbb6204fe512961708279f3e2e1a2e4567890abc\""
},
"startLine": 62
}
}
}
],
"message": {
"text": "Found potential hardcoded Private Key in src/app.go"
},
"properties": {
"findingId": "d1c46dc8-4c69-4a69-9264-2034c1f5a62b",
"metadata": {
"secret_type": "Private Key"
},
"title": "Hardcoded Private Key detected"
},
"ruleId": "hardcoded_secret_high"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Potential Secret Hash and use environment variables or secure vault"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/app.go",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "const BitcoinPrivateKey = \"5KJvsngHeMpm884wtkJNzQGaCErckhHJBGFsvd3VyK5qMZXj3hS\""
},
"startLine": 59
}
}
}
],
"message": {
"text": "Found potential hardcoded Potential Secret Hash in src/app.go"
},
"properties": {
"findingId": "889e1bb3-6a0b-455e-b242-46ff90a345ae",
"metadata": {
"secret_type": "Potential Secret Hash"
},
"title": "Hardcoded Potential Secret Hash detected"
},
"ruleId": "hardcoded_secret_medium"
},
{
"fixes": [
{
"description": {
"text": "Remove hardcoded Potential Secret Hash and use environment variables or secure vault"
}
}
],
"level": "warning",
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/app.go",
"uriBaseId": "WORKSPACE"
},
"region": {
"snippet": {
"text": "const EthereumPrivateKey = \"0x4c0883a69102937d6231471b5dbb6204fe512961708279f3e2e1a2e4567890abc\""
},
"startLine": 62
}
}
}
],
"message": {
"text": "Found potential hardcoded Potential Secret Hash in src/app.go"
},
"properties": {
"findingId": "60424cc3-95ea-47cf-a014-25b0f4b3c089",
"metadata": {
"secret_type": "Potential Secret Hash"
},
"title": "Hardcoded Potential Secret Hash detected"
},
"ruleId": "hardcoded_secret_medium"
}
],
"tool": {
"driver": {
"informationUri": "https://fuzzforge.io",
"name": "FuzzForge Security Assessment",
"rules": [
{
"defaultConfiguration": {
"level": "warning"
},
"fullDescription": {
"text": "Detection rule for sensitive_file vulnerabilities with medium severity"
},
"id": "sensitive_file_medium",
"name": "Sensitive File",
"properties": {
"category": "sensitive_file",
"severity": "medium",
"tags": [
"security",
"sensitive_file",
"medium"
]
},
"shortDescription": {
"text": "sensitive_file vulnerability"
}
},
{
"defaultConfiguration": {
"level": "error"
},
"fullDescription": {
"text": "Detection rule for sql_injection vulnerabilities with high severity"
},
"id": "sql_injection_high",
"name": "Sql Injection",
"properties": {
"category": "sql_injection",
"severity": "high",
"tags": [
"security",
"sql_injection",
"high"
]
},
"shortDescription": {
"text": "sql_injection vulnerability"
}
},
{
"defaultConfiguration": {
"level": "error"
},
"fullDescription": {
"text": "Detection rule for hardcoded_secret vulnerabilities with high severity"
},
"id": "hardcoded_secret_high",
"name": "Hardcoded Secret",
"properties": {
"category": "hardcoded_secret",
"severity": "high",
"tags": [
"security",
"hardcoded_secret",
"high"
]
},
"shortDescription": {
"text": "hardcoded_secret vulnerability"
}
},
{
"defaultConfiguration": {
"level": "warning"
},
"fullDescription": {
"text": "Detection rule for hardcoded_secret vulnerabilities with medium severity"
},
"id": "hardcoded_secret_medium",
"name": "Hardcoded Secret",
"properties": {
"category": "hardcoded_secret",
"severity": "medium",
"tags": [
"security",
"hardcoded_secret",
"medium"
]
},
"shortDescription": {
"text": "hardcoded_secret vulnerability"
}
},
{
"defaultConfiguration": {
"level": "warning"
},
"fullDescription": {
"text": "Detection rule for dangerous_function vulnerabilities with medium severity"
},
"id": "dangerous_function_medium",
"name": "Dangerous Function",
"properties": {
"category": "dangerous_function",
"severity": "medium",
"tags": [
"security",
"dangerous_function",
"medium"
]
},
"shortDescription": {
"text": "dangerous_function vulnerability"
}
}
],
"version": "1.0.0"
}
}
}
],
"version": "2.1.0"
}