feat(upgrade): integrate UpgradeMODX functionality into core - #71
Open
Ibochkarev wants to merge 3 commits into
Open
feat(upgrade): integrate UpgradeMODX functionality into core#71Ibochkarev wants to merge 3 commits into
Ibochkarev wants to merge 3 commits into
Conversation
- Add SoftwareUpdate/UpgradeCore processor for one-button MODX upgrade - Add Upgrade MODX and Download buttons to dashboard updates widget - Add updates badge in manager navbar when MODX or Extras updates available - Show Extras package names in dashboard widget when updates available - Add system settings: core_upgrade_temp_dir, core_upgrade_allowed_groups, core_upgrade_force_pcl_zip - Add unit tests for UpgradeCore validation Resolves modxcms#13715, modxcms#16660, modxcms#14182
- Change permission for UpgradeCore processor to 'upgrade_core' - Add checksum verification for downloaded upgrade packages - Implement path traversal protection during zip extraction - Add unit tests for permission checks and error handling in UpgradeCore - Update lexicon entries for new permissions and error messages
Use a unique work directory, ZipArchive-only safe extract, HTTPS plus required SHA-256, flock, site_url redirect, and require upgrade_core without group bypass.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Что сделано
Добавляет апгрейд ядра в один клик из Manager: скачивает пакет из Sentinel, верифицирует SHA-256 через HTTPS, распаковывает с проверками путей ZipArchive, копирует файлы (пропускает
config.inc.php), затем редиректит на setup. Виджет Dashboard Updates и бейдж header показывают апдейты ядра и Extras.Зачем нужно
modxcms#13715 / modxcms#16660 просят путь апгрейда из менеджера вместо FTP плюс экстра UpgradeMODX. modxcms#14182 просит показывать апдейты Extras на дашборде.
Как проверить
upgrade_core(и Administrator, если группы заданы) открывает виджет Updatescomposer test -- --filter UpgradeCoreTestСвязанные
Refs modxcms#13715
Refs modxcms#16660
Refs modxcms#14182
Оригинал: modxcms#16856