The more you understand about Unicode the more you understand how profoundly broken this is http://rot8000.com/Index
-
-
Vigenère ciphers (of which Caeser ciphers such as ROT-13 are a special case) have no effect on Japanese text. So I needed to come up with something analogous which could be applied to all Unicode text
Show this thread -
But you can't just naïvely rotate Unicode code points. That rotation can lead to unassigned code points, or invalid ones. What about combining characters? Normalization of the output can cause data corruption. So can whitespace flattening
Show this thread -
In the end I used a dumb solution, which was to percent-encode the input and *then* apply the Vigenère cipher to the percent-encoded input. The result looks a little ridiculous, but it was definitely illegible and 100% reversible, which was the important part
Show this thread -
And while I'm at it, can everybody *please* remember to NFD-normalize your strings prior to ROT-13. "Naïveté" should become "Anv̈irgŕ", not "Anïirgé". Otherwise, if the encoded text does get normalized in transit, it'll decode incorrectly to "Nav̈vetŕ"
Show this thread -
-
You know what? Here's a ROT13 implementation which handles combining characters properly https://qntm.org/files/rot13/rot13.html …
Show this thread
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.