Skip to content

Instantly share code, notes, and snippets.

:shipit:
Secretly a squirrel

Bas Mechazawa

:shipit:
Secretly a squirrel
Block or report user

Report or block Mechazawa

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View lazyMap.js
// Example: https://repl.it/repls/WhoppingPotableBoards
function lazyArray(data, func) {
const out = [];
for (let i = 0; i < data.length; i++) {
function set(value) {
delete out[i];
return out[i] = value;
@Mechazawa
Mechazawa / cdp.fish
Created Jun 27, 2017
cd back to project directory
View cdp.fish
function cdp
set old (pwd)
while not test -e .env -o -e .idea -o -e .git
cd ..
if [ '/' = (pwd) ]
cd $old
echo 'Could not descend to a project directory'
return 1
end
@Mechazawa
Mechazawa / uuid.js
Created May 23, 2017
Safe uuid generator using the crypto api if possible
View uuid.js
import StaticClass from './StaticClass';
/**
* UUID util class
* @static
* @protected
*/
export default class Uuid extends StaticClass {
/**
* Generate a UUID4 string
View keybase.md

Keybase proof

I hereby claim:

  • I am Mechazawa on github.
  • I am shodan (https://keybase.io/shodan) on keybase.
  • I have a public key whose fingerprint is DF27 3DDC 10E0 D5C0 5C62 AA8E D24A 9DCD DC84 0F6E

To claim this, I am signing this object:

View ilon.py
import sys
import httplib
import xml.etree.ElementTree as ET
from xml.sax.saxutils import escape
from ftplib import FTP
import re
"""
Terrible code ahead
We found this exploit ages ago. Never found out if anyone else knew
@Mechazawa
Mechazawa / index.html
Created Apr 8, 2014
sierpinski triangles
View index.html
<html>
<head>
<title>Sierpinski triangles in Liquidscript</title>
<script src="triangle.js"></script>
</head>
<body onload="sierpinski(100)">
<canvas id="result" width="800" height="800"></canvas>
</body>
</html>
View pifm.c
// To run:
// wget -O - http://beta.etherpad.org/p/pihackfm/export/txt 2>/dev/null | gcc -lm -std=c99 -g -xc - && time ./a.out
// Access from ARM Running Linux
#define BCM2708_PERI_BASE 0x20000000
#define GPIO_BASE (BCM2708_PERI_BASE + 0x200000) /* GPIO controller */
#include <stdio.h>
#include <string.h>
You can’t perform that action at this time.