Save Image with Password Prompt
Save Image with Password Prompt — hidden metadata, but don't call it encryption
- images
This node is basically ComfyUI's Save Image with a party trick: it takes a prompt string and a password, and stashes the prompt into the image file in a way that's garbled unless you know the password. The matching Load Image with Password Prompt node in the same pack reads it back. It's a neat way to keep a prompt hidden inside your output instead of sitting there in plaintext.
Let me be straight about what "hidden" means before you build anything on it. The mechanism is a per-byte XOR of the UTF-8 prompt against the password, then base64. That's obfuscation, not encryption - a cryptographer would call it a toy. If someone has the image and wants the prompt badly enough, XOR with a guessable password is trivially crackable, and if your password is weak, it's effectively plaintext with extra steps. Treat it as "keeps casual viewers from reading the prompt in a text editor," not as any kind of DRM or secret storage. If the password field is empty, the prompt is written out in plaintext, so the whole feature quietly switches off.
How it works
For PNG it writes the encoded prompt into the image's prompt PNG metadata chunk. For JPG it stuffs it into the EXIF ImageDescription field (tag 0x010E). Either way, the prompt bytes survive because they live in metadata, not in pixels - which matters for JPG, because the pixel data gets recompressed at a fixed quality of 70.
It's an output node, so it has no outputs; it saves files and reports them back to the UI like a normal save node.
The inputs that matter
- images (IMAGE) - what you're saving.
- prompt (STRING) - the text to embed. This is your prompt string, not the whole ComfyUI workflow - if you want the full graph embedded too, you'd chain a standard save node.
- password (STRING) - the XOR key used to scramble the prompt.
- filename_prefix (STRING) - where and how to name files. Default is
Images/%date:yy-MM-dd%/%date:hhmmss%_, which gives you a dated subfolder and a timestamped base. The%date:...%token takes strftime-style codes (yyyy,MM,dd,hh,mm,ss), and you can also use%width%and%height%to bake dimensions into the name. - image_format - JPG or PNG. Pick JPG for smaller files, PNG if you want the metadata in the native chunk and lossless pixels.
Files get a counter suffix (_00001, _00002, ...) so you won't overwrite, and it refuses to write outside your output directory.
Installing it
Part of ComfyUI Fictiverse Nodes. Install via ComfyUI Manager (search "ComfyUI Fictiverse Nodes") or:
cd ComfyUI/custom_nodes
git clone https://github.com/Fictiverse/ComfyUI_Fictiverse
Restart ComfyUI afterward. No extra dependencies and no model downloads - it uses only PIL, which ComfyUI already ships. The pack is Apache 2.0.
Common issues
If you get ModuleNotFoundError: No module named 'custom_nodes.ComfyUI_Fictiverse' on startup, it's the pack's known install-folder bug: it must live in a folder literally named ComfyUI_Fictiverse because the code imports itself by that path. Rename and restart.
The other gotcha is real-world: a password-protected JPG still carries its prompt in EXIF, and any image tool that shows EXIF will happily display the base64 blob. And if you feed the file through a service that strips EXIF or re-encodes it, the prompt is gone. For sharing a prompt with someone, the plaintext metadata that ComfyUI already embeds is usually the friendlier choice; this node shines when you specifically want the prompt out of view.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| prompt | STRING | — | |
| password | STRING | — | |
| filename_prefix | STRING | Images/%date:yy-MM-dd%/%date:hhmmss%_ | — |
| image_format | COMBO | JPG | 2 options: JPG, PNG |
Outputs (0)
No outputs