Abstractly speaking, a hash function and a symmetric cipher are "the same thing". But, concretely, there is a symmetry between Stream cipher: map a fixed-length random input to a variable-length random output Hash function: map a variable-length random input to a fixed-length random output
Basic "while" loop in Elixir
"that's not how you're supposed to use functional programming languages" — how 'bout I do anyway?
Most efficient random integer generator by random bits consumed
Discovered in 2013 by then-UPMC-student Jérémie Lumbroso, and independently re-discovered by an Apple programmer last Fall (with much ado on Twitter and Hacker News), the basic idea is as follows: Take your (infinite) random bitstream as the binary digits of random $r\in\left[0,1\right)$…
Clearing the DNS cache on Ubuntu 20.04
Yeah, lots of people out there saying "leenucks doesn't have a dns cache!!1!" — well, recent versions of Ubuntu do ootb, and just restarting NetworkManager doesn't clear it for some ungodly reason… flush it with sudo systemctl restart systemd-resolved
A very tiny bitmap font
Could be useful for very small LCD displays, or for fitting an entire movie script on your monitor at once. TODO: convert to OpenType Bitmap…
mcomix system-level requirements
Say you don't want sweeping system changes for something idiosynchronous like an unstable build of a comic book viewer…
X25519 original specification
Adapted from the original specification
The "real way" to run X11 apps as another local user
xhost +SI:localuser:$someoneElse
Old-school new-school: Optical Tape Archives
I had come up with this "cursed technique" a while back at work, when I needed to transfer a ~1GB file onto a quite old Linux machine that, for "security reasons" had USB mass storage access as well as the UDF kernel drivers disabled (and I was unable to access it over the network)…
Quick Fix: remove "Mozilla VPN" ads from Firefox Private Browsing window
/* ~/.mozilla/firefox/…/chrome/userContent.css */
/* Remove advertisements for Mozilla VPN */
@-moz-document url(about:privatebrowsing) {
.promo {
display: none;
}
}