diff --git a/.github/workflows/check-mkdocs-uris.yml b/.github/workflows/check-mkdocs-uris.yml new file mode 100644 index 00000000..219fcbcc --- /dev/null +++ b/.github/workflows/check-mkdocs-uris.yml @@ -0,0 +1,45 @@ +name: Check MkDocs URIs + +on: + pull_request: + push: + branches: + - main + +jobs: + check-mkdocs-uris: + name: Validate MkDocs URIs + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + + - name: Disable git-committers plugin in CI + # The git-committers plugin is not CI-safe: + # it performs GitHub API calls even without an explicit token, + # which causes 403 rate-limit errors in GitHub Actions. + # We remove the plugin block entirely for CI builds. + run: | + sed -i '/- git-committers:/,/^[[:space:]]*-[[:space:]]/d' mkdocs.yml + + - name: Check for underscores in MkDocs URIs + run: | + echo "Checking mkdocs.yml for URIs (use '-' instead of '_')" + + INVALID_PATHS=$(grep '.md' mkdocs.yml | grep '_' | grep -Ev 'pymdownx\.superfences|md_in_html' || true) + + if [ -n "$INVALID_PATHS" ]; then + echo "❌ Invalid MkDocs URIs detected (use '-' instead of '_'):" + echo "$INVALID_PATHS" | sed 's/^/ - /' + echo "Required format:" + echo "usage/scenarios_and_simulations.md -> usage/scenarios-and-simulations.md" + exit 1 + else + echo "✅ All MkDocs URIs are clean (no underscores)." + fi diff --git a/docs/administration/users_and_rbac.md b/docs/administration/users-and-rbac.md similarity index 100% rename from docs/administration/users_and_rbac.md rename to docs/administration/users-and-rbac.md diff --git a/docs/deployment/installation.md b/docs/deployment/installation.md index f758d297..777225de 100644 --- a/docs/deployment/installation.md +++ b/docs/deployment/installation.md @@ -88,7 +88,7 @@ docker compose up -d This section provides instructions to install and run a pre-built OpenAEV server with its dependencies. Note that this does not cover building from source, -which you will find in the [Development section](../development/build_from_source.md) instead. +which you will find in the [Development section](../development/build-from-source.md) instead. ### Prepare the installation diff --git a/docs/development/build_from_source.md b/docs/development/build-from-source.md similarity index 97% rename from docs/development/build_from_source.md rename to docs/development/build-from-source.md index ec1f1dc4..2a392e5c 100644 --- a/docs/development/build_from_source.md +++ b/docs/development/build-from-source.md @@ -3,8 +3,8 @@ Ensure you have followed the steps for installing prerequisites according to your development platform of choice: - * [Linux (Ubuntu used as example)](environment_ubuntu.md) - * [Windows](environment_windows.md) + * [Linux (Ubuntu used as example)](environment-ubuntu.md) + * [Windows](environment-windows.md) * MacOS (TBD) # Building and running from source diff --git a/docs/development/environment_ubuntu.md b/docs/development/environment-ubuntu.md similarity index 100% rename from docs/development/environment_ubuntu.md rename to docs/development/environment-ubuntu.md diff --git a/docs/development/environment_windows.md b/docs/development/environment-windows.md similarity index 100% rename from docs/development/environment_windows.md rename to docs/development/environment-windows.md diff --git a/docs/usage/components/channels.md b/docs/usage/components/channels.md index b5a9375c..a197d31e 100644 --- a/docs/usage/components/channels.md +++ b/docs/usage/components/channels.md @@ -1,6 +1,6 @@ # Channels -In OpenAEV, Channels represent communication medias with a particular look. They are used to present [web articles or other media contents](media_pressure.md) to Players in a specific way. +In OpenAEV, Channels represent communication medias with a particular look. They are used to present [web articles or other media contents](media-pressure.md) to Players in a specific way. It helps give shape to your Scenario context and events. @@ -20,6 +20,6 @@ On the right, a mock up of the overview is displayed to give you the look and fi A Channel will then be used in Scenario and in Simulation definition. When you create an Article, you have to choose the Channel that will give it an adequate shape. -See [Media pressure](media_pressure.md) page to know how to create and add Articles to your Scenarios. +See [Media pressure](media-pressure.md) page to know how to create and add Articles to your Scenarios. ![Channel selection during Article creation](../assets/channel_selection_during_creation.png) diff --git a/docs/usage/components/media_pressure.md b/docs/usage/components/media-pressure.md similarity index 100% rename from docs/usage/components/media_pressure.md rename to docs/usage/components/media-pressure.md diff --git a/docs/usage/default_asset_rules.md b/docs/usage/default-asset-rules.md similarity index 100% rename from docs/usage/default_asset_rules.md rename to docs/usage/default-asset-rules.md diff --git a/docs/usage/getting-started.md b/docs/usage/getting-started.md index 546e63d0..4d4025ec 100644 --- a/docs/usage/getting-started.md +++ b/docs/usage/getting-started.md @@ -67,7 +67,7 @@ You can: Once defined, a scenario can be turned into a [simulation](simulation.md): a live execution in your environment, either one-shot or scheduled regularly. -During simulations, [expectations](injects_and_expectations.md) are validated: +During simulations, [expectations](injects-and-expectations.md) are validated: - **Automatically**, via integrations with your stack - **Manually**, by observers validating human reactions diff --git a/docs/usage/injects_and_expectations.md b/docs/usage/injects-and-expectations.md similarity index 100% rename from docs/usage/injects_and_expectations.md rename to docs/usage/injects-and-expectations.md diff --git a/docs/usage/injects_builtin.md b/docs/usage/injects-builtin.md similarity index 100% rename from docs/usage/injects_builtin.md rename to docs/usage/injects-builtin.md diff --git a/docs/usage/scenario_import.md b/docs/usage/scenario-import.md similarity index 100% rename from docs/usage/scenario_import.md rename to docs/usage/scenario-import.md diff --git a/docs/usage/scenario.md b/docs/usage/scenario.md index 5d7db6ab..589e5e48 100644 --- a/docs/usage/scenario.md +++ b/docs/usage/scenario.md @@ -54,7 +54,7 @@ In the "Definition" tab, you can add various elements to construct events: - [Teams and Players](people.md) involved in the scenario, - [Custom variables](components/variables.md) for simplifying injects' customization, -- Articles that you might use to simulate [media pressure](components/media_pressure.md), +- Articles that you might use to simulate [media pressure](components/media-pressure.md), - [Challenges](components/challenges.md) designed for including Capture The Flag elements in your scenario. diff --git a/docs/usage/scenario/security-coverage.md b/docs/usage/scenario/security-coverage.md index d18a8e62..401d9fb0 100644 --- a/docs/usage/scenario/security-coverage.md +++ b/docs/usage/scenario/security-coverage.md @@ -113,7 +113,7 @@ After injects are generated: - Review and customize the **Scenario** to match your organization’s needs. - Assign appropriate **Asset groups** to each inject. - Optionally, configure default **Asset Groups** for scenarios created from OpenCTI using - the [Default Asset Groups](../default_asset_rules.md) page. + the [Default Asset Groups](../default-asset-rules.md) page. ![Inject Asset Groups](assets/inject-asset-group.png) diff --git a/docs/usage/scenarios_and_simulations.md b/docs/usage/scenarios-and-simulations.md similarity index 100% rename from docs/usage/scenarios_and_simulations.md rename to docs/usage/scenarios-and-simulations.md diff --git a/docs/usage/simulation_reports.md b/docs/usage/simulation-reports.md similarity index 100% rename from docs/usage/simulation_reports.md rename to docs/usage/simulation-reports.md diff --git a/mkdocs.yml b/mkdocs.yml index 16a2d8f9..d968a97d 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -140,8 +140,8 @@ nav: - User Guide: - Getting started: usage/getting-started.md - Foundations: - - Scenario and Simulations: usage/scenarios_and_simulations.md - - Injects and Expectations: usage/injects_and_expectations.md + - Scenario and Simulations: usage/scenarios-and-simulations.md + - Injects and Expectations: usage/injects-and-expectations.md - Evaluate your Security posture: - Overview: usage/evaluate/overview.md - Simulation: usage/simulation.md @@ -163,25 +163,25 @@ nav: - Build your own Threat Scenario: - Scenario: usage/scenario.md - Scenario Generation from OpenCTI Security Coverage: usage/scenario/security-coverage.md - - Default Asset Rules: usage/default_asset_rules.md - - Importing injects into a Scenario: usage/scenario_import.md + - Default Asset Rules: usage/default-asset-rules.md + - Importing injects into a Scenario: usage/scenario-import.md - Assets: usage/assets.md - People: usage/people.md - Components: - Documents: usage/components/documents.md - Custom variables: usage/components/variables.md - Channels: usage/components/channels.md - - Media pressure: usage/components/media_pressure.md + - Media pressure: usage/components/media-pressure.md - Challenges: usage/components/challenges.md - Lessons: usage/components/lessons.md - Payloads: usage/payloads/payloads.md - Share and export: - - Simulations: usage/simulation_reports.md + - Simulations: usage/simulation-reports.md - Notifications: usage/notifications.md - Interact with your environment: - Injectors: - Overview: usage/injectors.md - - Built-In Injector: usage/injects_builtin.md + - Built-In Injector: usage/injects-builtin.md - Caldera Injector: usage/inject-caldera.md - Collectors: - Overview: usage/collectors.md @@ -194,7 +194,7 @@ nav: - Parameters: administration/parameters.md - Security: - Policies: administration/policies.md - - Users and RBAC: administration/users_and_rbac.md + - Users and RBAC: administration/users-and-rbac.md - Taxonomies: administration/taxonomies.md - XTM Hub: administration/hub.md # Warning: page is linked in XTM Hub documentation - Reference: @@ -204,9 +204,9 @@ nav: - Telemetry: reference/deployment/telemetry.md - Development: - Prerequisites: - - Ubuntu: development/environment_ubuntu.md - - Windows: development/environment_windows.md - - Building and running from source: development/build_from_source.md + - Ubuntu: development/environment-ubuntu.md + - Windows: development/environment-windows.md + - Building and running from source: development/build-from-source.md - Platform: development/platform.md - Collectors: development/collectors.md - Injectors: development/injectors.md