استخدم هذا إذا
Install a managed Linux VM scanner that reuses an existing Wazuh or OSSEC alert source, runs Lynis hardening audits, and forwards host findings from one native systemd service.
Install a managed Linux VM scanner that reuses an existing Wazuh or OSSEC alert source, runs Lynis hardening audits, and forwards host findings from one native systemd service. الجمهور: Security operations teams, infrastructure engineers, and platform teams. وقت الإعداد المعتاد: 10 minutes on Ubuntu/Debian systemd hosts.
Install a managed Linux VM scanner that reuses an existing Wazuh or OSSEC alert source, runs Lynis hardening audits, and forwards host findings from one native systemd service.
انسخ إعداد البداية وقم بتشغيله في بيئتك، ثم عد إلى هنا للحصول على تفاصيل التوزيع الأكثر عمقًا.
Demonstration only
This configuration is designed for ease of use. To deploy scanner clients at scale, please plan your deployment architecture accordingly or contact us for enterprise best practices.
Download the exact source files referenced on this page, or run the one-command installer to write them locally before following the deployment steps.
Creates `deploy/vm-scanner/managed/` with an Ubuntu/Debian installer that defaults to existing Wazuh/OSSEC alerts and supports explicit managed-local OSSEC installs.
BLACKSHIELD_SITE_URL=https://blackshield.chaplau.com \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/vm-scanner-managed-linux.sh)
cd deploy/vm-scanner/managedCreates `deploy/vm-scanner/` with a Compose file, a ready-to-edit `.env.vm-scanner`, and a README so local host ingestion is runnable without rewriting the guide commands.
BLACKSHIELD_VMS_IMAGE=public.ecr.aws/blackshield-security/vms-scanner:1.0.14 \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/vm-scanner-compose.sh)
cd deploy/vm-scannerCreates `deploy/vm-scanner/systemd/` with a Docker-backed unit file, env template, install helper, and README for long-running host services.
BLACKSHIELD_VMS_IMAGE=public.ecr.aws/blackshield-security/vms-scanner:1.0.14 \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/vm-scanner-systemd.sh)
cd deploy/vm-scanner/systemdCreates `deploy/vm-scanner/cron/` with a one-shot wrapper, cron example, env template, and README for periodic host-side forwarding.
BLACKSHIELD_VMS_IMAGE=public.ecr.aws/blackshield-security/vms-scanner:1.0.14 \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/vm-scanner-cron.sh)
cd deploy/vm-scanner/cronCreates `deploy/aws-vm-scanner/` with an ECS Fargate service, S3-backed source settings, and a host upload helper so AWS rollout can start without writing infrastructure boilerplate first.
BLACKSHIELD_VMS_IMAGE=public.ecr.aws/blackshield-security/vms-scanner:1.0.14 \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/aws-vm-scanner.sh)
cd deploy/aws-vm-scannerCreates `deploy/gcp-vm-scanner/` with a Cloud Run service, GCS-backed source settings, and a host upload helper so GCP rollout can start without rewriting the guide commands.
BLACKSHIELD_VMS_IMAGE=public.ecr.aws/blackshield-security/vms-scanner:1.0.14 \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/gcp-vm-scanner.sh)
cd deploy/gcp-vm-scannerBLACKSHIELD_SITE_URL=https://blackshield.chaplau.com \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/vm-scanner-managed-linux.sh)
cd deploy/vm-scanner/managed
# Edit .env.vm-scanner, replace BLACKSHIELD_API_KEY, and choose managed-local only if approved.
sudo ./install-managed-vm-scanner.shsudo install -d -m 750 /var/lib/blackshield/vm-scanner
docker run --rm \
-e BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
-e BLACKSHIELD_API_KEY=sp_xxxx \
-e VMS_COLLECTOR_MODE=file \
-e OSSEC_ALERTS_FILE=/var/ossec/logs/alerts/alerts.json \
-e LYNIS_ENABLED=true \
-e LYNIS_REPORT_FILE=/host/lynis/lynis-report.dat \
-e SCAN_INTERVAL_SECONDS=0 \
-v /var/ossec/logs/alerts:/var/ossec/logs/alerts:ro \
-v /var/lib/blackshield/vm-scanner/lynis:/host/lynis:ro \
-v /var/lib/blackshield/vm-scanner:/tmp/vms-state \
public.ecr.aws/blackshield-security/vms-scanner:1.0.14sudo systemctl status blackshield-vms-scanner --no-pager
sudo -u blackshield-vms-scanner test -r /etc/blackshield/vm-scanner.env
sudo -u blackshield-vms-scanner test -r /var/ossec/logs/alerts/alerts.json
sudo journalctl -u blackshield-vms-scanner -n 100 --no-pager
curl http://localhost:8080/health
curl http://localhost:8080/metricsVMS_COLLECTOR_MODE=s3
VMS_SOURCE_URI=s3://blackshield-vm-alerts/prod/web-01/alerts.json
OSSEC_STATE_FILE=/tmp/vms-state/ossec-state.json
SCAN_INTERVAL_SECONDS=60استخدم الخطوات الإرشادية أدناه عندما ترغب في تخصيص التوزيع أو التحقق من الملكية أو توسيع النشر بأمان.
الخطوة 1
The managed installer makes VM scanner mean a working host scanner: it defaults to existing Wazuh or OSSEC alerts, while OSSEC local installation is an explicit customer-approved option.
معايير النجاح
Rotate any `sp_...` key pasted into terminals, tickets, or chat before retesting.
الخطوة 2
Download the recommended managed bundle first. It installs `/usr/local/bin/blackshield-vms-scanner-run`, the native package under `/opt/blackshield/vm-scanner/venv`, a restartable scanner unit, and a Lynis audit timer.
معايير النجاح
Advanced existing-source modes remain available below for Docker Compose, Docker-backed systemd, cron, AWS Fargate, and GCP Cloud Run.
الخطوة 3
Create a dedicated ingestion key, then update the generated env file before running the installer.
معايير النجاح
Only override `BLACKSHIELD_VMS_NATIVE_PACKAGE_URL` when you also provide the matching `BLACKSHIELD_VMS_NATIVE_PACKAGE_SHA256`.
الخطوة 4
Run the generated installer with sudo, then confirm OSSEC/Wazuh alerts are readable and the native BlackShield service is healthy.
معايير النجاح
Open the finding detail and confirm Host Identity, Network / Actor, Detection Provenance, and Raw Evidence are populated from the alert where available.
الخطوة 5
Keep the original sidecar and cloud patterns for environments where OSSEC/Wazuh is already managed elsewhere or alerts are synced through object storage.
معايير النجاح
Existing OSSEC/Wazuh deployments can still use Docker, cron, and object-storage collectors without changing the managed Linux default.
Keep your rollout moving with the next recommended step.
مراجعة النتائج وتحديد الأولويات