Skip to content

Release 2.9.4

Latest

Choose a tag to compare

@github-actions github-actions released this 25 Aug 21:08
· 1489 commits to master since this release
c809b13

Upgrading to 2.9.4? The one action for every install is bundle update camaleon_cms; required grants, behaviour changes, and notes for theme/plugin developers are collected in docs/upgrading-to-2.9.4.md. Breaking changes are flagged inline below.

  • Security fix: The bundled front_cache plugin ran Rails.cache.clear on every POST/PATCH, wiping every cache-based counter in the shared store — an attacker could reset the per-IP login brute-force counter with one interleaved frontend POST. Pages are now cached per site under versioned keys (one entry per URL, one-week TTL, any store); invalidation bumps the version and never touches entries the plugin does not own. #1279.

    • Breaking change: the Invalidate the cache instead of deleting it checkbox is removed from the front_cache settings — versioned invalidation is now the only behavior, and a stored invalidate_only value is ignored. PUT and DELETE requests now invalidate the page cache like POST/PATCH; draft autosaves (posts/drafts) no longer invalidate it (a draft is not published content); and the admin Clean cache action also physically purges the site's stored pages.
    • Upgrade notes.
  • Security fix (dependency): Raises the bundled cama_contact_form floor to ~> 0.1.13, which validates the contact-form auto-reply recipient (CF-1): the optional confirmation email previously went to a visitor-controlled address, turning a site into an email relay from its own From address. 0.1.13 also routes the plugin's markup gate through CamaleonCms::UnsafeMarkup and gates its forms shortcode. cama_contact_form#76.

  • Bug fix: The engine no longer force-requires factory_bot_rails nor appends its spec/factories to the application's factory paths — a host app loading the gem from a path/git checkout while defining its own same-named factory (e.g. :site) crashed at boot with FactoryBot::DuplicateDefinitionError. Released-gem installs never received the factories (spec/ is not packaged). #1280.

  • Testing: Specs are now bootstrapped through rails_helper — .rspec uses --require rails_helper, so individual specs no longer require 'rails_helper' — and rails_helper forces RAILS_ENV=test before the app boots, so an exported RAILS_ENV can never point the suite (whose before(:suite) purges every table) at a development or production database. Development-only. #1278.

  • Testing: The contact-form security specs moved to the cama_contact_form plugin, which now has its own camaleon_cms-backed harness and owns the code they exercise; the contact_form_unfiltered_html permission-model spec stays here, where the permission is defined. Development-only; no shipped code changed. #1278 · pairs with cama_contact_form#73.

  • Security fix: Shortcodes in authored content are now gated behind a default-off content_shortcodes role permission. A save carrying a registered shortcode is refused (never sanitized) for a non-admin lacking it, across post content, custom-field values, taxonomy content and widget descriptions. Detection is precise and fails closed; admins, stored content and rendering are unaffected. #1277.

    • Breaking change: a non-administrator role without content_shortcodes can no longer publish shortcode-bearing content on any of those surfaces. Grant the permission (Settings → User Roles → Allow shortcodes in content) to roles that author shortcodes.
    • Upgrade notes.
  • Bug fix: Publishing a post without an explicit date saved it published with a nil published_at — undated, and raising in themes that format the publish date. CamaleonCms::Post now stamps published_at (UTC) when a post becomes published without one; supplied/scheduled dates and already-published posts are untouched, and existing undated posts are not backfilled. #1276.

  • Performance fix: Frontend post listings no longer issue N+1 queries for post metas, categories, post_tags and post-type metas — a Post.with_eager preload scope loads them up front on the listing paths (single-post lookups stay lean), and stale association caches are reset after category/tag mutations. #1275.

Full Changelog: 2.9.3...2.9.4