13

I was reading through the docs for vim, and noticed there's a shortcut, for example g?w would transform the next word using ROT13. I also know that you can change the encoding of a Python file to ROT13.

Here's my question: Why? It seems like it wouldn't be that useful, aside from prank programs like Django FUNserver.

3 Answers3

19

There is history there. In the old days, long before the spoiler tag, you'd ROT13 a spoiler, or a joke punchline, or a riddle, so that it wouldn't be immediately readable, but it could still be quickly converted to readable format (if you ROT13 a piece of text a second time, it'll switch it back to the original text because there are only 13 26 (need more COFFEE) characters in the roman alphabet.)

So a lot of things that did mild obfuscation used ROT13, because it was commonly available, and so it's been backported into a number of more modern languages. It's just a weird quirk.

Satanicpuppy
  • 6,196
8

ROT13 was originally devised to be used with Usenet postings that contained offensive material so the more sensitive among us wouldn't be inadvertently exposed to them. The idea was that you had to take an action to decode the posting as a way of indicating that you understood that you might find the contents offensive.

It's just a substitution cipher and isn't intended to provide any kind of privacy or authentication.

(ETA: It was very difficult to resist the urge to post this answer ROT13'd.)

Blrfl
  • 20,525
2

It was actually once used seriously as part of a 4 stage encryption process by Netscape Navigator to store email passwords. It is probably not their greatest idea and forms part of a case study of poor encryption (There may be a better version of this doc to link to somewhere - if so - please edit)