Skip to content

Instantly share code, notes, and snippets.

@AzureFlow
AzureFlow / rotateString.js
Created March 24, 2025 03:58
Akamai BMP native (`libakamaibmp.so`) string concealment
const RotateDirection = Object.freeze({
Left: -1,
Right: 1,
});
// Init the ASCII character mapping table (equivalent to the large local_* arrays)
// /** @type {string[]} */
// const charMap = [];
// for(let i = 32; i < 127; i++) {
// // Skip " ' \ \x7F
import WebSocket from "ws";
import {readFileSync} from "node:fs";
import {randomUUID} from "node:crypto";
import {fileURLToPath} from "url";
import ora from "ora";
const __dirname = fileURLToPath(new URL(".", import.meta.url));
const ORBIT_VERSION = "1.2.2";
const USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:133.0) Gecko/20100101 Firefox/133.0";
@AzureFlow
AzureFlow / arkose_mobile_docs.md
Last active December 18, 2024 00:52
Arkose mobile fingerprinting reverse engineering.

Arkose Mobile Info

TL;DR:

  1. Collect Android environment information + (string escape + base64 encode)
  2. Send data to fingerprintData function in WebView via WebView.evaluateJavascript
  3. Forward data sent into the WebView to arkoseEnforcement.dataResponse(dataCollection) in the JavaScript api.js
  4. Emit the event from api.js to enforcement.version_hash.js

Le.emit("data_response", {message: "data_response", data: eventData, key: Jt.config.publicKey});

const { webcrypto: crypto } = require("crypto");
// https://vercel.com/docs/security/attack-challenge-mode
(async () => {
const hostname = "https://vercel-debug-xi.vercel.app";
const _vcrct = await getReqToken();
const solution = await computePOW(_vcrct);
const resp = await postChallenge(hostname, _vcrct, solution);
@AzureFlow
AzureFlow / QueryBuilder.php
Created January 18, 2023 01:30
Simple Wolfram|Alpha client in PHP
<?php declare(strict_types=1);
namespace AzureFlow\WolfApi;
class QueryBuilder
{
private array $parts = [];
public function add(string $key, mixed $value): void
{
@AzureFlow
AzureFlow / twitter-query.php
Last active March 21, 2024 05:49
Get last N tweets from a user.
<?php declare(strict_types=1);
require __DIR__ . '/../vendor/autoload.php';
use GuzzleHttp\Client;
use GuzzleHttp\Exception\GuzzleException;
use GuzzleHttp\RequestOptions;
// ==================== //
@AzureFlow
AzureFlow / Colors.php
Created January 23, 2021 06:43
Easy way to apply colors to console output in PHP
<?php
class Colors
{
public static function getRich(string $string, string $foregroundColor = null, string $backgroundColor = null): string
{
$coloredString = '';
if(!empty($foregroundColor))
{
@AzureFlow
AzureFlow / ChatDrain.php
Created August 22, 2020 02:55
A simple chat downloader for Twitch VODs
<?php
//Get a Client-ID here: https://dev.twitch.tv/docs/v5#getting-a-client-id
define('CLIENT_ID', '<INSERT CLIENT_ID>');
//$blacklistUsers = array('Nightbot', 'StreamElements');
if(isset($argv[1]))
{
$vodURL = $argv[1];
if(filter_var($vodURL, FILTER_VALIDATE_URL))
@AzureFlow
AzureFlow / PreferencesWindow.cs
Created June 27, 2016 21:23
Custom Unity PreferencesWindow
using UnityEngine;
using UnityEditor;
public class PreferencesWindow : EditorWindow
{
private const string WINDOW_NAME = "Preferences"; //Text displayed for the menu and window name
private const string SHORTCUT = CTRL + Shift + "W"; //Shortcut to open the window. Shortcut = Ctrl+Shift+W
private const string MENU_LOCATION = "Window/" + WINDOW_NAME + " " + SHORTCUT; //Location and name of menu item
private Vector2 scrollPos = Vector2.zero;