code.pablomurad.com

cock-mail1

Hx, a fork of cock-mail: client-side webmail that speaks IMAP and SMTP from the browser over WebSockets

git clone https://code.pablomurad.com/cock-mail1.git

Recent commits

  1. c921334
    Docs: README, LICENSE, CHANGELOG, deployment guide
    
    README credits cock-mail and cock.li and lists every change in this
    fork. LICENSE is the original license block, copied verbatim.
    
  2. fa538a1
    Rebrand as Hx by MuradCorp
    
    Page title, login heading, username placeholder, EHLO name and default
    User-Agent. The original license block and the upstream credits in the
    header comment are kept unchanged, as the license requires.
    
  3. e790a48
    Config: official: false
    
    This is not the official cock.li deployment; disable the features that
    are specific to it, as the upstream config comment asks.
    

Full log →

Readme

Hx by MuradCorp

A fully client-side webmail that talks IMAP and SMTP straight from the browser over WebSockets. There is no webmail backend: the whole session lives in your browser.

Hx is a fork of cock-mail, made by the people behind cock.li. All the hard work is theirs. This fork only adds a few compatibility fixes and a different name. If you like it, please support cock-mail’s development.

Based on

Hx cock-mail
0.5.2-hx1 0.5.2

The unmodified upstream releases are in the history, tagged upstream-0.5.1 and upstream-0.5.2, so every change in this fork can be read with git diff upstream-0.5.2 main.

What this fork changes

Compatibility (useful for any server that is stricter than Dovecot/Postfix, such as Mox):

  • IMAP greeting: any * OK greeting is accepted. Upstream required the word “ready” and hung on “Connecting…” with servers that greet differently.
  • SMTP envelope: MAIL FROM:<addr> and RCPT TO:<addr> use angle brackets, as RFC 5321 requires. Stricter servers reject the bare form.
  • Multiple tabs: if another tab holds the local database during a storage upgrade, the user is told to close it instead of the app freezing on “Migrating your storage”.

Configuration and branding:

  • official: false, since this is not the official cock.li deployment.
  • Name, login heading, placeholder, EHLO name (hx) and User-Agent (Hx/0.5.2).

Everything else is upstream cock-mail.

How it works

  • public/ is the whole app: one index.html and a favicon. Serve it as static files.
  • The browser opens WebSockets to /imap and /smtp on the same host (configurable in window.config at the end of index.html).
  • A WebSocket-to-TCP bridge (such as websockify) forwards those to your IMAPS and SMTPS ports.
  • HTML mail is shown as plain text with the links extracted, never rendered.

See docs/deploy.md for a working nginx + websockify setup.

License

The original cock-mail license applies and is kept in full, both at the top of public/index.html and in LICENSE.