Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • E exo
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 10
    • Issues 10
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 3
    • Merge requests 3
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Xfce
  • exo
  • Issues
  • #85
Closed
Open
Created Jun 01, 2022 by 1g0r S0uz4@gotherlain

Remote code execution trough URI handlers of Browsers

Hello. Its possible redirect a linux xfce user to connect on a remote ftp and execute arbitrary code through .desktop files with 1 click to remote code execution:

  • If the user already have a ftp partition - connected on computer, when they click to open a generic xdg-open, chrome will execute a .desktop file, on all Linux system. ( If you try that on chromium browsers on MacOs, the browser will just download any file, not execute, either behavior we have on Firefox)

  • If the user still not connected on ftp, when xdg-open is accepted, the user will connect to ftp server, when the user click again to open xdg-open, the file .desktop will be automatically executed

steps:

    • On a Linux xfce system (machine 1), you will connect it to a shared ftp server (that will have the malicious .desktop file that hacker uploaded) - simulating the victim computer who have a shared ftp of the business

2.Hacker send the link containing malicious html page to victim

  1. Victim accepts the xdg-open

  2. Automatically the .desktop file will be executed


A lot of apps run through xdg-open , a attacker can make infinity malicious pages to execute the generic xdg-open, that in reality is a arbitrary code on a .desktop file that browsers enable to execute

Please see the Poc:

  • https://youtu.be/v9tjI4JwYG0

on attachments we have the .desktop file and the html file a.desktop

a.html

Thanks!

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking