Skip to content

Releases

mkcert Web UI 5.0.1

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 10 Nov 04:49
2cc6887

Fixed

  • SSO stayed broken until restart if the OIDC provider was unreachable at
    startup (#59).
    Discovery ran once at boot; when it failed, /auth/oidc
    answered 500 Unknown authentication strategy "oidc" until the process was
    restarted (typical with Docker Compose starting mkcert-web before the
    identity provider). Discovery is now retried when someone signs in with
    SSO, at most once every 10 seconds, and until the provider answers the
    browser is returned to the login page with a "provider cannot be reached"
    message. The discovery request also has a 10 second timeout, so a provider
    that accepts connections but never answers no longer stalls startup.

Added

  • docs/DOCKERHUB.md, the Docker Hub overview page. docker-build-push.sh
    now publishes it, with the short description, after each push, and
    --overview-only updates the page without building.

Images

  • Docker Hub: jeffcaldwellca/mkcertweb:5.0.1 (also 5.0, 5, latest)
  • GHCR: ghcr.io/jeffcaldwellca/mkcertweb:v5.0.1

mkcert Web UI 5.0.0

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 30 Oct 00:05
ae050ef

mkcert Web UI 5.0

Docker: docker pull jeffcaldwellca/mkcertweb:5.0.0 · ghcr.io/jeffcaldwellca/mkcertweb:v5.0.0 — upgrading from 4.4.x? Read Upgrading from 4.4.x below first.

Highlights

  • Split-pane dashboard. Every page has a top bar (page tabs, mkcert / CA /
    openssl status, user, theme) with a list pane on the left and a detail pane
    on the right. The certificates page groups certificates as needs attention,
    healthy, read-only and archived, has a quick-generate command bar and a
    filter, and shows overview, files and notes tabs for the selected
    certificate. The selection is kept in the URL.
  • Root CA and notifications pages. The root CA (details, download, install
    guide, generate) and the notification channels (email, ntfy, webhook,
    monitoring, with their test actions and the expiring list) moved off the
    certificates page onto their own pages.
  • Settings page with a section list, a setting search, the config key on
    every field, unsaved-change tracking (edited sections, discard, a
    leave-page warning) and the running configuration.
  • SCEP page rebuilt: service URLs with copy buttons, enterprise CA status,
    templates, and challenges / issued / manual enroll / mdm setup tabs. A new
    challenge password is shown once.
  • Light and dark themes on every page, including login, and a layout that
    works down to phone width.

Upgrading from 4.4.x

  • Docker: the image's HEALTHCHECK and the compose health check now
    probe /api/health instead of /; change any custom health check the same
    way. Set TRUST_PROXY to your reverse proxy's address as the container sees
    it (see docs/DOCKER.md).
  • docker run: add -v mkcert_config:/app/config so settings saved in
    the UI (config/settings.json) survive recreating the container, as
    docker-compose.yml and npm run docker:run now do.
  • systemd: the unit moved to deploy/mkcert-web-ui.service and keeps
    the CA in /var/lib/mkcert-web-ui/ca. Before starting it, copy the existing
    rootCA.pem and rootCA-key.pem there (or mkcert creates a new CA), then
    create the directories it writes to:
    cd /opt/mkcert-web-ui && sudo install -d -o www-data -g www-data certificates config data ssl.
    See deploy/README.md.
  • ENABLE_OIDC=true without ENABLE_AUTH=true: the settings API and
    mkcert -uninstall (POST /api/uninstall-ca, and uninstall-ca in
    POST /api/execute) now return 403. Set ENABLE_AUTH=true; without it
    there was never a login, OIDC or otherwise.
  • FORCE_HTTPS=true now redirects pages, assets and API calls: 301 for
    GET and HEAD, 308 for other methods. Only /api/health and /scep are
    exempt. Scripts that call the API over http:// must switch to https://.
  • API clients:
    • The removed endpoints and response fields listed under Breaking are gone;
      use the replacements given there.
    • Archive and restore return 409 TWIN_EXISTS instead of overwriting a
      same-name copy; restore takes ?swap=true to exchange the two.
    • ?archived and ?swap accept only true or false (anything else is a 400).
    • DELETE /api/certificates/:folder/:certname removes one copy only (see
      Breaking for which one).
    • GET /api keys are now "METHOD /path".
    • Every JSON 500 body is a fixed error message plus a ref (and a short
      reason on a few routes). Don't parse the error text; look up the ref
      in the server log.
    • Status codes: archive when the active files are gone → 404 (was 200);
      restore when the archived files are gone → 404 (was 200); an unexpected
      upload failure → 500 (was 400); a malformed JSON body → 400 (was 500); an
      oversized body → 413 (was 500).
  • UI: uploaded and SCEP-issued certificates are view-only. The root-ca
    page's install button really runs mkcert -install on the server (it needs
    root, so it fails in Docker and under the systemd unit; install the CA on
    clients instead). An archived certificate with an active copy of the same
    name shows their shared note read-only; edit it on the active copy (see
    Known issues).

Breaking

  • Removed endpoints (they now return 404): GET /api/files,
    GET /api/file/:filename/content, GET /download/:filename,
    GET /api/certificate/:filename, DELETE /api/certificate/:filename and
    GET /api/commands. Use /api/download/{cert,key,bundle}/:folder/… and
    /api/certificates/:folder/:certname.
  • GET /api index format. endpoints.<group> keys are now
    "METHOD /path" with a description as the value (was "/path": "METHOD - …",
    which also lost one of two routes sharing a path). The index lists every API
    route.
  • Same-name archived and active certificates are never overwritten:
    • DELETE /api/certificates/:folder/:certname deletes exactly one copy:
      ?archived=true the archived one, ?archived=false the active one, no
      parameter the active one if present, else the archived one. It used to
      delete both. The response adds scope.
    • POST …/restore returns 409 TWIN_EXISTS when an active copy exists,
      instead of overwriting it; ?swap=true exchanges the two copies.
    • POST …/archive returns 409 TWIN_EXISTS when an archived copy exists,
      instead of overwriting it.
  • ?archived and ?swap accept only true or false; anything else is a 400.
  • A certificate name that decodes to a path (e.g. a double-encoded
    archive%252F<name>) is rejected with 400.
  • Uploaded and SCEP-issued certificates are view-only in the UI (no download,
    PFX, archive or notes buttons); the server's per-certificate routes never
    accepted their folders.
  • Removed response fields that exposed server paths and that the UI
    never read: command and certificateDir from POST /api/execute
    (generate); the absolute path of each file in GET /api/certificates
    (relativePath stays); workingDirectory from GET /api/system;
    publicCACertPath from POST /api/generate-ca; and from the public
    GET /api/status: caRoot, ca.root, server.pid, server.memory,
    server.version and environment.workingDir (features.oidc is now a
    boolean).
  • systemd unit moved to deploy/mkcert-web-ui.service and now keeps the
    root CA in /var/lib/mkcert-web-ui/ca. When upgrading, copy rootCA.pem
    and rootCA-key.pem from the service user's old mkcert directory there
    first, or mkcert creates a new CA (see deploy/README.md).
  • FORCE_HTTPS=true redirects everything over plain HTTP (pages, assets,
    API calls), with 308 for methods other than GET and HEAD, except
    /api/health and /scep. It used to reach only unknown paths, and it
    trusted X-Forwarded-Proto from any client; now only from TRUST_PROXY
    (see Fixed).
  • The settings API and uninstall-ca return 403 unless ENABLE_AUTH=true,
    even with ENABLE_OIDC=true (see Security).
  • Health check path: the Docker and compose health checks probe
    /api/health, not /.
  • Archive returns 404 when the active files are gone (it returned 200), and
    restore returns 404 when the archived files are gone (it returned 200 and
    moved nothing).
  • Error bodies and status codes: every JSON 500 is a fixed message plus a
    ref (no error text, and no stack with NODE_ENV=development); unexpected
    upload failures are 500 (were 400); malformed JSON is 400 and an oversized
    body 413 (both were 500); a broken multipart upload is 400 Malformed upload.
    See Security and the upgrade checklist above.

Added

  • TRUST_PROXY environment variable: which proxies may set
    X-Forwarded-For / X-Forwarded-Proto (true, false, a hop count, or
    addresses, CIDRs and loopback/linklocal/uniquelocal). The default is
    the previous hard-coded loopback,linklocal,uniquelocal, so existing
    proxy-container setups keep working; that default trusts every private-LAN
    client, so set it to your proxy's address as the app sees it (in Docker,
    usually the network gateway or the proxy container's IP; see
    docs/DOCKER.md).

Changed

  • Accessibility: focus returns to a sensible place after every re-render;
    status dots and channel states carry text, not only colour; toasts are
    announced through live regions (errors stay until dismissed); sub-tabs work
    with the arrow keys.
  • Content-Security-Policy: script-src and style-src are 'self' only, with
    no unsafe-inline and no CDN origin. No page has inline scripts, styles or
    event handlers, and guard tests keep it that way.
  • Font Awesome is gone; icons are text glyphs. No page loads anything from
    another origin.
  • The root-ca page's install button calls POST /api/install-ca, which always
    runs mkcert -install. The old path reported success without installing
    when the CA files already existed.
  • Least-privilege systemd unit: the code tree is read-only to the service,
    writes are limited to certificates/, config/, data/ and ssl/, and the
    CA lives in the unit's state directory.
  • Uploads are staged in a private directory under the OS temp dir instead of
    the working directory.
  • data/ (certificate notes) is git-ignored.
  • The unused asn1js dependency is removed.
  • Pages link the favicons and web manifest; /favicon.ico redirects to
    /assets/favicon.ico.
  • CI runs npm ci and npm test on Node.js 22 (the engines minimum) for
    pull requests and pushes to main; the Docker scan and publish jobs wait
    for it.
  • package.json: the env script is gone (server.js loads .env itself),
    docker:run mounts the mkcert_config volume like docker-compose, the
    compose:* scripts use docker compose, and the license (GPL-3.0-only)
    and repository fields are set.
  • ...
Read more

mkcert Web UI 4.4.3

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 29 Oct 12:00

Fixed

  • CA generation failed when running as a custom UID (#54). With e.g.
    user: "2000:2000", the UID has no passwd entry, Docker sets HOME=/, and
    mkcert tried to create /.local/share/mkcert. The image now sets
    CAROOT=/home/nodejs/.local/share/mkcert, so the CA path no longer depends
    on HOME. docs/DOCKER.md documents running as a custom UID.

Security

  • Dependency updates for four advisories. npm audit is clean again:

Images

  • Docker Hub: jeffcaldwellca/mkcertweb:4.4.3 (also 4.4, 4, latest)
  • GHCR: ghcr.io/jeffcaldwellca/mkcertweb:v4.4.3

mkcert Web UI 4.4.2

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 15 Oct 04:00

Fixed

  • "Generate Root CA" success message. The UI shows "CA Certificate copied
    to public download area" when the response has caCopiedToPublic, but the
    API never sent it, and the detailed success alert was passed through the
    HTML-escaping showAlert, so its formatting showed as literal <strong> /
    <br> tags. POST /api/generate-ca now returns caCopiedToPublic (whether
    the CA certificate is in certificates/ afterwards), and the alert renders
    as HTML with the CA path escaped.

Images

  • Docker Hub: jeffcaldwellca/mkcertweb:4.4.2 (also 4.4, 4, latest)
  • GHCR: ghcr.io/jeffcaldwellca/mkcertweb:v4.4.2

mkcert Web UI 4.4.1

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 15 Oct 02:57

Fixed

  • "Generate Root CA" reported failure in Docker. POST /api/generate-ca
    ran mkcert -install, which creates the CA and then adds it to the system
    trust store. The second step needs root, which the container's nodejs
    user doesn't have, so the request returned 500 even though the CA had been
    created (and the CA certificate was never copied to certificates/ for
    download). The trust-store step is now best-effort: the endpoint succeeds
    when the CA files exist, copies the CA for download, and returns
    trustStoreInstalled: false with a message explaining it.
  • Wrong version in /api/health and /api under Docker (4.4.0
    regression).
    The version came from npm_package_version, which isn't set
    now that the image starts with node server.js, so it showed 1.0.0. It's
    now read from package.json.

Images

  • Docker Hub: jeffcaldwellca/mkcertweb:4.4.1 (also 4.4, 4, latest)
  • GHCR: ghcr.io/jeffcaldwellca/mkcertweb:v4.4.1

mkcert Web UI 4.4.0

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 15 Oct 02:47

Security

  • Docker image hardening (#46). A Trivy scan of the 4.3.4 image reported
    ~370 findings, mostly from the image rather than the app:
    • mkcert is now built from the v1.4.4 source with Go 1.27 and current
      golang.org/x/{crypto,net,text} instead of using the 2022 release
      binary (Go 1.18). This accounted for all critical findings.
    • Base image moved from node:20-alpine (end-of-life 2026-04-30) to
      node:24-alpine, with apk upgrade for Alpine security fixes.
    • npm, npx, corepack and yarn are removed from the runtime image; the
      container now starts with node server.js.
    • CI scans every build with Trivy (fails on fixable critical findings) and
      rebuilds weekly so base-image patches reach :latest.
  • Dependency updates: nodemailer 10.1.1, multer 2.4.0, proxy-addr 2.0.8
    (IP spoofing via IPv4-mapped IPv6 with trust proxy), qs 6.16.1,
    brace-expansion 2.1.7.
  • Code fixes: ReDoS in filename validation; POST /scep rate-limits
    before parsing the request body; SCEP certificate paths are validated
    against traversal; page and OIDC routes are rate-limited.

Changed

  • Node.js 22 or newer is required to run outside Docker (nodemailer 10
    needs Node 20+, and Node 20 is end-of-life).

Images

  • Docker Hub: jeffcaldwellca/mkcertweb:4.4.0 (also 4.4, 4, latest)
  • GHCR: ghcr.io/jeffcaldwellca/mkcertweb:v4.4.0

mkcert Web UI 4.3.4

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 31 Aug 22:22

Fixed

  • UI-saved settings lost on container recreation (#45). The sample
    docker-compose.yml persisted /app/certificates, /app/data, and the
    mkcert root CA, but not /app/config — where settings saved from the web
    UI (config/settings.json: webhook, email/ntfy notifications, theme, ...)
    are stored. Pulling a new image therefore wiped them. The compose file now
    mounts a mkcert_config volume at /app/config, and the manual
    docker run example in docs/DOCKER.md includes the config and CA
    volumes.

    Upgrading an existing deployment: add the volume to your compose file
    before recreating the container —

    services:
      mkcert-web-ui:
        volumes:
          - mkcert_config:/app/config
    volumes:
      mkcert_config:
        driver: local

Documentation

  • Documented the certificate-expiry notification environment variables
    (WEBHOOK_ENABLED, WEBHOOK_URL, NTFY_*, EMAIL_NOTIFICATIONS_ENABLED,
    CERT_MONITORING_*) in the sample docker-compose.yml and
    docs/DOCKER.md — they existed but were not documented anywhere (#45).
  • Corrected docs/SETTINGS.md, which still described the pre-4.0.0
    precedence order: explicitly-set environment variables override
    config/settings.json, not the other way around.
  • Fixed the theme variable name in docs/DOCKER.md (THEME_MODE, not
    DEFAULT_THEME).

Full Changelog: v4.3.3...v4.3.4

mkcert Web UI 4.3.3

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 23 Aug 05:58

Security

  • Prototype pollution via upload filenames (CodeQL #169–171). /api/upload
    grouped files in a plain object keyed by the uploaded base name, so a file
    named __proto__.pem wrote its multer file object onto Object.prototype
    (({}).cert). Grouping now uses a Map. Regression test added.
  • Companion-file deletion in DELETE /api/certificate/:filename now re-runs
    path containment on the derived -key.pem/.pem name instead of relying
    on the primary filename's validation (CodeQL #104).

Full Changelog: v4.3.2...v4.3.3

mkcert Web UI 4.3.2

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 23 Aug 05:45

Fixed

  • OIDC/SSO login bounced straight back to the login page (#43). After a
    successful OIDC callback, passport stored the user in the session and GET /
    served the app, but /api/auth/status only recognised username/password
    sessions (req.session.authenticated), so the frontend's auth check saw
    authenticated: false and redirected to /login. Auth state is now computed
    by one helper (src/utils/authState.js) that understands both basic-auth
    sessions and passport logins, and is used by /api/auth/status, GET /,
    GET /login, and requireAuth. The OIDC display name (falling back to
    email) is now shown as the logged-in user.

  • OIDC failures are now logged. The callback uses a custom passport
    callback so the strategy's reason (issuer mismatch, bad nonce, expired
    token, ...) is written to the server log instead of being swallowed by the
    redirect to /login?error=oidc_failed. The login page also shows a
    dedicated "single sign-on failed" message for that error.

  • OIDC issuer taken from discovery. passport-openidconnect compares the
    ID token's iss claim with strict equality, so a trailing-slash difference
    between the configured issuer and what the provider advertises (authentik
    includes one; Keycloak/Entra don't) silently failed login. The strategy now
    uses the discovery document's issuer and warns at boot when it differs
    from the configured value.

  • Rate limiters now key per-user buckets for OIDC logins too (they looked for
    req.user.username, which passport users don't have, so SSO users shared
    the per-IP anonymous bucket).

  • Removed a duplicate, un-rate-limited /api/auth/methods route that shadowed
    the rate-limited one whenever auth was enabled.

Added

  • RP-initiated OIDC logout. When the provider advertises an
    end_session_endpoint, logging out of an SSO session now also redirects the
    browser to the provider to end its session (with id_token_hint and a
    post_logout_redirect_uri back to /login), so "Login with SSO" no longer
    silently signs the user straight back in. Register <origin>/login as an
    allowed post-logout redirect URI with your provider.

Security

Removed

  • Dead src/routes/auth.js and src/middleware/auth.js (never required by
    server.js; they carried an older copy of the same auth logic and the same
    OIDC status bug).

Changed

  • /api/auth/logout no longer calls req.logout() after destroying the
    session — destroying the session already drops the passport user, and the
    extra call only produced a spurious "session support" error in the log.

Full Changelog: v4.3.1...v4.3.2

mkcert Web UI 4.3.1

Choose a tag to compare

@jeffcaldwellca jeffcaldwellca released this 17 Jul 06:55

A dependency-security release clearing all seven open Dependabot alerts. No application code changes.

Security

  • multer 2.1.1 → 2.2.0 — fixes two denial-of-service vectors in multipart parsing: crash via deeply nested field names (GHSA-72gw-mp4g-v24j, high) and disk exhaustion from incompletely cleaned-up aborted uploads (GHSA-3p4h-7m6x-2hcm, moderate). These were the only alerts with real exposure: /api/upload is reachable with a fetchable CSRF token when authentication is disabled (the Docker default).
  • nodemailer 8.0.7 → 9.0.3 — clears GHSA-p6gq-j5cr-w38f (high) plus three moderate advisories. None were exploitable as used (the email service never uses the raw option, jsonTransport, List-* headers, or OAuth2), but the fix for the high only exists on the 9.x line. The API surface the app uses (createTransport/sendMail/verify) is unchanged.
  • form-data 4.0.5 → 4.0.6 (dev-only, via axios) — CRLF injection in multipart names (GHSA-hmw2-7cc7-3qxx); test-suite exposure only.

npm audit now reports 0 vulnerabilities across all dependency scopes.

Full Changelog: v4.3.0...v4.3.1