Skip to content

Instantly share code, notes, and snippets.

program app;
{$IFDEF FPC}{$mode objfpc}{$ENDIF}
uses SysUtils, Classes;
var
t1,t2: TDateTime;
t3,t4: UInt64;
tickspersec: UInt64;
import pyaudio
import numpy as np
import time
import queue
import threading
from collections import deque
import os
import signal
# Frequency range to check for peaks.
unit SNMPParserMIB;
{$mode delphi}
interface
uses Windows, SysUtils, Classes, Generics.Collections,
Generics.Defaults, Math;
type
pTRKnownOID = ^TRKnownOID;
@Alligator-1
Alligator-1 / ureplacefunction.pas
Created April 4, 2025 03:27
function substitution, FPC
unit uReplaceFunction;
{$mode objfpc}
{$asmmode intel}
interface
uses
{$IF DEFINED(MSWINDOWS)}
Windows
{$ELSEIF DEFINED(LINUX)}
@Alligator-1
Alligator-1 / read_mft.ps1
Created February 16, 2025 16:23 — forked from CynicRus/read_mft.ps1
Read Master Fat Table by Powershell > 7
param(
[Parameter(Mandatory=$true)]
[ValidatePattern('^[A-Za-z]$')]
[string]$DriveLetter
)
# Структура загрузочного сектора NTFS
$NTFSBootSectorFormat = @{
JumpInstruction = 0..2
OemID = 3..10
@Alligator-1
Alligator-1 / ldrloaddll_hook.c
Created August 11, 2023 04:06 — forked from bats3c/ldrloaddll_hook.c
Hook LdrLoadDll to whitelist DLLs being loaded into a process
#include <stdio.h>
#include <windows.h>
#include <winternl.h>
#define dwAllowDllCount 1
CHAR cAllowDlls[dwAllowDllCount][MAX_PATH] = {
"W:\\allowed.dll"
};
VOID HookLoadDll(LPVOID lpAddr);
@Alligator-1
Alligator-1 / bookmarks_from_sql.py
Created December 15, 2021 02:12 — forked from iafisher/bookmarks_from_sql.py
Programmatically access your Firefox bookmarks
"""
A script to automatically export bookmarks from Firefox's SQLite database.
There does not seem to be a programmatic way to get Firefox to export its bookmarks in
the conventional HTML format. However, you can access the bookmark information directly
in Firefox's internal database, which is what this script does.
Always be careful when working with the internal database! If you delete data, you will
likely not be able to recover it.