HNHacker News
TopNewBestAskShowJobs

a1k0n

1,974 karma · joined March 9, 2007

the obfuscated C donut guy.

https://www.a1k0n.net/

submissionscomments
a1k0n··on Microcorruption – Embedded Security CTF
I wonder: Did Square/Matasano end up hiring many people from this? It was a super fun challenge either way...
a1k0n··on LinkedIn called me a white supremacist because I happen to share a name with one
I'm glad you mentioned that, because I had just turned it to "No" while reviewing that page. Now I'm confused.
a1k0n··on Setting Up a Deep Learning Machine from Scratch
That would be pretty impressive, considering the only data structure included in scratch is a list, and it's pretty cumbersome to address.
a1k0n··on SolveSpace – Parametric 2d/3d CAD
How does this compare to OpenSCAD?
a1k0n··on Reversing the Petya ransomware with constraint solvers
That's right, I was, but on further reflection you don't need to do anything special in this case since it's just doing 32 bit math, not 32 bit addressing. EAX/EBX/etc should just work in real mode IIRC.
a1k0n··on An integer formula for Fibonacci numbers
ΣnFib(n+2)x^(n+2) is F(x)−x−1 because it's an infinite series of powers of x, except since it's x^(n+2) then x^1 (x) and x^0 (1) never appear, so you need to subtract them from F(x) which is ΣnFib(n)x^n. I hope that's clear and explains the rest.
a1k0n··on Reversing the Petya ransomware with constraint solvers
You don't even need to be in protected mode to use 32-bit registers. You can sort of bounce in and out just enough to use them with the 66 prefix. I used to do that but it's been so long I forgot how.
a1k0n··on AlphaGo beats Lee Sedol again in match 2 of 5
Usually it's because as it searches the move tree, it finds ways for the opponent to maximize their own winning probability and so has to hedge against that. In minimax games sometimes the evaluator finds a long chain of moves that leads to a win, and once it finds that, doesn't necessarily bother trying to find a shorter one. It can be frustrating to tune that out.
a1k0n··on 100 more of those BITFIELDs
Check out Concise [0] or Roaring Bitmaps [1] before rolling your own compressed bitset scheme. Wish I had known about these sooner.

(I realize now this is offtopic, as this is bit fields not bit sets; nevermind, but still it's interesting!)

[0] http://arxiv.org/pdf/1004.0403.pdf

[1] http://roaringbitmap.org/

a1k0n··on Calculating integer factorials in constant time, taking advantage of overflow
You wouldn't, for statistics. That's my point.

Only in number theory problems do you actually need bignums for factorials, and those are usually toy problems or modulo some big prime.

I don't know of any actual applications where you need to compute the bignum factorial. I'm curious what the GP needed it for.

a1k0n··on Calculating integer factorials in constant time, taking advantage of overflow
Depends what you need them for... In statistics, factorials appear in normalizing constants for various distributions (e.g., Poisson) and often you're working with floating point log-probabilities, in which case you can use the log-gamma function (built into most math libraries) to replace the log factorial. And that's a 64-bit float, no bignums needed.
a1k0n··on I Was Internet-Famous
It is all of those things. The language is just a bit overwrought.
a1k0n··on I Was Internet-Famous
Tay Zonday's response is hilarious. "It is hard to create Derrida’s fracture in the repetition of power structures when the loins of civil society log every person’s digital utterance."
a1k0n··on Entering Public Beta
This is awesome! Way easier than installing anything that tries to do everything for you, especially if you have a non-traditional setup.

One caveat: AWS CloudFront requires the domain key to be 2048 bits instead of 4096. Other than that, worked flawlessly for me and now www.a1k0n.net is finally SSL capable. Thank you!

a1k0n··on A Cabinet of Infocom Curiousities
I submitted this yesterday, and then someone re-submitted this today, and the auto-resubmit logic apparently just kicked in for my post. You can see on https://news.ycombinator.com/submitted?id=a1k0n that it was submitted "1 day ago" though it shows a different date here. It's a weird hack.
a1k0n··on ARRIS Cable Modem Has a Backdoor in the Backdoor
Not a bad chiptune either: http://www.a1k0n.net/code/jsxm/#Ghidorah_-_Toilet_story_5.xm
a1k0n··on Playing Fasttracker2 .XM files in JavaScript
edit: THANK YOU! That was the issue; I had to make a dummy oscillator. And, separately, there was a CSS issue which made the buttons black on black. Now it works on iOS.
a1k0n··on Playing Fasttracker2 .XM files in JavaScript
On second thought you're probably right; this API will probably break in a couple years and my player won't work anymore, just like everything else that tried to use createJavaScriptNode in the past is now broken.

Hopefully the web workers transition is the last...

a1k0n··on Playing Fasttracker2 .XM files in JavaScript
Yep. Just added drag-and-drop to the player window; drag a local .xm file onto it to load it. Only tested in Chrome.
a1k0n··on Playing Fasttracker2 .XM files in JavaScript
Haha, sure, let me push some fixes to the github repo.

RIP script, OMG. I remember that. With HTML canvas, shouldn't be too hard, though it would be weirdly high-resolution.

a1k0n··on Playing Fasttracker2 .XM files in JavaScript
Of course it is. It's actually a lot easier, as there are no envelopes and just one sample per instrument. Firehawk/TDA wrote this excellent player a while back: http://mod.haxor.fi/Purple_Motion/2nd_pm.s3m
a1k0n··on Playing Fasttracker2 .XM files in JavaScript
Hmm, I appear to have a sample loading overflow bug somewhere... http://www.a1k0n.net/code/jsxm/#nf-chill.xm

Edit: pushed a fix... something is goofy with the sample data in instrument 4.

a1k0n··on Playing Fasttracker2 .XM files in JavaScript
It got renamed from JavaScriptNode to ScriptProcessor when it switched from webkitAudioContext to AudioContext, and it seems to be the best-supported way to do it. I don't see why not. But of course IE doesn't support it at all and I don't think iOS Safari does either (it's a big question mark on mozilla.org anyway)
a1k0n··on Playing Fasttracker2 .XM files in JavaScript
Sorry, haven't worked that in yet...
a1k0n··on TinyMOD (2011)
Funny, I just wrote one of these for the web. I don't oversample at 3.5MHz though. http://www.a1k0n.net/2015/11/09/javascript-ft2-player.html
a1k0n··on Yahoo Logo ASCII Animation in 462 bytes of C (2011)
48kHz version, sounds slightly better: https://jsbin.com/zazifecaqe/1/edit?html,output
a1k0n··on Yahoo Logo ASCII Animation in 462 bytes of C (2011)
FWIW, most of this code is actually contained inside for loop expressions, since you can chain them together with commas and get away without using any braces. Once that's done it's hard to even count "lines".
a1k0n··on Yahoo Logo ASCII Animation in 462 bytes of C (2011)
I am a big fan of viznut also, and took the liberty of translating this into Javascript so we can all hear it without trying to find a /dev/dsp analog (I used ./viznut | sox -t raw -e unsigned -b 8 -r 8000 - -d):

https://jsbin.com/tazeyoqoci/edit?html,output

Amazing work.

a1k0n··on Yahoo Logo ASCII Animation in 462 bytes of C (2011)
Speaking of crazy ascii company logo animations, I never got a chance to golf these down, but I made some with color and signed distance field ray marching:

https://github.com/a1k0n/asciitracing

a1k0n··on Yahoo Logo ASCII Animation in 462 bytes of C (2011)
I transformed the code into something sort of readable, although still somewhat difficult to understand:

https://gist.github.com/a1k0n/15f6cc2fc9428d6fd197

← PreviousPage 3 of 11Next →