Skip to content

Instantly share code, notes, and snippets.

View Zemnmez's full-sized avatar
💭
oof

Thomas Neil James Shadwell Zemnmez

💭
oof
View GitHub Profile
eval(String.fromCharCode(
(8
*
eval(String.fromCharCode(
(8
*
eval(String.fromCharCode(
(5 *
5*4+1 ),2*(
2*(7*4+1) +1),(8*6*
2+1),9*6*2,8 *5,(2*(8*5+1)
+1),4*(7*4+1),6* (9*2+1),7*5*3,5
*2*(5*2+1),(6*(8* 2+1)+1),2*(2*(5*
2+1)+1),6*(8*2+1) ,6*(9*2+1),3*(9*4
+1),(9*6*2+1),(6* (5*2+1)+1),8*(6*2
+1),(8*6*2+1),6* (9*2+1),(6*(5*2+
@Zemnmez
Zemnmez / tweetdeck-limit-override-dm-rt-fix.js
Last active March 13, 2023 15:21
tweetdeck-limit-override.js
/*
This snippet is esssentially the same as being in the Twitter longer tweets test, for tweetdeck.
The Tweet length counter is fixed by tricking TweetDeck into counting up to 140 characters, twice, so you'll see 140
instead of 280 in the counter but going over 140 will give you another set of 140 charactrs.
*/
TD.services.TwitterClient.prototype.makeTwitterCall=function(b,e,f,g,c,d,h){c=c||function(){};d=d||function(){};b=this.request(b,{method:f,params:Object.assign(e,{weighted_character_count:!0}),processor:g,feedType:h});return b.addCallbacks(function(a){c(a.data)},function(a){d(a.req,"",a.msg,a.req.errors)}),b};
twttrTxt=Object.assign({},twttr.txt,{isInvalidTweet:function(){return!1},getTweetLength:function(x){return x=twttr.txt.getTweetLength.apply(this,arguments),x<140||x/140>2?x:x%140}});
@Zemnmez
Zemnmez / qr.js
Last active January 2, 2019 13:44
function byid(id) {
return document.getElementById(id);
}
function valof(id) {
return byid(id).checked ? 1 : 0;
}
function text(e) {
if (e == null) {
return "";
}
window.theImage = () => {
const u = byid("url").value,
i = img,
c = valof("control"),
r = valof("rand"),
d = valof("data"),
t = valof("dither"),
s = Math.floor(Math.random()*1e9),
o = rotation,
x = dx
@Zemnmez
Zemnmez / variadic-curry-golfed.js
Last active February 20, 2019 16:50
variadic curry, javascript
z=f=>(...a)=>+a!=0?z(f.bind(0,...a)):f()
@Zemnmez
Zemnmez / Makefile
Created February 24, 2019 22:47
makefile for golang aws lambda
# expect handler/handlername handler/handler2 etc.
dist.zip: $(patsubst handler/%,dist/%,$(wildcard handler/*))
zip -FSj $@ $^
#getDeps = $(shell go list -f '{{.Deps}}' $(1) | xargs go list -f '{{$$this:=.}}{{range .GoFiles}}{{$$this.Dir}}/{{.}} {{end}}')
# maybe one day i will generate the deps dynamically lol
# must be forced because cant determine whether update is
# needed purely based on go files
dist/%: handler/% .FORCE
@Zemnmez
Zemnmez / authy_extract.md
Last active December 18, 2022 17:49 — forked from tresni/gist:83b9181588c7393f6853
Authy OTP 2FA Extractor (authy to 1password, google authenticator etc)

Authy OTP 2FA Extractor

Inspired by the original gist.

This snippet will extract all the OTP (2FA) keys from Authy, and convert them to scannable QR codes and URLs you can copy-paste into e.g. 1password. Unlike other approaches, this consumes the internal digits record, making it compatible with authy-specific extra long 2FA codes.

Usage

  1. Install the Authy Chrome Extension and the Authy App.
  2. Open the authy app from the browser icon in the top right, and view some TOTP codes. This decrypts them so we can extract them.
  3. Visit the Chrome Inspector Page (chrome://inspect/#apps) and click 'inspect' under 'Authy'. If that's not there, you likely need to open the Authy app from chrome://apps/.
  4. In the window
String.fromCharCode(($=2*5),(q=(2*6+1)*5),(a=4*8),(Â=(2*9+1)*6),(Y=4*5*5+1),($+1)*9,(y=(2*6+1)
*9),Â,Â,Y,($+1)*$,(È=(4*7+1)*4),a,($+1)*$,Y,y,Â,(E=2*6*8+1),(K=2*6*9),a,($+1)*$,Y,È,
(À=(2*8+1)*7),(Ê=(4*9+1)*3),Â,(G=2*6*9-1),a,(e=5*8),((c=5*8+1))*2,(s=(2*6+1)*6),s,c,
a,(S=3*5*7),(Æ=(3*8-1)*5),a,E,a,($+1)*9,K,E,Æ,Æ,a,Ê,(º=(2*8+1)*6),a,E,Â,È,S,º,S,($+1
)*9,S,E,K,a,($+1)*$,Y,y,Â,E,K,a,($+1)*$,Y,È,À,Ê,Â,G,a,À,(w=(2*6+1)*8),Y,Â,Y,a,($+1)*
9,Ê,($+1)*$,($+1)*$,Y,($+1)*9,È,S,Ê,($+1)*$,Æ,a,(M=2*7*7),Y,È,À,Y,Y,($+1)*$,a,($+1)*
$,Ê,(_=4*5*5),Y,Æ,a,º,Ê,Â,(I=2*6*9+1),a,E,a,_,S,Â,Y,($+1)*9,È,Y,_,a,(µ=(2*8+1)*6+1),
Â,E,(Q=2*7*8),w,a,E,K,Ê,($+1)*$,µ,a,E,a,È,Y,I,Q,Ê,Â,E,K,a,Æ,Y,(O=2*7*8+1),y,Y,($+1)*
$,($+1)*9,Y,(Ä=(3*8-1)*2),a,(C=2*6*7),w,S,Æ,a,E,K,K,Ê,À,Æ,a,S,È,a,È,Ê,a,Y,(W=3*5*8),
w,S,M,S,È,a,È,Y,I,Q,Ê,Â,E,K,a,_,(U=3*5*8+1),($+1)*$,E,I,S,($+1)*9,a,M,Y,w,E,($*6-1)*