Live data from Hacker News

Show HN: Base24 binary-to-text encoding for humans

kuon.ch

11–20 of 69 posts

Re: Show HN: Base24 binary-to-text encoding for humans

#11
Another interesting solution to this problem is that used by plus codes [1]:

> The characters that are used in Open Location Codes were chosen by computing all possible 20 character combinations from 0-9A-Z and scoring them on how well they spell 10,000 words from over 30 languages. This was to avoid, as far as possible, Open Location Codes being generated that included recognisable words. The selected 20 character set is made up of "23456789CFGHJMPQRVWX". [2]

[1]: https://plus.codes [2]: https://github.com/google/open-location-code/blob/master/doc...

Re: Show HN: Base24 binary-to-text encoding for humans

#12

Another interesting solution to this problem is that used by plus codes [1]: > The characters that are used in Open Location Codes were chosen by computing all possible 20 character combinations from 0-9A-Z and scoring them on how well they spell 10,000 words from over 30 languages. This was to avoid, as far as possible, Open Location Codes being generated that included recognisable words. The selected 20 character s…

Does not help with the ambiguous character problem at all, though

Re: Show HN: Base24 binary-to-text encoding for humans

#13
> The final alphabet I came up with is ZAC2B3EF4NH5TKL7P8RS9WXY. As I required 24 characters, I kept G and 6 which are the least ambiguous in the list.

I've read this a dozen times. Isn't OP saying that their character list includes G and 6, which are _not_ present in that list?

Update: It appears to be a typo in the article. Here's the real alphabet (N replaced by G and L replaced by 6): ZAC2B3EF4GH5TK67P8RS9WXY

https://github.com/kuon/java-base24/blob/0c25905414f1598a0ed...

Re: Show HN: Base24 binary-to-text encoding for humans

#14
Nice! I'd like to implement this in a key-recovery tool I have been working on, Passcrux [1]. I actually started fleshing out a base24 encoding of my own, but the padding/bit shuffling proved to be somewhat cumbersome, and I shifted focus to abc16, which is like hex, but purely alphabetic.

[1] https://github.com/xkortex/passcrux

Re: Show HN: Base24 binary-to-text encoding for humans

#15

I'm fond us using a base100, made of up 2 letter syllables. It results in a vaguely pronounceable string. For syllables, I use: syllables: %w[ ba be bi bo bu ca ce ci co cu da de di do du fa fe fi fo fu ga ge gi go gu ha he hi ho hu ja je ji jo ju ka ke ki ko ku la le li lo lu ma me mi mo mu na ne ni no nu pa pe pi po pu ra re ri ro ru sa se si so su ta te ti to tu va ve vi vo vu wa we wi wo wu xa xe xi xo xu ya ye y…

And pipe them into TTS for all kinds of fun...

It is - https://cloud.google.com/text-to-speech

Try different languages. ra re ri ro ru is my favorite little run of most of them.

Re: Show HN: Base24 binary-to-text encoding for humans

#16

> decimal: 49894920630459842177293598641814316632 This 128-bits can also be represented in, let's say base-50K, by using five words chosen from a 50,000 word dictionary. If you also make "this", "This" and "THIS" separate, then you can get away with a 17K word dictionary. Depending on the language, if you use roots and then vary morphology based number, tense, etc., then the number of root words (and the choice you h…

I recently needed to encode a 32-bit value into something easy for QA folks to remember and report. I opted for 3 words out of an 11-bit (2048 entry) dictionary of commonly used words.

How to build the dictionary? Well, in order to determine the most commonly used English words, I downloaded a bunch of free texts from Project Gutenberg, and did some simple filtering - nothing less than 5 letters, no duplication of singular + plural, etc...

A valuable lesson that I learned during this process is that when your corpus includes older english texts, you should always give your final list a visual once-over and apply some judicious manual filtering. I'm looking at you, "The Adventures of Tom Sawyer". (And, to a lesser extent, Moby Dick).

Re: Show HN: Base24 binary-to-text encoding for humans

#17
post #6

Though clearly there are some advantages with removing ambiguous chars... I feel like it's more of a UI / UX thing-to-polish than a problem . Lack of polish creates the problem, the ambiguous chars themselves are not inherently an issue. If it's ambiguous, you could accept either and transform it to the correct value (implicitly, or as entered, or whenever makes sense. your users don't ever have to know). Or if you c…

> do something like 1password does with chars and letters: show them differently

That’s missing the point. You can show them differently, but the point of keys / recovery codes is that they’ll be stored somewhere and later re-entered. Users could store them in any program (including writing them down or printing them out), you can’t control how they are displayed over there. Then when they need to use them, there’s a chance the ambiguous characters can’t be easily discerned.

Re: Show HN: Base24 binary-to-text encoding for humans

#18
post #16

> decimal: 49894920630459842177293598641814316632 This 128-bits can also be represented in, let's say base-50K, by using five words chosen from a 50,000 word dictionary. If you also make "this", "This" and "THIS" separate, then you can get away with a 17K word dictionary. Depending on the language, if you use roots and then vary morphology based number, tense, etc., then the number of root words (and the choice you h…

I recently needed to encode a 32-bit value into something easy for QA folks to remember and report. I opted for 3 words out of an 11-bit (2048 entry) dictionary of commonly used words. How to build the dictionary? Well, in order to determine the most commonly used English words, I downloaded a bunch of free texts from Project Gutenberg, and did some simple filtering - nothing less than 5 letters, no duplication of si…

In most cases if you need a short list it's better to use something like the diceware or EFF lists than to make your own from scratch.

Re: Show HN: Base24 binary-to-text encoding for humans

#19

I'm fond us using a base100, made of up 2 letter syllables. It results in a vaguely pronounceable string. For syllables, I use: syllables: %w[ ba be bi bo bu ca ce ci co cu da de di do du fa fe fi fo fu ga ge gi go gu ha he hi ho hu ja je ji jo ju ka ke ki ko ku la le li lo lu ma me mi mo mu na ne ni no nu pa pe pi po pu ra re ri ro ru sa se si so su ta te ti to tu va ve vi vo vu wa we wi wo wu xa xe xi xo xu ya ye y…

That’s just Japanese “Roman” alphabet:

Consonants [(None), k, s, t, n, h, m, y, r, w], followed by,

Vowels [a, i, u, e, o] forming 5x10 matrix,

+ semi-voiced ゜(p replaces h) and voiced ゛(g, z, d, b replaces k, a, t, h)signs,

+ silent “nn”,

- wi wu we.

(aka NES Dragon Quest spell of resurrection)

Re: Show HN: Base24 binary-to-text encoding for humans

#20

I'm fond us using a base100, made of up 2 letter syllables. It results in a vaguely pronounceable string. For syllables, I use: syllables: %w[ ba be bi bo bu ca ce ci co cu da de di do du fa fe fi fo fu ga ge gi go gu ha he hi ho hu ja je ji jo ju ka ke ki ko ku la le li lo lu ma me mi mo mu na ne ni no nu pa pe pi po pu ra re ri ro ru sa se si so su ta te ti to tu va ve vi vo vu wa we wi wo wu xa xe xi xo xu ya ye y…

Be careful, wiser(??) people have tried the path, and their tale is told in...

https://thedailywtf.com/articles/The-Automated-Curse-Generat...

Post reply on HN