Supported Operations
The plugin follows the standard discovery-plugin CLI contract.
Command | Purpose |
|---|---|
| Emits plugin metadata (id, version, description, contact). |
| Emits the JSON schema for the configuration. |
| Emits UI rendering hints (field order, password widget, help text). |
| Validates the config and verifies connectivity/auth against |
| Runs all discovery routines and emits scan results plus a state record. |
./nutanix-pe-plugin info
./nutanix-pe-plugin schema
./nutanix-pe-plugin uischema
./nutanix-pe-plugin test --inputfile input.json --outputfile test-result.json
./nutanix-pe-plugin scan --inputfile input.json --outputfile scan-result.json
APIs Scanned
The plugin scans 15 distinct API endpoints across v1 and v2.0 PrismGateway:
# | API endpoint | API | Asset (s) Produced |
|---|---|---|---|
1 | TLS handshake against the Prism endpoint | TLS |
|
2 |
| v1 |
|
3 |
| v2 |
|
4 |
| v2 |
|
5 |
| v2 |
|
6 |
| v2 |
|
7 |
| v2 |
|
8 |
| v2 |
|
9 |
| v2 |
|
10 |
| v1 |
|
11 |
| v2 |
|
12 |
| v1 |
|
13 |
| v2 |
|
14 |
| v1 |
|
15 |
| v2 |
|
API Endpoint Reference
Endpoint definitions live in api_endpoints.go. All endpoints require HTTP Basic Auth and HTTPS.
Output
All results are written as newline-separated JSON documents (one per line). Each scan document is a formatter-produced asset record; a final state document carries lastScanDate. Certificate assets include a cert_pem field (base64 DER body, no embedded newlines) from which PEM-intrinsic metadata (subject, issuer, validity, serial) is derived rather than duplicated in extra.
Full vs Incremental Scans
The plugin does not support incremental scanning because Prism Element APIs lack modification timestamps and filtering capabilities. Each scan performs a full reconciliation of the cluster's cryptographic assets. The state field is present for framework compatibility.
Building & Testing
make build # build the plugin binary
make test # run unit + integration tests
make docker # build the plugin container image
Unit and integration tests exercise all CLI commands. Integration tests use a mock Prism Element server built with httptest.NewTLSServer.