6 ms·
Is there an encoding that is less wasteful that base64 but not vulnerable to text editor corruption issues? I think avoiding 0x0 to 0x20 should be enough to not
by dheera 3y ago
Is there an encoding that is less wasteful that base64 but not vulnerable to text editor corruption issues? I think avoiding 0x0 to 0x20 should be enough to not get corrupted by text editors, though base64 avoids a lot more than that.
- ElectricalUnion 3y agoIf you can count on every printable ascii character being not-mangled, you can use ascii85/base85/Z85 (5 "ascii characters" to 4 bytes) instead of base64.
- raverbashing 3y agoThere's probably a base(bigger number) with Unicode chars today
- bashinator 3y agobase65536, and look who the author is :-D https://github.com/qntm/base65536 https://github.com/qntm/base65536
- cassianoleal 3y agoWho is the author?
- yccs27 3y agohttps://www.qntm.org https://www.qntm.org https://news.ycombinator.com/from?site=qntm.org https://news.ycombinator.com/from?site=qntm.org
- deleted 3y ago[deleted]
- CaptainFever 3y agoBase65536? https://github.com/qntm/base65536 https://github.com/qntm/base65536
- sudobash1 3y agoBut you need to make sure to use utf-16 or utf-32 instead of utf-8, or you may be worse off.
- dheera 3y agoThose get mangled by text editors that don't support them.
- Dylan16807 3y agoWhile a couple of people suggested Base65536, that encoding isn't particularly compact, and it can't be as elegant as 65536 would suggest because it has to dodge special cases in unicode. It's almost always the case that either Base32768 is denser, or encodings with 2^17 or 2^20 characters are denser.
- balou23 3y agothere's also base91, with an efficiency of 6.5 bits of data per printable character, compared to 6.4 with ascii85, 6.0 with base64
- doublerabbit 3y agobase16
- doublerabbit 3y agoWoah, why the downvotes.
- delusional 3y agoAt that point you're basically doing yEnc.
- Tepix 3y agoBase85, also called Ascii85. Also yEnc.
- bazzargh 3y agoif you mean the thing you want to encode is mostly-ascii, then https://en.wikipedia.org/wiki/Quoted-printable https://en.wikipedia.org/wiki/Quoted-printable ... it's a real throwback, I've not seen this in the wild since the 90s, but it's there in the python standard library (quopri), perl (MIME::QuotedPrint) etc