Commit Graph
6537 Commits
Author SHA1 Message Date
renovate[bot] 19a74b2383 Update php tool constraint to 8.5.* (#3843)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-06-28 07:14:41 +01:00
renovate[bot] 9acfb4a859 Update symfony packages to v7.4.14 2026-06-28 02:34:19 +00:00
renovate[bot] 42390a42d1 Update dependency autoprefixer to v10.5.2 (#3841)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-06-27 03:19:12 +01:00
Adam Daley 48c33a2d31 Add Stripe subscription support via Setup Intents and webhooks (#3455)
Introduces comprehensive recurring payment support to the Stripe payment
gateway using Stripe Setup Intents, Subscriptions, and webhook events.

Key changes:
- Add supports_subscriptions capability and webhook_secret config fields
- Generate subscription forms using Setup Intents + Stripe Elements
- Process subscription setup via Setup Intent redirect callback
- Handle subscription lifecycle via webhooks (created/updated/deleted)
- Handle recurring payments via invoice.payment_succeeded webhook
- Verify webhook signatures using Stripe signing secret
- Generate renewal invoices for recurring subscription payments
- Support JSON webhook payloads in ipn.php (skip_validation)

Security:
- Webhook signature verification via Stripe\Webhook::constructEvent()
- XSS-safe escaping of buyer name/email in subscription form HTML

Follows existing patterns from PayPal adapter and incorporates all
recent Stripe improvements (claimForProcessing, invoice approval,
deposit-type checks, Model_Transaction status constants).

Ref: #2828
2026-06-27 02:46:06 +01:00
renovate[bot] 472a940b78 Update phpmyadmin:5 Docker digest to 3c57518 2026-06-26 23:28:37 +00:00
renovate[bot] 5de3a7eeae Update actions/cache digest to 55cc834 2026-06-26 23:15:45 +00:00
Adam DaleyandCopilot Autofix powered by AI 7100e81bb2 Mask server manager credentials in API and admin UI (#3840)
* Mask server manager credentials in API and admin UI

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-26 22:57:35 +01:00
Adam Daley 1e958fc3b9 Migrate document fields to custom client fields (#3839)
* Migrate document fields to custom client fields

* Add 'unmigrated' to cspell dictionary

* Bump last_patch version to 75
2026-06-26 21:35:45 +01:00
Yağızhan Burak Yakar 52e49c431d Make patch 45 check if column exists before dropping it (#3838) 2026-06-26 14:40:11 +03:00
renovate[bot] f1915b60aa Update dependency pestphp/pest to v4.7.4 2026-06-26 02:09:21 +00:00
Yağızhan Burak Yakar d189ee468e Knowledge base, canned responses and helpdesk enhancements (#3808)
* Migrate the knowledge base to Doctrine

* Addressed code review comments

* Move incrementViews to the repo

* Knowledge base suggestions in support forms

* Improve the UI and make search actually search

* Make the knowledge base enabled on new installs by default

* Redid the kb index to list articles alongside categories

* Display articles in admin manage category

* Redirect authenticated users from guest ticket page to client ticket page

* Address code review comments

* Addressed code review comments

* Improved search accuracy by tokenizing queries

* Updated article layout and added CTAs

* Added a setting to toggle view count's visibility

* Removed contact button from the sidebar

* Migrate canned responses to Doctrine and improve admin UI

* Improved support settings canned dropdowns

* Added a flag to hide view count when serializing

* Improved search query matching

* Migrate SupportHelpdesk to Doctrine

* Fixed tests

* Update copyright headers

* Implemented suggestions (credit @admdly)

* Remove dead test
2026-06-25 23:35:28 +03:00
renovate[bot] 9024c2c376 Lock file maintenance 2026-06-25 17:54:05 +00:00
renovate[bot] 4b65ef7569 Update dependency friendsofphp/php-cs-fixer to v3.95.11 2026-06-25 15:46:44 +00:00
renovate[bot] 7fb4a34199 Update release-drafter/release-drafter digest to 4d75298 2026-06-25 14:51:31 +00:00
renovate[bot] b80b0d60e2 Update dependency stripe/stripe-php to v20.3.0 (#3835) 2026-06-25 16:45:32 +02:00
renovate[bot] 32f6a76ddf Update phpmyadmin:5 Docker digest to b16dc88 2026-06-25 00:50:40 +00:00
renovate[bot] 78d4e647a5 Update dependency autoprefixer to v10.5.1 (#3834) 2026-06-24 14:18:11 +02:00
renovate[bot] 2cbc4f047b Update phpmyadmin:5 Docker digest to 9a89e66 2026-06-24 10:46:02 +00:00
Adam DaleyandClaude Sonnet 4.6 17b121ca51 fix(Servicedomain): require_once registrar adapter file before class_exists check (#3832)
* fix(Servicedomain): require_once registrar adapter file before class_exists check

Third-party registrar adapters uploaded after installation are absent from
Composer's static class map (generated with --optimize-autoloader), causing
class_exists() to return false even when the file is present on disk.

Mirror the pattern used by Payment adapters in ServicePayGateway: require_once
the adapter file when the class is not yet loaded, then re-check class_exists
to keep a clear error for adapters that define no class.

Fixes #3828

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017mCNdqXfyuD2n1bjFK5zsv

* fix: require_once adapter/manager files before class_exists checks

Payment adapters, server managers, and the server_manager DI factory all
relied on Composer's classmap for dynamic class resolution. With
--optimize-autoloader the classmap is static, so third-party files dropped
into src/library/ after installation are invisible to class_exists().

AntLoader (removed in #3776) previously discovered these files on the fly;
this commit restores equivalent behaviour by requiring files explicitly:

- ServicePayGateway::getAdapterClassName() now checks both nested-dir and
  flat file formats before falling back, replacing the blind `include`
- Servicehosting/Service::getServerManagerConfig() require_onces the
  manager file before calling is_callable() so the class is guaranteed
  present; Server_ has no PSR-0 entry so this also fixes non-optimised builds
- di.php server_manager factory require_oncess the manager file when the
  class is absent from the classmap (adds Path import accordingly)

Registrar adapter loading was fixed separately in the prior commit.

Related to #3828

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017mCNdqXfyuD2n1bjFK5zsv

* fix: address code-review findings on adapter/manager class loading

- Servicehosting getServerManagerConfig: wrap require_once in try/catch
  so a PHP parse error in a manager file returns [] instead of fataling
  the entire manager-list API call (restores old is_callable() behaviour)

- di.php server_manager factory: replace file_exists() with Symfony
  Filesystem::exists() per CLAUDE.md convention; extract the repeated
  ucfirst((string) $manager) call to a local $managerName variable; add
  Filesystem use-import alongside the existing Path import

- composer.json: add Server_ to the psr-0 autoload entries alongside
  Payment_ and Registrar_, giving server managers the same architectural
  treatment and making the require_once guards defensive fallbacks rather
  than the only load path

- ServicePayGateway getAdapterConfig: remove the redundant filesystem
  existence re-checks (lines 386-390) that duplicated what
  getAdapterClassName() just did; collapse into a single class_exists()
  guard with the user-facing :adapter placeholder message

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017mCNdqXfyuD2n1bjFK5zsv

* fix(tests): update ServicePayGateway tests to match refactored getAdapterConfig

After refactoring getAdapterConfig() to delegate filesystem lookups to
getAdapterClassName(), the tests were failing because:
- Three tests had atLeast()->once() expectations on filesystem->exists()
  that the method no longer calls directly
- One test expected an error message with the full class name, but the
  refactored code uses $pg->gateway (the gateway code) in the message

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017mCNdqXfyuD2n1bjFK5zsv

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-06-24 00:16:11 +02:00
renovate[bot] 2e5049fa6b Update actions/cache action to v6 (#3831)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-06-23 19:55:47 +02:00
Adam DaleyandClaude Sonnet 4.6 aefaa01db6 Preserve < and > in ticket/KB messages by using Markdown-safe sanitization (#3830)
* fix(support): preserve < and > in ticket/KB messages by using Markdown-safe sanitization

The WYSIWYG editor (CKEditor) uses the Markdown plugin, so ticket replies
and KB article bodies are stored as Markdown, not HTML. Calling the Symfony
HTML Sanitizer on Markdown content silently corrupts it: when a user types
text containing an unknown tag-like string such as `<World>`, the sanitizer
treats it as an unknown HTML element, drops it, and—because there is no
closing tag—also drops everything that follows, causing the rest of the
message to disappear.

Fix by introducing `Tools::sanitizeMarkdownContent()`, which only strips
null bytes and trims whitespace. XSS protection is already provided at
render time by the `|markdown_to_html` Twig filter, whose underlying
CommonMark converter is configured with `html_input: escape`—any raw HTML
inside the stored Markdown is therefore escaped before it reaches the
browser.

Affected endpoints (all now use the new helper):
- Admin: ticket_reply, ticket_create, kb_article_create, kb_article_update
- Client: ticket_create, ticket_reply
- Guest: ticket_create, ticket_reply

Fixes #3827

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LBnxaZxj968uFFbgoSocLZ

* fix(spellcheck): use American English spelling "unrecognized"

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LBnxaZxj968uFFbgoSocLZ

* fix(support): apply markdown-body styling to admin ticket and client KB article views

The admin ticket conversation and client KB article content were rendered
with |markdown_to_html but without the markdown.css stylesheet or the
markdown-body CSS class required by github-markdown-css.  This caused
inline code, fenced code blocks, and other Markdown elements to appear
unstyled (admin) or miscontainerised in a list-group div (client KB).

- Admin ticket: load markdown.css in <head> and wrap message content in
  <article class="markdown-body bg-transparent text-reset">
- Client KB article: load markdown.css in <head> and replace the
  list-group wrapper with <article class="markdown-body bg-transparent
  text-reset">

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LBnxaZxj968uFFbgoSocLZ

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-06-23 19:22:41 +02:00
FOSSBilling BotandFOSSBilling Bot 06ecf3c5ab Apply PHP Code Styling & Quality Changes (#3829)
Co-authored-by: FOSSBilling Bot <fossbilling-bot>
2026-06-23 17:24:18 +02:00
renovate[bot] 22ee317f9c Update dependency rector/rector to v2.5.2 2026-06-22 23:20:09 +00:00
renovate[bot]andAdam Daley 632fdff66d Lock file maintenance (#3823)
* Lock file maintenance

* Fix browserslist lockfile regression (#3826)

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
2026-06-22 20:51:55 +02:00
renovate[bot] 3b235e0908 Update dependency rector/rector to v2.5.1 2026-06-22 01:15:30 +00:00
Adam DaleyandClaude Sonnet 4.6 ed89bf3731 Fix MySQL 8.0.22+ REGEXP charset conflict in patches 67 and 74 (#3822)
* Fix MySQL 8.0.22+ REGEXP charset conflict in patches 67 and 74

MySQL 8.0.22+ changed the REGEXP implementation to use ICU internals,
which rejects operands with mismatched character sets. Using `BINARY hash`
(producing binary charset) alongside a pattern literal with the session
charset (e.g. utf8mb3_general_ci) triggers:

  SQLSTATE[HY000]: General error: 3995 Character set 'binary' cannot be
  used in conjunction with 'utf8mb3_general_ci' in call to regexp_like.

Replace `BINARY hash NOT REGEXP '^[a-f0-9]+$'` in both patches with
`CAST(hash AS BINARY) NOT REGEXP _binary'^[a-f0-9]+$'`, making both
operands explicitly binary. This preserves the original case-sensitive
matching behaviour while being compatible with MySQL 8.0+ and MariaDB.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PNZCQ7v3gm6fc6t98TyZGP

* Fix invoice hash regexp charset handling

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-06-21 18:49:00 +02:00
renovate[bot] 6ae4bc131c Update dependency rector/rector to v2.5.0 (#3814)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-06-21 16:39:39 +03:00
Yağızhan Burak Yakar ce696d1871 Added a country code selector and number formatter (#3812)
* Added a country code selector and number formatter

* Added parantheses

* Fixed Cypress tests

* Fixed Cypress tests
2026-06-20 18:52:12 +02:00
3b2ca2a92b Apply PHP Code Styling & Quality Changes (#3811)
* Apply PHP Code Styling & Quality Changes

* Fix docblock return type to float

---------

Co-authored-by: FOSSBilling Bot <fossbilling-bot>
Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
0.8.3
2026-06-20 00:49:01 +01:00
renovate[bot] 838567edd5 Lock file maintenance 2026-06-19 22:11:35 +00:00
Adam DaleyandCopilot Autofix powered by AI 32e9896af7 Fixes for 3 code quality findings in Invoice tests (#3810)
* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
2026-06-19 23:03:41 +01:00
Adam DaleyandCopilot Autofix powered by AI 682c85d880 Fixes for 2 code quality findings (#3809)
* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
2026-06-19 22:42:46 +01:00
Adam Daley 0f29d0794e Add invoice hash self-healing and patch backfill (#3807)
* Add invoice hash self-healing and patch backfill

* Simplify invoice-hash comments and update test

* Update last_patch to 74

* Fix invoice hash backfill case matching
2026-06-19 22:08:34 +01:00
renovate[bot] cf547d76b1 Update composer:2 Docker digest to 7725eb4 2026-06-19 19:47:52 +00:00
dependabot[bot] a9a2b043b9 Bump guzzlehttp/psr7 from 2.11.0 to 2.12.1 in the composer group across 1 directory (#3806)
Bump guzzlehttp/psr7 in the composer group across 1 directory

Bumps the composer group with 1 update in the / directory: [guzzlehttp/psr7](https://github.com/guzzle/psr7).


Updates `guzzlehttp/psr7` from 2.11.0 to 2.12.1
- [Release notes](https://github.com/guzzle/psr7/releases)
- [Changelog](https://github.com/guzzle/psr7/blob/2.12/CHANGELOG.md)
- [Commits](https://github.com/guzzle/psr7/compare/2.11.0...2.12.1)

---
updated-dependencies:
- dependency-name: guzzlehttp/psr7
  dependency-version: 2.12.1
  dependency-type: indirect
  dependency-group: composer
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-19 20:47:05 +01:00
renovate[bot] 9d2e9cf387 Update dependency friendsofphp/php-cs-fixer to v3.95.10 2026-06-19 18:04:11 +00:00
Yağızhan Burak YakarandAdam Daley 7ade5bbdf3 Unify public tickets with client tickets (#3799)
* Merge public ticket logic into regular client tickets

* Unified email templates

* Unified events and listeners

* Remove passthrough service methods

* Corrected phpDocs

* Create a combined `author` array to replace `client`, `client_id`, `author_name`, `author_email`

* Switch to using "Author" instead of "Requester"

* Switch to using a single endpoint and single template for client and guest tickets

Also left a redirect behind to make sure previously sent emails still have a working link

* Add author_role parameter to onBeforeClientOpenTicket

* Adjusted rate limit ordering

* Update Twig templates and the update patcher

* "Public ticket" -> "Guest ticket"

* Addressed code review comments

* Address code review comments

* Also purge old pticket email templates

* Fix email sending

* Support: enforce auth, fix guest email links

* Migrate mod_support config key name

---------

Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
2026-06-19 19:01:52 +01:00
Adam Daley f39fd44f0f Add is_cron flag and limit cron-admin fallback (#3805)
* Add `is_cron` flag and limit cron-admin fallback

* Restore cron context after cron runs

* Fix cron context restoration test
2026-06-19 11:50:14 +01:00
renovate[bot] 7a5a2f057b Update actions/checkout action to v7 (#3804) 2026-06-18 18:51:50 +01:00
Adam Daley febec281a6 Migrate product models and enhance promo redemption functionality (#3587)
* Migrate product models; add `promo_redemption`

* Add DomainPricing & ProductOrder repositories

* Use Promo entity typehints and update tests

* Use DI logger, validate order config, update tests

* Replace `error_log` with logger; use stubs in tests

* Use attachOrderConfig and tighten service checks

* Clarify domain defaults and remove deprecated doc tag

* Add missing indexes to `promo_redemption` table

* Enrich promo API arrays and add redemption filters

* Various UI/JS fixes and template cleanups

* Log invoice issues as warnings; expose form_id

* Normalize spelling in UpdatePatcher comment

* Remove checkLimits production method and clean up stale test mocks

* Use getConfig() and add promo permission

* Use container logger directly, remove helpers

* Use defaults for optional Twig settings

* Import macro_functions into admin template

* Compensate promo redemptions on checkout failure

* 🐛 Fix product category and add-on availability handling
2026-06-18 17:56:14 +01:00
Adam DaleyandCopilot Autofix powered by AI 0d6c34137c Fixes for 4 code quality findings in Invoice module (#3803)
* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

* Apply suggested fix to src/modules/Invoice/tests/Unit/ServiceTest.php from Copilot Autofix

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
2026-06-18 17:16:05 +01:00
FOSSBilling BotandFOSSBilling Bot 5a43315fe8 Apply PHP Code Styling & Quality Changes (#3802)
Co-authored-by: FOSSBilling Bot <fossbilling-bot>
2026-06-18 16:47:19 +01:00
Adam Daley f47617c7ae Enhance registrar, email, staff, domain features and pagination (#3801)
* Enhance registrar, email, staff, domain, pagination

* Validate Reply-To and improve domain error message

* Use auth isAdminLoggedIn instead of exception
2026-06-18 15:49:39 +01:00
c7f43acac7 Use fb_api_link instead of custom event listeners in Huraga (#3794)
* Use fb_api_link rather than custom event listeners in Huraga

* API.js: Fall back to window.prompt when Modals isn't present in the theme

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-18 05:36:16 +01:00
renovate[bot] 986b044bdd Update dependency rector/rector to v2.4.6 2026-06-18 04:03:53 +00:00
59a24d7714 Replace Coloris with native input type="color" (#3795)
* Replace Coloris with native `input type="color"`

* Fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-18 05:02:55 +01:00
Yağızhan Burak YakarandAdam Daley 9142057d42 Removed dead code & Code refactoring (#3796)
* Replace hardcoded recurrent pricing rows with a loop

* Replace long if chain with a Twig map

* Remove unnecessary uninstall method for Branding

* Remove dead `createServicePlan` method in Plesk adapter

* Make setDi() disallow passing null

This would actually match what's expected in InjectionAwareInterface.

---------

Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
2026-06-18 04:49:36 +01:00
Yağızhan Burak YakarandAdam Daley f3673742f8 Improve Huraga pagination to automatically redirect to the correct tab (#3797)
* huraga: Automatically display linked tab

* huraga: Accept a `hash` value in pagination partial

* Use hash-based tab behavior rather than local workarounds

---------

Co-authored-by: Adam Daley <admdly@users.noreply.github.com>
2026-06-18 04:40:51 +01:00
renovate[bot] 687075defc Update docker/dockerfile Docker tag to v1.25 (#3798)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-06-18 04:27:27 +01:00
renovate[bot] 8204943419 Update dependency friendsofphp/php-cs-fixer to v3.95.8 2026-06-17 16:18:49 +00:00