
installer v13.30.0
Linux, macOS और Windows के लिए cnquery और cnspec की इंस्टॉल स्क्रिप्ट्स
अवलोकन
स्थिति
इंस्टॉलेशन
mql और cnspec को इंस्टॉल करने का सबसे आसान तरीका इंस्टॉल स्क्रिप्ट का उपयोग करना है।
Shell Script के माध्यम से (Linux और macOS)
https://install.mondoo.com/sh```bash
bash -c "$(curl -sSL https://install.mondoo.com/sh)"
### PowerShell के माध्यम से (Windows)
[`https://install.mondoo.com/ps1`](https://install.mondoo.com/ps1)```powershell
Set-ExecutionPolicy Unrestricted -Scope Process -Force;
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072;
iex ((New-Object System.Net.WebClient).DownloadString('https://install.mondoo.com/ps1'));
Install-Mondoo;
HTTP प्रॉक्सी के पीछे
इंस्टॉल स्क्रिप्ट को -x (Linux और macOS) या -Proxy (Windows) के साथ प्रॉक्सी पास करें। स्क्रिप्ट अपने स्वयं के डाउनलोड, पैकेज इंस्टॉलेशन, cnspec login और ऑटो अपडेटर को इसके माध्यम से रूट करती है। स्क्रिप्ट का प्रारंभिक डाउनलोड फ्लैग पढ़े जाने से पहले होता है, इसलिए उसे भी प्रॉक्सी की ओर इंगित करें:```bash
export https_proxy='http://proxy.example.com:3128'
curl -sSL --proxy "$https_proxy" https://install.mondoo.com/sh | bash -s -- -x "$https_proxy"
| `-s` | `--server` | Server URL (default: `http://localhost:8080`) |
| `-t` | `--token` | API token for authentication |
| `-o` | `--output` | Output format: `json`, `yaml`, `table` (default: `table`) |
| `-v` | `--verbose` | Enable verbose logging |
| `-q` | `--quiet` | Suppress non-essential output |
| `--timeout` | | Request timeout in seconds (default: `30`) |
| `--insecure` | | Skip TLS certificate verification |
### Examples
```bash
# List all projects
kitploit-cli projects list
# Get details of a specific project
kitploit-cli projects get --id 12345
# Export scan results to JSON
kitploit-cli scans export --id 67890 --output json
# Run a scan with a custom configuration
kitploit-cli scans run --config ./scan-config.yaml --verbose
Configuration File
The CLI reads configuration from ~/.kitploit/config.yaml by default. You can override this with the --config flag.
server: http://localhost:8080
token: your-api-token-here
output: table
timeout: 30
insecure: false
Environment Variables
All configuration options can be set via environment variables with the KITPLOIT_ prefix:
| Variable | Description |
|---|---|
KITPLOIT_SERVER | Server URL |
KITPLOIT_TOKEN | API token |
KITPLOIT_OUTPUT | Output format |
KITPLOIT_TIMEOUT | Request timeout |
KITPLOIT_INSECURE | Skip TLS verification |
Troubleshooting
Connection Refused
If you see a connection refused error, verify that the server is running and accessible:
curl -I http://localhost:8080/health
Authentication Failed
Ensure your API token is valid and has not expired. You can regenerate a token from the web interface under Settings → API Tokens.
Timeout Errors
For large scans, increase the timeout value:
kitploit-cli scans run --config ./scan-config.yaml --timeout 120
Contributing
We welcome contributions from the community. Please read our Contributing Guide before submitting a pull request.
Development Setup
# Clone the repository
git clone https://github.com/kitploit/kitploit-cli.git
cd kitploit-cli
# Install dependencies
npm install
# Run tests
npm test
# Build for production
npm run build
Code Style
This project follows the Airbnb JavaScript Style Guide. Please ensure your code passes linting before submitting:
npm run lint
License
This project is licensed under the MIT License. See the LICENSE file for details.
Support
- 📖 Documentation
- 💬 Community Forum
- 🐛 Issue Tracker
- 📧 Email Support```powershell Set-ExecutionPolicy Unrestricted -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; $wc = New-Object System.Net.WebClient; $wc.Proxy = New-Object System.Net.WebProxy('http://proxy.example.com:3128'); iex ($wc.DownloadString('https://install.mondoo.com/ps1')); Install-Mondoo -Proxy 'http://proxy.example.com:3128';
Linux और macOS पर, जब `-x` नहीं दिया जाता है, तो एक विरासत में मिला `https_proxy` या `http_proxy` स्वचालित रूप से उठाया जाता है। किसी भी तरह, दोनों रूप निर्यात किए जाते हैं, इसलिए वितरण के अपने रिपॉजिटरी — जो Debian और Ubuntu पर सादे HTTP हैं — भी प्रॉक्सी के माध्यम से पहुँचे जाते हैं। आपके द्वारा सेट किया गया कोई भी `no_proxy` बिना बदलाव के आगे बढ़ाया जाता है, जिसमें `sudo` के पार भी शामिल है।
प्रॉक्सी URL एक सादा URL होना चाहिए: यदि इसमें क्रेडेंशियल्स हैं, तो उन्हें प्रतिशत-एनकोड करें (`!` को `%21`, इत्यादि)। मान ऑटो अपडेटर के शेड्यूल किए गए जॉब में लिखा जाता है, इसलिए जिन वर्णों को वहाँ उद्धृत करने की आवश्यकता होगी, उन्हें एस्केप करने के बजाय अस्वीकार कर दिया जाता है।
## अपने लक्ष्य प्लेटफ़ॉर्म को स्कैन करें
अपने [लक्ष्य प्लेटफ़ॉर्म](https://github.com/mondoohq/cnspec/#supported-targets) को स्कैन करें:```bash
# query system information with incident and inventory query pack
mql scan aws
# scan the platform for security vulnerabilities
cnspec scan aws
अधिक नीतियों तक पहुँचने और रिपोर्ट संग्रहीत करने के लिए Mondoo खाते के लिए साइन अप करें। अधिक जानने के लिए, हमसे संपर्क करें।```bash cnspec login -t 'eyJh...llZ4BW'
mql और cnspec स्थानीय और दूरस्थ लक्ष्यों का समर्थन करते हैं, जिनमें सर्वर (Linux, Windows, macOS), क्लाउड (AWS, Azure, Google, VMware), Kubernetes (EKS, GKE, AKS, स्व-प्रबंधित), कंटेनर, कंटेनर रजिस्ट्रियाँ, SaaS उत्पाद (Google Workspace, M365, GitHub, GitLab), और बहुत कुछ शामिल हैं।
स्कैन चलाएँ:```bash
# scan your local host
cnspec scan local
# scan a cloud environment
cnspec scan aws
cnspec scan gcp
cnspec scan azure
# scan a kubernetes cluster
cnspec scan k8s
# scan a docker image from a remote registry
cnspec scan docker image debian:12
# scan a docker container (get ids from docker ps)
cnspec scan docker container 00fa961d6b6a
# scan a system over ssh
cnspec scan ssh [email protected]
पैकेज जानकारी