Commit Graph

5 Commits

Author SHA1 Message Date
aitbc
a58773d4d4 Migrate exchange app to centralized aitbc package utilities
- Migrate 2 files from logging to aitbc.get_logger
- health_monitor.py, real_exchange_integration.py
- Remove logging.basicConfig() from both files
- Migrate 3 files with hardcoded paths to use DATA_DIR constant
- simple_exchange_api.py, scripts/seed_market.py, database.py
2026-04-25 07:12:27 +02:00
aitbc
2c2c2df585 feat: comprehensive security remediation - CodeQL fixes and best practices
Some checks failed
API Endpoint Tests / test-api-endpoints (push) Successful in 11s
Blockchain Synchronization Verification / sync-verification (push) Failing after 1s
Documentation Validation / validate-docs (push) Successful in 11s
Documentation Validation / validate-policies-strict (push) Successful in 4s
Integration Tests / test-service-integration (push) Successful in 39s
Multi-Node Blockchain Health Monitoring / health-check (push) Successful in 2s
P2P Network Verification / p2p-verification (push) Successful in 3s
Production Tests / Production Integration Tests (push) Failing after 6s
Python Tests / test-python (push) Successful in 10s
Security Scanning / security-scan (push) Failing after 10s
Phase 1: Dependency Vulnerabilities
- Resolved 72/72 GitHub Dependabot vulnerabilities (100%)
- Updated cryptography, ecdsa, black, orjson, python-multipart

Phase 2: CodeQL Static Analysis (25+ categories)
- Fixed 100+ information exposure instances (str(e) → generic messages)
- Fixed 9 clear-text logging/storage instances
- Fixed 9 log injection instances (user data removed from logs)
- Fixed 2 hardcoded credential instances
- Fixed 15 print statements (replaced with logger)
- Added SSRF and path validation (18 alerts with robust validation)
- 20+ additional categories scanned (0 issues found)

Phase 3: CodeQL Infrastructure
- Created GitHub Actions CodeQL workflow
- Created CodeQL suppression file for false positives
- Moved CodeQL database to /var/lib/aitbc/codeql-db

Phase 4: Security Documentation
- Updated SECURITY_FIXES_SUMMARY.md with comprehensive details
- Documented security best practices for developers

Files modified: 48 files across coordinator-api, agent-services, blockchain-node, exchange, wallet, scripts, and infrastructure
2026-04-24 10:42:29 +02:00
aitbc
d3415413b3 Add hash conflict detection and cleanup across chains in import operations and improve database initialization
Some checks failed
Integration Tests / test-service-integration (push) Has been cancelled
Python Tests / test-python (push) Has been cancelled
Security Scanning / security-scan (push) Has been cancelled
API Endpoint Tests / test-api-endpoints (push) Has been cancelled
- Add hash conflict detection in import_block to delete existing blocks with same hash
- Add hash conflict cleanup in import_chain before importing blocks
- Add logging for hash conflict deletions showing affected chains
- Add WAL file permission setting in init_db for .db-shm and .db-wal files
- Add test_import_chain_clears_hash_conflicts_across_chains to verify cross-chain hash cleanup
2026-04-15 08:17:35 +02:00
fb460816e4 fix: standardize exchange database path to use centralized data directory with environment variable
All checks were successful
API Endpoint Tests / test-api-endpoints (push) Successful in 38s
Documentation Validation / validate-docs (push) Successful in 10s
Integration Tests / test-service-integration (push) Successful in 57s
Python Tests / test-python (push) Successful in 1m32s
Security Scanning / security-scan (push) Successful in 1m7s
🔧 Database Path Standardization:
• Change DATABASE_URL environment variable to EXCHANGE_DATABASE_URL
• Update default database path from ./exchange.db to /var/lib/aitbc/data/exchange/exchange.db
• Apply consistent path resolution across all exchange database connections
• Update database.py, seed_market.py, and simple_exchange_api.py with new path
• Maintain backward compatibility through
2026-03-30 13:34:20 +02:00
oib
bb5363bebc refactor: consolidate blockchain explorer into single app and update backup ignore patterns
- Remove standalone explorer-web app (README, HTML, package files)
- Add /web endpoint to blockchain-explorer for web interface access
- Update .gitignore to exclude application backup archives (*.tar.gz, *.zip)
- Add backup documentation files to .gitignore (BACKUP_INDEX.md, README.md)
- Consolidate explorer functionality into main blockchain-explorer application
2026-03-06 18:14:49 +01:00