54 lines · 1.8 KB · Python
RawDownload
# ------------------------------------------------------------# name      Fuzzbunch# type      exploit# cve       —# year      unknown# os        Windows# authors   unknown# source    RamadhanAmizudin/malware# archived  RamadhanAmizudin, krisyotam (2026)# notes     —# ------------------------------------------------------------ import dszimport traceback, sysfrom optparse import OptionParserfrom collections import defaultdictimport reimport ops.cmdfrom ops.pprint import pprint def main():    process_list = []    if (len(sys.argv) > 1):        pattern = (('.*' + sys.argv[1]) + '.*')    else:        pattern = '.*'    print (('\nFiltering processes with regex:: ' + pattern) + '\n')    regex = re.compile(pattern, (re.I | re.UNICODE))    dsz.control.echo.Off()    cmd = ops.cmd.getDszCommand('processes -list')    proc_items = cmd.execute()    if cmd.success:        for proc_item in proc_items.initialprocesslistitem.processitem:            pid = str(proc_item.id)            ppid = str(proc_item.parentid)            name = str(proc_item.name.encode('utf-8'))            path = str(proc_item.path.encode('utf-8'))            user = str(proc_item.user.encode('utf-8'))            c_time = str(proc_item.created.time)            c_date = str(proc_item.created.date)            process = [pid, ppid, path, name, user, c_date, c_time]            if regex:                tmp_str = ' '.join(process)                if re.search(regex, tmp_str):                    process_list.append(process)    if (process_list > 1):        pprint(process_list, header=['PID', 'PPID', 'Path', 'Name', 'User', 'CDate', 'CTime'])    dsz.control.echo.On()if (__name__ == '__main__'):    usage = 'psg [regex]\n\t\t\t'    try:        main()    except RuntimeError as ex:        dsz.ui.Echo(('\n RuntimeError Occured: %s' % e), dsz.ERROR)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t