Nodes/ComfyUI ARG Toolkit/Rotate-13 Cipher
ComfyUI Node

Rotate-13 Cipher

The cipher that's its own undo button

By AzelusLightvale·Created 12 months ago·Updated 4 days ago· 1
Rotate-13 Cipher
    • encrypted_txt
    textHello World!
    alphabetENGLISH
    modetrue
    keep_formattingtrue

    ROT13 is the cipher you already know even if you don't know you know it: every letter shifts 13 places, A↔N, B↔O, and so on. Because 13 is exactly half of 26, applying it twice restores the original message - it's its own inverse. That's why it's been the default "hide the spoiler" trick on the internet since Usenet. The Rot13 node gives you that in your ComfyUI graph, mostly because an ARG Toolkit that didn't include it would feel incomplete, and because it's the perfect first test node to confirm your workflow is wired right.

    Seriously, that last bit is the real use case here. Before you chain together Playfair, a transposition, and a hash, wire up Rot13 and run a known phrase through it. If Hello comes back as Uryyb on encrypt and Hello again on decrypt, your graph plumbing works and any failure downstream is a cipher problem, not a wiring problem.

    The inputs are the pack's classical template minus the key (there is no key - the rotation is fixed):

    • text - your message, plain string, multiline.
    • alphabet - ENGLISH by default. You can change this, which is the one clever thing: a different alphabet length changes the rotation arithmetic. Leave it alone for actual ROT13.
    • mode - encrypt or decrypt. As noted, they're the same operation, so this toggle is decoration.
    • keep_formatting - on by default: only letters rotate, case and punctuation stay put. Off: lowercase, no spaces.

    Output is encrypted_txt, a STRING.

    There's no real troubleshooting to do here, which is the point - this is the "does the pack work" node. It sits under ARG Toolkit/Cryptography/Classical after you install the pack via ComfyUI Manager (search "ComfyUI ARG Toolkit") and restart, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/AzelusLightvale/ComfyUI-ARG-Toolkit
    

    Restart ComfyUI and you're done. No models, no downloads, and unlike the pack's modern-crypto nodes this one takes plain strings, so there's no bytes conversion to forget.

    Worth one sentence on why ROT13 keeps appearing in puzzles: it's not security, and everyone knows it. It's a convenience obscurity - it hides the text from casual glance while staying trivially reversible, which is exactly what you want for a first-stage clue that's meant to be solved in seconds. If you're building an ARG, ROT13 is the "hello world" layer of your puzzle.

    CategoryARG Toolkit/Cryptography/Classical

    Inputs (4)

    NameTypeDefaultDescription
    textSTRINGHello World!
    alphabetSTRINGENGLISHInput your alphabet here. If left blank, uses the alphabet default to the cipher. Uses standard connected format ('abcdef'), but can also accept the alphabets defined in secretpy in alphabets.py.
    modeBOOLEANtrueToggle between encrypting or decrypting a message.
    keep_formattingBOOLEANtrueToggle between preserving the format of the message or remove all spaces, punctuations, and convert to lowercase.

    Outputs (1)

    NameTypeDescription
    encrypted_txtSTRING