Skip to content

Instantly share code, notes, and snippets.

View hryvinskyi's full-sized avatar

Volodymyr Hryvinskyi hryvinskyi

View GitHub Profile
@hryvinskyi
hryvinskyi / README.md
Last active April 14, 2026 15:54
gist-magento-module-quote-246.patch

Fix File Custom Option Processing via REST/SOAP API

Backport of mage-os/mageos-magento2#210 for Magento 2.

Problem

File-type custom options cannot be submitted through the REST/SOAP API when adding products to cart. The CustomOptionProcessor does not handle file_info data from API requests, and there is no validation to prevent file uploads on non-file option types.

What the Patch Does

@hryvinskyi
hryvinskyi / order-monitor.sh
Last active November 5, 2025 11:26
Magento Order Monitor Script
#!/bin/bash
# Order Monitor Script
# Checks if orders have been received within the last 2 hours
# Runs only between 9am and 9pm (7am + 2 hour check period)
# Sends email alerts to specified addresses if no orders found
#
# Usage:
# ./order-monitor.sh [OPTIONS]
#
@hryvinskyi
hryvinskyi / 1 SRI hashes broke magento checkout (Magento 2.4.8-p3, 2.4.7-p8, 2.4.6-p13).md
Last active April 9, 2026 14:32
SRI hashes broke magento checkout (Magento 2.4.8-p3, 2.4.7-p8, 2.4.6-p13)

CSP Storage File Locking Patch

Overview

This patch addresses two critical issues in Magento's Content Security Policy (CSP) module:

  1. Race Condition: Fixes corrupted sri-hashes.json files caused by concurrent write operations during normal storefront operation, which results in malformed JSON and 500 checkout errors.

  2. Minification Support: Ensures that static.min.js and mixins.min.js are correctly loaded and their SRI hashes properly recorded when CSP and SRI are enabled along with JS bundling and minification enabled simultaneously.

Problems

@hryvinskyi
hryvinskyi / CVE-2025-54236_SessionReaper.md
Last active April 11, 2026 18:50
CVE-2025-54236 (SessionReaper) Security Patch

CVE-2025-54236 (SessionReaper) Security Patch

Problem

CVE-2025-54236 (SessionReaper) is a critical unauthenticated Remote Code Execution vulnerability (CVSS 9.1) affecting Magento 2 / Adobe Commerce.

  • Attack Vector: /customer/address_file/upload endpoint
  • Impact: Unauthenticated RCE via Phar deserialization

What the Patch Does