Skip to content

About

Unofficial command-line client for Cybersecurity Compliance Platform ControlMap (read-only)

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

An unofficial command-line client for ControlMap

At a glance

ControlMap is SaaS that helps companies to organize their compliance documents and processes. It's widely used to manage ISO-27001 certification.

During the introduction of ISO-27001 at dimedis GmbH we discovered that ControlMap and LLMs don't play well together. Because ControlMap is entirely browser-based without any documented API we couldn't instruct an LLM to carry out tasks. However, many tasks could be done perfectly by AI such as

  • discuss approaches
  • gap analysis
  • document reviews
  • consistency checking
  • summarizing documents
  • spell checking

The main problem is that LLMs cannot read what's inside ControlMap.

While there are some export functions they are too limited to allow efficient work with LLMs. On the other hand the underlying API beneath the user interface is easy to reverse engineer. It follows RESTful patterns so exporting data in a way LLMs can read them with ease is doable. That's why we created this command-line client for automated data export.

Features

With ctrlmap-cli you can mirror data and documents from ControlMap to a folder on your disk using machine and human-readable data formats (Markdown and JSON). You can export

  • Governance documents
  • Policies
  • Procedures
  • Risk Register
  • Vendor Register (including document downloads, quick assessments, risks & action items)
  • Audit trail (aka Activities) of all above-mentioned documents

Usage

ctrlmap-cli is written in Python and distributed as a single-file zip-app. Python 3.9 or newer is required.

  • Download a release to anywhere you like e.g. /usr/local/bin.
  • Open ControlMap in your browser with Dev-Tools open. Open the network tab of the dev tools and click on "Policies". Grab your API base URL and your bearer token. See screenshot.
  • Go to an empty folder and make it the folder where ControlMap documents are mirrored to. Your API URL of ControlMap is required. E.g. https://api.eu.ctrlmap.com
     ctrlmap-cli init https://<CONTROLMAP-API-URL>/
    You will be asked interactively for the bearer token. Your input will not be displayed on the console. This step will create the file .ctrlmap-cli.ini and the basic folder structure.
    .
    ├── .ctrlmap-cli.ini
    ├── govs/
    ├── pols/
    ├── pros/
    ├── risks/
    └── vendors/
    
  • Now you can export all data or individual categories:
    • ctrlmap-cli export-all — export everything
    • ctrlmap-cli governance export — all governance documents
    • ctrlmap-cli policies export — all policies
    • ctrlmap-cli procedures export — all procedures
    • ctrlmap-cli risks export — all risks
    • ctrlmap-cli vendors export — all vendors
  • Or export a single item by its code:
    • ctrlmap-cli governance export GOV-1 — one governance document
    • ctrlmap-cli policies export POL-5 — one policy
    • ctrlmap-cli procedures export PRO-3 — one procedure
    • ctrlmap-cli risks export RSK-66 — one risk
    • ctrlmap-cli vendors export VND-17 — one vendor Single-item export updates the category index file automatically.
  • Optional flags:
    • --force — overwrite existing files without confirmation
    • --keep-raw-json — also write raw JSON files alongside Markdown

Place export options after the command, for example ctrlmap-cli policies export POL-5 --force. Numeric codes also work: ctrlmap-cli policies export 5. Run ctrlmap-cli --help or ctrlmap-cli policies export --help for command-specific help. Run ctrlmap-cli --show-completion to print a completion script for your detected shell, or ctrlmap-cli --install-completion to install completion for your detected shell. In environments where Typer cannot detect the shell, generate a script explicitly, for example _CTRLMAP_CLI_COMPLETE=source_bash ctrlmap-cli > ctrlmap-cli-completion.bash, then source that file from your shell configuration.

Migration from action flags

The Typer interface replaces the previous flags; legacy flags are no longer accepted. Replace --init URL with init URL, --copy-all with export-all, and --copy-pols / --copy-pol CODE with policies export / policies export CODE. Use the corresponding domain commands above for other exports. Update external scripts accordingly. Configuration files and export directories are unchanged.

About

Unofficial command-line client for Cybersecurity Compliance Platform ControlMap (read-only)

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages