From bc86c2db9f446d277d5b4a114cbdc66f9d18f77c Mon Sep 17 00:00:00 2001 From: Defame1297 Date: Sun, 15 Nov 2026 22:44:55 +0000 Subject: [PATCH] chore(release): 1.6.0 Adds the sshd role. ufw base rules can delete a rule (delete: true), so an open rule can be replaced by narrower ones, and fail2ban gains fail2ban_ignoreip. Existing behaviour is unchanged unless the new options are used. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm --- CHANGELOG.rst | 15 +++++++++++ CLAUDE.md | 2 +- README.md | 4 +-- changelogs/.plugin-cache.yaml | 6 ++++- changelogs/changelog.yaml | 29 ++++++++++++++++++++++ changelogs/fragments/fail2ban-ignoreip.yml | 6 ----- changelogs/fragments/sshd-role.yml | 7 ------ changelogs/fragments/ufw-rule-delete.yml | 7 ------ galaxy.yml | 2 +- 9 files changed, 53 insertions(+), 25 deletions(-) delete mode 100644 changelogs/fragments/fail2ban-ignoreip.yml delete mode 100644 changelogs/fragments/sshd-role.yml delete mode 100644 changelogs/fragments/ufw-rule-delete.yml diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 47a007a..2ed590a 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,21 @@ mortis.kamino Release Notes .. contents:: Topics +v1.6.0 +====== + +Release Summary +--------------- + +Adds the sshd role. ufw base rules can now delete a rule, so an open rule can be replaced by narrower ones, and fail2ban gains fail2ban_ignoreip. Existing behaviour is unchanged unless the new options are used. + +Minor Changes +------------- + +- fail2ban - add ``fail2ban_ignoreip``, written as ``ignoreip`` in the ``[DEFAULT]`` section of ``jail.local`` so it applies to every jail, the service jails included. The default is Fail2Ban's own (``127.0.0.1/8`` and ``::1``). The first run after upgrading adds the section and restarts Fail2Ban once. +- sshd - New role. Writes a hardened sshd drop-in selected by a profile (``pve``, ``ubuntu_lxc``, ``ubuntu_vm``), merged from a baseline, the profile and ``sshd_settings``, checked with ``sshd -t`` and reloaded through a handler. It refuses to run when the result would lock SSH out (password login off without public key login), when the ``pve`` profile does not allow root public-key login or lacks ``rsa-sha2-512`` (Proxmox VE cluster SSH needs both), and when any profile allows SHA-1 ``ssh-rsa``. +- ufw - ``ufw_rules`` entries accept ``delete`` (a boolean). An entry with ``delete: true`` removes the rule it describes, so a base rule can be replaced, for example an open SSH rule by narrower ones. Deletes are applied after every other rule of the list, a delete entry never satisfies the SSH lock-out guard, and a rule that the list both adds and deletes fails the play. ``service_rules`` does not accept the key. + v1.5.0 ====== diff --git a/CLAUDE.md b/CLAUDE.md index 41885d2..97d7ba0 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -6,7 +6,7 @@ Guidance for Claude Code (claude.ai/code) in this repository. `mortis.kamino`: an Ansible Collection (GPL-3.0-or-later, REUSE-compliant), extracted role by role from the author's homelab environment repository. The design contract is ADR 0004 (in the -maintainer's environment repository). Roles arrive here wave by wave; `docker` is in 1.0.0, `fail2ban` in 1.1.0, `network_interfaces` and `systemd_hardening` in 1.2.0, `system_baseline` in 1.3.0, `ufw` in 1.4.0; 1.5.0 adds no role (new `system_baseline` options). +maintainer's environment repository). Roles arrive here wave by wave; `docker` is in 1.0.0, `fail2ban` in 1.1.0, `network_interfaces` and `systemd_hardening` in 1.2.0, `system_baseline` in 1.3.0, `ufw` in 1.4.0; 1.5.0 adds no role (new `system_baseline` options); `sshd` in 1.6.0. **Roadmap.** The roles still to come, and the ones that will never be extracted, are listed in the README section "Roadmap". Context: the maintainer's private environment repository (a diff --git a/README.md b/README.md index fdfac99..efdb20a 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ An Ansible Collection of reusable, hardened roles for a self-hosted home lab: Linux baseline, firewall, SSH, user management and, in later releases, Proxmox, Gitea and Gitea Actions runner roles. -Status: roles arrive in waves. Release 1.5.0 holds the `docker`, `fail2ban`, `network_interfaces`, `system_baseline`, `systemd_hardening` and `ufw` roles. +Status: roles arrive in waves. Release 1.6.0 holds the `docker`, `fail2ban`, `network_interfaces`, `sshd`, `system_baseline`, `systemd_hardening` and `ufw` roles. ## Consuming @@ -16,7 +16,7 @@ name (FQCN) only, `mortis.kamino.`: collections: - name: https://git.rkdr.net/mortis/kamino.git type: git - version: v1.5.0 + version: v1.6.0 ``` Its dependencies (`community.general`, `ansible.posix`) are declared in `galaxy.yml`, so diff --git a/changelogs/.plugin-cache.yaml b/changelogs/.plugin-cache.yaml index bf36bad..23c469f 100644 --- a/changelogs/.plugin-cache.yaml +++ b/changelogs/.plugin-cache.yaml @@ -12,6 +12,10 @@ objects: description: Manage /etc/network/interfaces name: network_interfaces version_added: null + sshd: + description: Write a hardened sshd drop-in + name: sshd + version_added: null system_baseline: description: Apply the OS baseline for a system type name: system_baseline @@ -40,4 +44,4 @@ plugins: strategy: {} test: {} vars: {} -version: 1.5.0 +version: 1.6.0 diff --git a/changelogs/changelog.yaml b/changelogs/changelog.yaml index 0da7015..62ce45b 100644 --- a/changelogs/changelog.yaml +++ b/changelogs/changelog.yaml @@ -119,3 +119,32 @@ releases: - system-baseline-tmux.yml - system-baseline-update-toggle.yml release_date: '2026-11-15' + 1.6.0: + changes: + minor_changes: + - fail2ban - add ``fail2ban_ignoreip``, written as ``ignoreip`` in the ``[DEFAULT]`` + section of ``jail.local`` so it applies to every jail, the service jails included. + The default is Fail2Ban's own (``127.0.0.1/8`` and ``::1``). The first run + after upgrading adds the section and restarts Fail2Ban once. + - sshd - New role. Writes a hardened sshd drop-in selected by a profile (``pve``, + ``ubuntu_lxc``, ``ubuntu_vm``), merged from a baseline, the profile and ``sshd_settings``, + checked with ``sshd -t`` and reloaded through a handler. It refuses to run + when the result would lock SSH out (password login off without public key + login), when the ``pve`` profile does not allow root public-key login or lacks + ``rsa-sha2-512`` (Proxmox VE cluster SSH needs both), and when any profile + allows SHA-1 ``ssh-rsa``. + - 'ufw - ``ufw_rules`` entries accept ``delete`` (a boolean). An entry with + ``delete: true`` removes the rule it describes, so a base rule can be replaced, + for example an open SSH rule by narrower ones. Deletes are applied after every + other rule of the list, a delete entry never satisfies the SSH lock-out guard, + and a rule that the list both adds and deletes fails the play. ``service_rules`` + does not accept the key.' + release_summary: Adds the sshd role. ufw base rules can now delete a rule, so + an open rule can be replaced by narrower ones, and fail2ban gains fail2ban_ignoreip. + Existing behaviour is unchanged unless the new options are used. + fragments: + - 1.6.0.yml + - fail2ban-ignoreip.yml + - sshd-role.yml + - ufw-rule-delete.yml + release_date: '2026-11-15' diff --git a/changelogs/fragments/fail2ban-ignoreip.yml b/changelogs/fragments/fail2ban-ignoreip.yml deleted file mode 100644 index 85baacc..0000000 --- a/changelogs/fragments/fail2ban-ignoreip.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- -minor_changes: - - >- - fail2ban - add ``fail2ban_ignoreip``, written as ``ignoreip`` in the ``[DEFAULT]`` section of ``jail.local`` so it applies to - every jail, the service jails included. The default is Fail2Ban's own (``127.0.0.1/8`` and ``::1``). The first run after - upgrading adds the section and restarts Fail2Ban once. diff --git a/changelogs/fragments/sshd-role.yml b/changelogs/fragments/sshd-role.yml deleted file mode 100644 index 632808b..0000000 --- a/changelogs/fragments/sshd-role.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -minor_changes: - - sshd - New role. Writes a hardened sshd drop-in selected by a profile (``pve``, ``ubuntu_lxc``, ``ubuntu_vm``), - merged from a baseline, the profile and ``sshd_settings``, checked with ``sshd -t`` and reloaded through a handler. - It refuses to run when the result would lock SSH out (password login off without public key login), when the - ``pve`` profile does not allow root public-key login or lacks ``rsa-sha2-512`` (Proxmox VE cluster SSH needs both), - and when any profile allows SHA-1 ``ssh-rsa``. diff --git a/changelogs/fragments/ufw-rule-delete.yml b/changelogs/fragments/ufw-rule-delete.yml deleted file mode 100644 index bbcf989..0000000 --- a/changelogs/fragments/ufw-rule-delete.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -minor_changes: - - >- - ufw - ``ufw_rules`` entries accept ``delete`` (a boolean). An entry with ``delete: true`` removes the rule it describes, - so a base rule can be replaced, for example an open SSH rule by narrower ones. Deletes are applied after every other - rule of the list, a delete entry never satisfies the SSH lock-out guard, and a rule that the list both adds and deletes - fails the play. ``service_rules`` does not accept the key. diff --git a/galaxy.yml b/galaxy.yml index 58db08d..d70a23c 100644 --- a/galaxy.yml +++ b/galaxy.yml @@ -1,7 +1,7 @@ --- namespace: mortis name: kamino -version: 1.5.0 +version: 1.6.0 readme: README.md authors: - Defame1297 -- 2.43.0