HNHacker News
TopNewBestAskShowJobs

leijurv

486 karma · joined May 1, 2016

[ my public key: https://keybase.io/leijurv; my proof: https://keybase.io/leijurv/sigs/w7C9Q0ei9POBhzwXcl36pWOTknw0WeEo5yNlqo497G8 ] Verifying my Blockstack ID is secured with the address 1PjWQMkKBD3JJJuYMEXnSYZ9pvpbLTQVqS https://explorer.blockstack.org/address/1PjWQMkKBD3JJJuYMEXnSYZ9pvpbLTQVqS
submissionscomments
leijurv··on Resurrecting a dead torrent tracker and finding 3M peers
OP did actually host a tracker.

"I then started the tracker. After about an hour, it peaked at about 1.7 million distinct torrents across 3.1 million peers!"

leijurv··on Short Message Compression Using LLMs
Here's the submission that won the Hutter Prize in 2021: https://github.com/amargaritov/starlit It uses a LSTM to predict the next token lossily, then uses https://en.wikipedia.org/wiki/Arithmetic_coding to convert that to lossless compression. Lossless compression can definitely leverage a lossy compressor, such as via arithmetic coding. Also see: https://en.wikipedia.org/wiki/Context-adaptive_binary_arithm... which has a simple "Example" section - imagine if the top prediction made by your neural network was correct, you emit "0", if the 2nd was correct, you emit "10", if the 3rd, "110", if the 4th, "1110". As you can see, this is lossless, but the fundamental prediction is lossy, and the better that prediction is, the better the compression. (In actuality, you wouldn't waste your 1 bits like this, you'd use arithmetic coding instead).
leijurv··on A new rare high-rank elliptic curve, and an orchard of Diophantine equations
I suspect it was, given that they've now deleted their comment.
leijurv··on A new rare high-rank elliptic curve, and an orchard of Diophantine equations
`for char in message: encrypted_char = ord(char) ^ (shared_secret[0] % 256)`

This is not real encryption, it picks only one byte of shared secret and XORs it into the plaintext. Therefore, there are only 256 possible decryption keys to check, which is trivial.

Instead, you'd want to use the shared secret as a key to something strong and symmetric like AES.

leijurv··on Randar: A Minecraft exploit that uses LLL lattice reduction to crack server RNG
It was a one-way collaboration, in that we referenced their discoveries and code such as LattiCG https://github.com/mjtb49/LattiCG, but they were unaware of anything we were doing until now. https://twitter.com/admiral_stapler/status/17806748612594609...

Naming Baritone after Fit is actually a coincidence / joke, the repo github.com/cabaletta/baritone was the result of random brainstorming for something untaken. We only later realized it described Fit and thus added that to the readme :)

leijurv··on Randar: A Minecraft exploit that uses LLL lattice reduction to crack server RNG
I'm just a regular SWE! Infosec or algorithmic trading - maybe someday.
leijurv··on Randar: A Minecraft exploit that uses LLL lattice reduction to crack server RNG
Yes, absolutely :) that's why we went to FitMC to make the video, he always delivers.
leijurv··on Randar: A Minecraft exploit that uses LLL lattice reduction to crack server RNG
I believe that may be the spectral test https://en.wikipedia.org/wiki/Spectral_test which I mentioned in the explanation when showing the lattices visually
leijurv··on Minosoft: Open-source Minecraft client, written from scratch
HN thread: https://news.ycombinator.com/item?id=29615428 :)
leijurv··on Iterators in Go: A proposed extension
No that's not at all how this works. The iterator could "return" a boolean by passing a boolean to "yield". The return value of "yield" just indicates if the generator should continue, or stop because the actual loop has exited (due to break or return).
leijurv··on 55 GiB/s FizzBuzz (2021)
This inspired me to plumb the depths of FizzBuzz, seeking further into it than anyone ever has before: the 10^10000000000th digit (it's a "1"): https://github.com/leijurv/reverse-fizzbuzz
leijurv··on Brave Integration Deepens Support for Unstoppable Domains
One person one vote is democracy, one dollar one vote is web3. Very different.
leijurv··on Dusting “Attack” via Tornado Cash to Public Wallets
> I wonder how Blockchain explorers deal with more complex scripts. For example on blockchain.com one can look up coins by putting an "address" into the search bar. But how would one look up coins that are not locked by a script that puts the coins under control of a certain key? Or a script that puts them under control of multiple keys?

The reveal of the script is actually time-delayed. See https://en.bitcoin.it/wiki/Pay_to_script_hash

Essentially, you "send" the Bitcoin to the hash of the script, then whenever a transaction spends those coins it must reveal the script (whose hash must match), as well as some data (normally a digital signature or two) that fulfills the script's conditions.

So, the block explorer doesn't get to deal with it until the coins are spent, up until that point all it knows is a hash, which is represented as beginning with a "3", to differentiate it from the simple single-key addresses that begin with a "1".

When it's spent, a block explorer could show the revealed script contents if it wanted.

leijurv··on A prominent composer lost his Wikipedia page
Some mistake or miscommunication happened there, as Wikipedia does have a policy that people can be cited for information about themselves, the policy is called SELFSOURCE. See: https://en.wikipedia.org/wiki/WP:SELFSOURCE

Perhaps the issue was that Philip Roth was unable to sufficiently demonstrate his identity? Of course, Wikipedia can't take a random editor's word when they say "I am this person and this is the truth", then anyone could say anything. There has to be some citation, for example I've seen someone cite a tweet for simple biographical information (e.g. "today is my birthday").

leijurv··on A prominent composer lost his Wikipedia page
I think it has to do with verifiability. https://en.wikipedia.org/wiki/WP:V Essentially everything written has to be verifiable, and if a person doesn't have enough reliable sources talking about them, it isn't really possible to write a verifiable article. See https://en.wikipedia.org/wiki/WP:GNG and https://en.wikipedia.org/wiki/WP:RS
leijurv··on Why I’m Cryptophobic
Well it's a continuous process: today the fees make up maybe three percent of revenue, but that fluctuates as transaction space demand changes, and as the coinbase halves every few years.

But your point is good - miners are not really in a traditional supply/demand relationship with transactors, because block space is perfectly inelastic. There will be 7 slots per second (amortized), no matter what. Although... a petulant miner could artificially restrict this supply, by perhaps declaring that they'll never mine a transaction that pays less than X fee. This would only apply to the blocks that they mine, but the effect on overall supply could be nontrivial?

leijurv··on Why I’m Cryptophobic
I've heard the metaphor that "writing your ledgers in pen instead of pencil doesn't make transactions irreversible" - meaning that in the same sense, actions on the blockchain could be coded to be irreversible.

The difference is in the authority of who gets to reverse transactions. For example, Tether can freeze and generally arbitrarily control USDT token. USDT therefore isn't really a cryptocurrency, since now a central authority can seize it. It seems to me that this authority undermines why one might want to use crypto in the first place. I don't think you can have it both ways.

leijurv··on Why I’m Cryptophobic
Why do you think it all comes down to that?

Clearly there's much more to it. For example, cryptocurrencies with those two properties you mentioned are a dime a dozen. I could make one right now by git cloning bitcoin, changing some properties, then running it. And in practice there are thousands with high volume exchange-value. Digital currencies, when combined with ubiquitous exchanges, have such substitutability that I'm not sure there's much of a "network effect" or "lock in", when it's so easy to swap and pay with any of them. "value decided by the market" might be flimsy in this case.

leijurv··on Why I’m Cryptophobic
I don't think that's true, fees are not proportional to that. Fees compete for a finite and precise limited space in blocks. There's no limit to how high fees could grow in this competition, because only the 7 most lucrative transactions get mined per second.

I think it is vaguely accurate to say that fees and mining costs are linked, *however*, currently the coinbase block reward is a bigger deal. Example: most recent block https://www.blockchain.com/btc/block/743055 created 6.25 bitcoin out of thin air, plus 0.186 bitcoin from all its fees. In the future, when fees make up a larger share of this, miners will indeed start to get income from fees. Then, we will see an interesting dynamic where automatic difficulty adjustments and competition between miners entering and exiting the market will result in miners electricity costs aligning with bitcoin transaction fees. In other words, every unit of value that goes into a bitcoin transaction will result in that much value being spent by a miner on their electricity bill.

leijurv··on In search of the least viewed article on Wikipedia
No need to speculate on how big or small the gaps may be, the article looks at the actual random gap values used on Wikipedia.

Quote: "The least viewed article in the sample, Erygia sigillata, has a page_random value of 0.500764585777. The article Katherine Hanley is right on its tail with a value of 0.500764582314, which is just 0.000000003 less, or 3e-9 in scientific notation. This is 98% smaller than the average random gap. In other words, Erygia sigillata is an extremely unlucky article as far as the “Random article” button is concerned! It’s 50 times less likely to be landed on than an average article."

leijurv··on Nearly 1k mysterious strands revealed in Milky Way’s center
There's a download button in the bottom right, if you hit Original you get the actual original. Here it is: https://live.staticflickr.com/65535/51847931721_c3feebd201_o...
leijurv··on Automatic Ripping Machine (2016)
That is handled by MakeMKV, which the blog posts refers to.

https://www.makemkv.com/

"MakeMKV is a format converter, otherwise called "transcoder". It converts the video clips from proprietary (and usually encrypted) disc into a set of MKV files, preserving most information but not changing it in any way."

leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
Well, read https://news.ycombinator.com/item?id=29621262 if you want to know why this ended up happening :)
leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
Not quite a shortcut, it was actually to patch a bug in vanilla minecraft that causes desync, see https://news.ycombinator.com/item?id=29621262 And it may seem silly that it tells you that it's block type ABC, but the reason is to tell your client to put it back as block ABC, instead of air. (in other words, it has to "undo" your client claiming to have mined that block [which replaces whatever it is with air]).
leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
Well, Paper is trying to fix the result of vanilla Minecraft's range check. Taking their perspective, they wanted to fix the issue where <6 blocks worked, but >6 blocks caused desync. So it is natural to reply in the "else" block with "no you can't break that". They just didn't think of adding yet another range check with a looser limit on top of that.

I wasn't around for when the patch was engineered into Paper, but from what I'm told, yes that was the idea. :)

leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
Yeah, https://users.isy.liu.se/rt/schon/Publications/HolSG2006.pdf was great to refer to, just the right level of complexity for me.
leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
If I remember correctly, for ZFS it was some stuff about cache size and RAM usage, since we were in a VM and couldn't be too greedy. Something about a NVME drive needing slightly different settings. I didn't spend much time on this. For Postgres it was so so so many things, I played with it on and off for months, benchmarking certain key queries and such. And I read a LOT of blog posts about how to make Postgres and ZFS work together ideally, one thing I remember in particular was waffling back and forth about logbias=throughput vs logbias=latency. Just google "postgres zfs logbias" and you'll get MANY conflicting opinions. (edit: when I google it now in incognito, my reddit post is at the top lol)

But for what I actually changed, off the top of my head, I set the recordsizes in ZFS large enough that Postgres could safely (because of ZFS CoW) have full_page_writes off, and combined with synchronous_commit off, that really sped up the overall system and made the WAL logs much smaller. After looking just now at postgresql.conf, various other things were tweaked, such as seq_page_cost, random_page_cost, effective_cache_size, effective_io_concurrency, max_worker_processes, default_statistics_target, dynamic_shared_memory_type, work_mem, maintenance_work_mem, shared_buffers, but those were not quite as important. (plus some uninteresting tweaks to WAL behavior, since we had replicas that got WAL logs shipped every few minutes with rsync)

leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
Thanks!
leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
For tracking, the spatial resolution was 1 chunk, which is 16 by 16 blocks, and the temporal resolution was 1 second. So, we have a few billion rows of tracking data for every player, localizing them to roughly that distance, roughly once a second.

For downloading bases, it is an essentially perfect recreation. Some things are missing, such as the color of banners, but for 99% of blocks, just setting the correct blockstates will recreate the build. Some disconnected sections of the build might not be found by the paintbucket floodfill algorithm though, so floating parts could be missing. We counteracted this by having a few random blocks in the chunk be checked on a schedule, so eventually it would get everything.

leijurv··on Nocom – 2b2t Minecraft server exploit using Monte-Carlo localization
Yes, so Minecraft is exactly that. Any "I have mined this block" further than 6 blocks away from the player is ignored. The problem is that on a laggy server, an honest client can end up sending this, if the server lags out for more than 6 blocks of walking your player forward. So, Paper added a patch to undo these disallowed mines, setting them back to what they were. But this happened at any radius, and could be used to lag the server by making it generate any region. Then they patched it again and made it only reply if it were in a loaded chunk. The mistake was that it replies if the coordinate is in a chunk loaded by any player, not just by your player. :) See https://news.ycombinator.com/item?id=29620852
Page 1 of 3Next →