Add compliance-staging folder, gitignore agents, update docs and kiro config
This commit is contained in:
48
README.md
48
README.md
@@ -60,9 +60,8 @@ The application provides:
|
||||
| Database | SQLite3 |
|
||||
| File uploads | Multer 2 |
|
||||
| Auth | bcryptjs, cookie-based sessions, express-rate-limit |
|
||||
| Frontend | React 19, lucide-react, xlsx, rehype-sanitize |
|
||||
| Frontend | React 19, lucide-react, recharts, xlsx, react-markdown, rehype-sanitize, mermaid |
|
||||
| Compliance xlsx parsing | Python 3, pandas, openpyxl |
|
||||
| Bulk notes import | Python 3 (stdlib only) |
|
||||
|
||||
---
|
||||
|
||||
@@ -106,7 +105,7 @@ apt install -y python3-pandas python3-openpyxl
|
||||
|
||||
> If apt packages are unavailable or you need a specific version, see `docs/python-venv-setup.md` for the venv fallback approach.
|
||||
|
||||
> The bulk notes import script (`import_notes_from_csv.py`) uses only Python stdlib and does **not** require these packages.
|
||||
> A bulk notes import script (`import_notes_from_csv.py`) is also available in `backend/scripts/` for maintenance tasks like backfilling notes from a CSV. It uses only Python stdlib.
|
||||
|
||||
### 5. Configure environment variables
|
||||
|
||||
@@ -362,7 +361,9 @@ Each row represents a single Ivanti host finding.
|
||||
|
||||
**Column management:** Toggle visibility and drag to reorder via the **Columns** button. Order and visibility persist to `localStorage`.
|
||||
|
||||
**Export:** Click **Export** to download the current filtered view as CSV or XLSX. Requires Admin, Standard_User, or Leadership group.
|
||||
**Row visibility:** Hide individual rows by clicking the `EyeOff` icon on any row, or select multiple rows via checkboxes and click **Hide Selected** in the bulk action toolbar. Hidden rows are excluded from the table, the Action Coverage chart, and exports. Use the **Hidden (N)** button in the toolbar to view and restore hidden rows individually or all at once. Hidden row state persists to `localStorage` across sessions. Row hiding is a personal view preference available to all user groups.
|
||||
|
||||
**Export:** Click **Export** to download the current filtered view as CSV or XLSX. Hidden rows and filtered rows are both excluded from exports. Requires Admin, Standard_User, or Leadership group.
|
||||
|
||||
---
|
||||
|
||||
@@ -509,45 +510,6 @@ Called automatically by the compliance upload flow. Parses the NTS_AEO xlsx repo
|
||||
|
||||
---
|
||||
|
||||
### `backend/scripts/import_notes_from_csv.py`
|
||||
|
||||
Bulk-import notes into the findings cache from a CSV file. Useful for onboarding existing notes or migrating from a spreadsheet.
|
||||
|
||||
**CSV format:**
|
||||
```csv
|
||||
ID,NOTES
|
||||
12345678,EXC-5754
|
||||
87654321,Patched in Feb maintenance window
|
||||
```
|
||||
|
||||
**Usage:**
|
||||
```bash
|
||||
cd backend/scripts
|
||||
|
||||
# Preview what would be imported (no writes)
|
||||
python3 import_notes_from_csv.py input.csv --dry-run
|
||||
|
||||
# Import against the default database path
|
||||
python3 import_notes_from_csv.py input.csv
|
||||
|
||||
# Import against a specific database
|
||||
python3 import_notes_from_csv.py input.csv --db /path/to/cve_database.db
|
||||
```
|
||||
|
||||
| Argument | Description |
|
||||
|---|---|
|
||||
| `csv_file` | Path to the input CSV (required) |
|
||||
| `--db` | Path to the SQLite database (default: `../cve_database.db`) |
|
||||
| `--dry-run` | Preview changes without writing to the database |
|
||||
|
||||
- Notes longer than 255 characters are truncated with a warning
|
||||
- Finding IDs not present in the active Ivanti cache are skipped
|
||||
- Uses UPSERT — running the same CSV twice is safe
|
||||
|
||||
**Dependencies:** Python stdlib only (no pip install required).
|
||||
|
||||
---
|
||||
|
||||
## API Reference
|
||||
|
||||
All endpoints are prefixed with `/api`. All endpoints except `/api/auth/login` and `/api/auth/logout` require a valid session cookie. Group requirements are listed per endpoint.
|
||||
|
||||
Reference in New Issue
Block a user