PrestaShop

Tip

AWS हैकिंग सीखें और अभ्यास करें:HackTricks Training AWS Red Team Expert (ARTE)
GCP हैकिंग सीखें और अभ्यास करें: HackTricks Training GCP Red Team Expert (GRTE) Azure हैकिंग सीखें और अभ्यास करें: HackTricks Training Azure Red Team Expert (AzRTE)

HackTricks का समर्थन करें

From XSS to RCE

  • PrestaXSRF: PrestaShop के लिए एक Exploitation Script जो XSS को RCE या अन्य Critical Vulnerabilities तक बढ़ा देता है। For more info check this post. यह PrestaShop Versions 8.X.X और 1.7.X.X के लिए support प्रदान करता है, और allow करता है:
  • (RCE) PSUploadModule(); - Upload a custom Module: PrestaShop में एक Persistent Module (backdoor) अपलोड करें।

ps_checkout ExpressCheckout silent login account takeover (CVE-2025-61922)

ps_checkout मॉड्यूल < 5.0.5 में identity validation की कमी एक unauthenticated attacker को उनका email प्रदान करके किसी भी customer का session switch करने देती है।

  • Endpoint (unauth): POST /module/ps_checkout/ExpressCheckout.
  • Flow: ExpressCheckout.php attacker JSON स्वीकार करता है, केवल orderID की जाँच करता है, ExpressCheckoutRequest बनाता है और ExpressCheckoutAction::execute() को कॉल करता है।
  • Auth bug: कमजोर वर्ज़न में ExpressCheckoutAction जब कोई user logged in नहीं होता तो CustomerAuthenticationAction::execute() को कॉल करता है। वह method बस customerExists(<payer_email>) और context->updateCustomer(new Customer($id)) करता है, तो email existence == login (कोई password/token जाँच नहीं).
  • Attacker-controlled email field: order.payer.email_address JSON payload के अंदर ExpressCheckoutRequest::getPayerEmail() द्वारा पढ़ा जाता है।

Exploitation steps

  1. किसी भी registered customer का email इकट्ठा करें (admin अलग है और इस flow से प्रभावित नहीं है)।
  2. controller को एक unauthenticated POST भेजें जिसमें orderID और victim का email order.payer.email_address में हो।
  3. भले ही endpoint 500 लौटाए, response में victim के customer context के लिए cookies शामिल होंगी (session पहले ही स्विच हो चुका होगा), जो PII तक पहुँच या saved cards से खरीदारी को संभव बनाती हैं।
POST /module/ps_checkout/ExpressCheckout HTTP/1.1
Host: `<target>`
Content-Type: application/json
Content-Length: 72

{"orderID":"1","order":{"payer":{"email_address":"victim@example.com"}}}

संदर्भ

Tip

AWS हैकिंग सीखें और अभ्यास करें:HackTricks Training AWS Red Team Expert (ARTE)
GCP हैकिंग सीखें और अभ्यास करें: HackTricks Training GCP Red Team Expert (GRTE) Azure हैकिंग सीखें और अभ्यास करें: HackTricks Training Azure Red Team Expert (AzRTE)

HackTricks का समर्थन करें