Repository navigation
Feature/plugins poc 4 - #9113
Feature/plugins poc 4 #9113henryjonathanquispe wants to merge 15 commits into
Conversation
commit b84543b Author: AugustoLopezProcess <augusto.lopez+github@processmaker.com> Date: Tue Apr 21 08:27:15 2026 -0400 Adding plugin admin ui commit ca8a863 Author: Nolan Ehrstrom <github@nolanpro.com> Date: Mon Mar 9 11:01:46 2026 -0700 Add controllers and routes for plugin UI Copied from feature/plugins-poc-vite-ui (just without the vite/Vue3 integration) commit 3cc89bc Merge: 9e9b4aa 5da27ce Author: Nolan Ehrstrom <github@nolanpro.com> Date: Mon Mar 9 10:58:27 2026 -0700 Merge branch 'task/FOUR-28803' into feature/plugins-poc commit 9e9b4aa Author: Nolan Ehrstrom <github@nolanpro.com> Date: Mon Jan 19 12:30:54 2026 -0800 Add install command and cached routes commit 4a5df14 Author: Nolan Ehrstrom <github@nolanpro.com> Date: Wed Dec 10 09:29:20 2025 -0800 Start on plugins
Updating feature/plugins-poc-4 with last changes in develop
FOUR-32722 Some adjustments in plugins installation
…the command: php artisan horizon:terminate
FOUR-32760 After install/enable/disable a plugin, should be executed the command: php artisan horizon:terminate
PR SummaryHigh Risk Overview In parallel, it introduces the cross-project Reviewed by Cursor Bugbot for commit 5bbed5d. Bugbot is set up for automated code reviews on this repo. Configure here. |
| $pluginPath = $pluginDisabledPath; | ||
| } elseif (!is_dir($pluginPath)) { | ||
| throw new RuntimeException("Plugin not found: {$pluginName}"); | ||
| } |
There was a problem hiding this comment.
Plugin name allows path traversal
High Severity
uninstall and toggle join the route {name} onto storage/plugins with no basename or allowlist check. A name of .. resolves to the tenant storage root, so delete or rename can wipe or move the entire storage tree.
Additional Locations (2)
Reviewed by Cursor Bugbot for commit a96f564. Configure here.
|
|
||
| try { | ||
| $zip->extractTo($tmpExtractDir); | ||
| $zip->close(); |
There was a problem hiding this comment.
Zip extract allows path traversal
High Severity
installFromZip calls ZipArchive::extractTo on the uploaded archive without checking entry names. Entries with .. or absolute paths write outside the temp directory as the application user before validation or copy.
Reviewed by Cursor Bugbot for commit a96f564. Configure here.
| // Extend BroadcastManager to our custom implementation that prefixes the channel names with the tenant id. | ||
| $app->extend(BroadcastManager::class, function ($manager, $app) use ($tenant) { | ||
| return new TenantAwareBroadcastManager($app, $tenant->id); | ||
| }); |
There was a problem hiding this comment.
Tenant switch crashes on broadcast extend
High Severity
makeCurrent extends BroadcastManager by constructing TenantAwareBroadcastManager with a tenant id. Those names resolve in ProcessMaker\Multitenancy, and the real class only accepts the app instance. Every tenant switch fatals. BroadcastServiceProvider already installs the tenant-aware manager.
Reviewed by Cursor Bugbot for commit a96f564. Configure here.
| } | ||
| } else { | ||
| $this->logRunning("Plugin {$command} command output:\n\n{$result->output()}", $pluginName, $userId); | ||
| } |
There was a problem hiding this comment.
Failed plugin commands still report success
Medium Severity
runCommand logs {plugin}:install, route:cache, and horizon:terminate failures and returns. Install still calls logDone and the API responds with success, so a failed plugin setup or stale route cache looks like a completed install.
Additional Locations (2)
Reviewed by Cursor Bugbot for commit a96f564. Configure here.
| throw new RuntimeException( | ||
| "Invalid JSON in composer.json at {$composerJsonPath}: " . json_last_error_msg() | ||
| ); | ||
| } |
There was a problem hiding this comment.
Invalid plugin composer.json crashes tenant
High Severity
loadPlugins rethrows on invalid composer.json or a missing PSR-4 path during TenantResolved. One leftover or corrupt folder under storage/plugins then 500s every request for that tenant. PluginManager::list already skips invalid plugins.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit a96f564. Configure here.
…ink, add load screen-builder-form.js files from plugin
…ink, add load screen-builder-form.js files from plugin
…ink, add load screen-builder-form.js files from plugin
…ink, add load screen-builder-form.js files from plugin
|
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
There are 6 total unresolved issues (including 5 from previous reviews).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 5bbed5d. Configure here.







Related Tickets & Packages
Code Review Checklist
ci:deploy