Skip to content

Instantly share code, notes, and snippets.

@balazsorban44
balazsorban44 / apple-gen-secret.mjs
Last active December 31, 2024 23:38
Script to generate Apple Client secret
// This is now built into `npx auth add apple`! :tada:
// https://github.com/nextauthjs/cli/pull/10
#!/bin/node
import { SignJWT } from "jose"
import { createPrivateKey } from "crypto"
if (process.argv.includes("--help") || process.argv.includes("-h")) {
@mimoo
mimoo / recs.md
Created December 31, 2024 23:34
The recommendation list

Humor

  • all the Bo Burnham standups + inside, some of it is genius and it's hard to categorize it as humor. Inside is a masterpiece that has nothing to do with his other stand ups.

Gaming

  • The Last of Us: Part 1
  • Hunt Showdown

Movies

@faustomorales
faustomorales / stabilize.py
Last active December 31, 2024 23:33
Optical Flow Video Stabilization with OpenCV
import cv2
import numpy as np
# Code assumes that the video lives in the following
# folder and is titled video.wmv.
folder_template = 'data/folder/{0}'
# Reset frequency determines how many frames the
# stabilization will track before resetting to the
# identity transform. May switch to using a maximum
# translation, rotation, scale, etc.
@paulmillr
paulmillr / BLS_Signature.md
Last active December 31, 2024 23:31
BLS Signature for Busy People

BLS Signature for Busy People

Summary

  • BLS stands for

    • Barreto-Lynn-Scott: BLS12, a Pairing Friendly Elliptic Curve.
    • Boneh-Lynn-Shacham: A Signature Scheme.
  • Signature Aggregation

  • It is possible to verify n aggregate signatures on the same message with just 2 pairings instead of n+1.

@elsayed85
elsayed85 / imei-eg.sh
Last active December 31, 2024 23:31
Replace 351941237314725 With Your IMEI
curl 'https://api-citizens-prod-imei.gs-ef.com/ceirimeicheck/api/v1/imei/check'
-H 'Host: api-citizens-prod-imei.gs-ef.com'
-H 'Content-Type: application/json'
-H 'Accept: */*'
-H 'Connection: keep-alive'
-H 'Accept-Language: en'
-H 'Content-Length: 34'
-H 'Accept-Encoding: gzip, deflate, br'
-H 'User-Agent: CitizenApp_Ntra/1.0.0 CFNetwork/1568.300.101 Darwin/24.2.0'
--data '{"imeiNumber":["351941237314725"]}'
@f0rki
f0rki / result-type-in.c
Created October 18, 2016 08:32
using something like rust Result in C?
#include <stdbool.h>
#include <stdio.h>
#define DEFINE_RESULT(T, E, NAME) \
typedef struct { \
bool success : 1; \
union { \
T result; \
E error; \
}; \
@pmkay
pmkay / installing-postman.md
Created April 27, 2020 02:49 — forked from ba11b0y/installing-postman.md
Installing Postman on Ubuntu/Gnome

Since Chrome apps are now being deprecated. Download postman from https://dl.pstmn.io/download/latest/linux

Although I highly recommend using a snap

sudo snap install postman

Installing Postman

tar -xzf Postman-linux-x64-5.3.2.tar.gz
@NicolasT
NicolasT / core
Created November 3, 2011 16:34
Haskell fold over list of monadic actions
[1 of 1] Compiling IO ( io.hs, io.o )
8 Lets floated to top level; 0 Lets floated elsewhere; from 11 Lambda groups
8 Lets floated to top level; 0 Lets floated elsewhere; from 8 Lambda groups
Total ticks: 507
107 PreInlineUnconditionally
2 eta_B1
@Pymmdrza
Pymmdrza / R2cloudflare_V1_6.py
Last active December 31, 2024 23:20
R2 Cloudflare Upload file with boto in python
# https://gist.github.com/Pymmdrza/3e3f30b16f4009503e7572b914fd200d
# install package's from requirements.txt
# Windows : pip install -r requirements.txt
# Linux : pip3 install -r requirements.txt
import os
import boto3
from tqdm import tqdm
from colorthon import Colors as Fore
def get_user_input(prompt, example=''):