Files
wekan/docs/Features/Admin-Panel/Validation.md
T
Lauri Ojansivu ac856dd38f Cloud Panel: only with the CLOUD environment variable; its Cloud Admins, customer login, support boards and allowed addresses.
CloudPanelBleed. Any site administrator of any WeKan could set the Cloud
Panel Domain and its SuperAdmin in Admin Panel / People / Cloud and then
make the server connect to any MongoDB server with credentials of their
choosing - Test connection and Import build a MongoClient from the
domain's database settings. A customer is the administrator of their own
WeKan container, so a customer could reach MongoDB servers on the internal
network.

The Cloud Panel now exists only where the server has CLOUD=<its domain>
(models/lib/cloudPanel.js cloudDomainFromEnv). The domain is never read
from the database, the browser or the REST API; the People / Cloud pane is
gone and cloudPanelGetSettings / cloudPanelSetSettings always refuse. Every
cloudPanel* method except cloudPanelWhoAmI passes the CLOUD gate before
anything else, its argument checks included, and the one MongoClient built
from data that is not the environment (withSource) has the gate in its own
body. A refusal is recorded in Admin Panel / Problems under the new keys
authz.cloud-panel-off, authz.cloud-panel-access and
authn.cloud-admin-address (bleed CloudPanelBleed; none disables an
account).

- Cloud Admins: on the CLOUD container its site administrators - the first
  registered user is one - not disabled, never a customer's account. They
  have Admin Panel / Cloud (/admin/cloud/<pane>, a tab shown only for a
  Cloud Admin at the CLOUD address): Domains, Invoices, Tickets, Chat,
  Cloudflare, Caddy, Allowed addresses. /cloud stays the customers' panel.
- Customer login: a password login handler, ahead of accounts-password's
  and after the timing normalization, only at the CLOUD address, only for a
  name exactly one domain with its own database lists, never for a name an
  account of the panel's own has. The password is checked against that
  customer's own database hash with Accounts._checkPasswordAsync, under an
  id no local account has; a disabled or password-less account there is
  refused, and so is a wrong 2FA code. On success a local non-admin account
  without a password, services.cloudCustomer, which sees exactly its own
  domain: info, invoices, tickets and chat.
- Support boards: one WeKan board per domain, "Support: <domain>", lists
  Open / In progress / Done for tickets and Chat with one card whose
  comments are the support chat (Board View / Chat shows them as a chat).
  Cloud Admins are board admins, customers Comment only: they read and
  comment but cannot create, edit, move, archive or delete a card nor
  manage the board; the panel adds their tickets into Open. The earlier
  cloudChatMessages are moved once into the chat card; imported
  Rocket.Chat and SandChat conversations go there too.
- Allowed addresses: IPv4, IPv6 and CIDR ranges (models/lib/cloudAddresses.js).
  When set, a Cloud Admin login (resume included) from elsewhere is refused
  and recorded, and so is a Cloud Admin method. A list without the saver's
  own address is refused; CLOUD_ADMIN_ANY_ADDRESS=true sets it aside for a
  locked-out operator.

Tests: tests/cloudPanel.test.cjs, tests/cloudAddresses.test.cjs,
tests/cloudPanelAccess.test.cjs (the real methods and login handler without
and with CLOUD), tests/cloudPanelGate.test.cjs (the MongoClient source scan),
server/lib/tests/cloudPanel.security.tests.js and
tests/playwright/specs/cloud-panel.e2e.js (negative without CLOUD; the
positive part runs with CLOUD=localhost WEKAN_TEST_CLOUD=true). The guards
that pin board inserts, comment inserts, card-reading paths, copy/move
methods, the Admin Panel tabs and method areas list the panel's support
board and its methods, with the reason.

Thanks to xet7 !
2026-11-22 18:49:51 +02:00

19 KiB

Admin Panel implementation validation

Audit against the September 2026 source, which then had 48 pane routes. The pane routes are defined by adminUrls.js, and the tables below follow its current list in menu order - tests/adminPanelDocsMatchMenu.test.cjs fails when a pane is missing from them or in a different order. A visible menu entry alone is not proof that its action works: the table identifies its implementation and the boundaries of this validation.

Findings and fixes

Scheduled backups registered jobs but the shared scheduler was never started. The daily expression was also rejected by the bundled scheduler parser and produced a partial first-of-month schedule; daily backups now use its supported time expression and refuse parser errors. The old whole-instance archive excluded attachment/avatar metadata and GridFS collections; restore also suppressed database write failures. The repair starts the scheduler, includes all application collections with BSON types and indexes, and streams selected attachment/avatar versions through their storage readers. Export and restore use Meteor's own BSON driver to avoid incompatible BSON objects between driver versions. A versioned manifest verifies payload hashes before restore and file metadata is rebased to the destination storage path. Failed jobs report errors.

The Backup form now reloads its saved file selections and destination, validates schedules and displays save/list errors. A complete backup requires all three content selections and Whole instance scope. Organization backups deliberately exclude global accounts/settings and are not full-instance backups.

Evidence and limits

  • Source inspection follows menu templates, event handlers, server methods, publications and permissions. No active pane is an empty placeholder.
  • All 70 focused Node regression suites pass and exercise settings, administration, permissions, storage policy, reports and backup scheduling.
  • Nine real FerretDB round-trip and failure checks pass, covering accounts, BSON values, dotted GridFS collections, indexes, empty collections, relocated file bytes, add-missing behavior and rejected corrupt/incomplete backups.
  • The browser suite exercises the actual timer, backup/restore controls and file downloads, rejects non-admin backup operations, and visits every pane. Visiting a pane proves rendering; it does not prove every possible action.
  • Another 21 Chromium checks pass for user management, report filters, mail setting persistence and secret masking, instrumentation and office locations.
  • External LDAP/OAuth/SMTP accounts, S3/Azure/GCS endpoints, device PWA installation, MongoDB compaction and a two-database migration require their own live-service tests. Their implementations exist; this audit does not claim those deployments were exercised.

The old unused attachmentSettings template and its obsolete S3 handler names are not reachable from the current Admin Panel menu. Current storage panes use testAttachmentCloudConnection and updateAttachmentStorageSettings.

Settings

Pane / URL slug Implementation Behavior and limits
Version (version) informationBody.js Live version/runtime information; read-only.
Appearance (appearance) tableVisibilityModeSettings.js Saved All Boards visibility, branding and date defaults; server permissions apply. Was Visibility (2026-11-19).
Features (features) instanceFeatures.js Instance features, card fields, pilot users, SQRL, ActivityPub, Rules and Optional APIs; site-admin-only methods.
Feature profiles (feature-profiles) featureProfiles.js Opt-in profiles hiding features from users, teams and organizations; saved by the site-admin-only saveFeatureProfiles.
Security (security) settings.js Rich-text and import/export policies, enforced by renderers and server guards. Was Problems / Security.
Activities and notifications (activities) settings.js Activity, notification and watching switches; separate from delivery preferences. Was Problems / Notifications.
Delete (delete) settings.js Explicit administrator permanent-delete setting; purge remains a separate action. Was Problems / Delete.
Announcement (announcement) announcements.js Saved banner content and visibility; rendered through announcement controls.
Accessibility (accessibility) accessibilitySettings.js Saved accessibility content and configuration.
Translation (translation) translation.js Add/edit/delete custom translation records with administrator checks.
PWA (pwa) settingBody.js Saved head/manifest/assetlinks configuration; device installation requires a device check.
Global Webhooks (global-webhooks) outgoing.js Global integration configuration and event delivery; endpoint delivery requires a configured receiver.
Shared labels (labels) sharedLabels.js Site-admin catalog edits reach every board copy; tests/sharedLabels.test.cjs and its runtime suite.

People

Pane / URL slug Implementation Behavior and limits
Login (login) settings.js General sign-in and registration controls.
SAML (saml) saml.js Provider overrides and configuration-source/service-URL reporting; external IdP sign-in needs a configured provider.
LDAP (ldap) authConfig.js Every LDAP_* setting from the login settings catalog, Admin Panel value first; secret never sent to the browser; connection test. Directory integration needs a test directory.
OAuth2 (oidc) authConfig.js Every OAUTH2_* setting (OpenID Connect, Oracle OIM); the service configuration is rewritten on save. Live-provider flows need credentials.
CAS (cas) authConfig.js Every CAS_* setting; the service configuration is rewritten on save. Live CAS sign-in needs a CAS server.
Header login (header-login) authConfig.js Every HEADER_LOGIN_* setting, read per request; still fails closed without trusted IPs. Needs a trusted reverse proxy to exercise.
OAuth (oauth) peopleBody.js OAuth provider settings; live-provider flows need credentials.
Passwordless (passwordless) peopleBody.js Passwordless authentication settings, separate from the Login pane.
E-mail (email) settings.js Mail service settings, secret masking and test-email method; delivery needs a configured SMTP/provider account.
Notifications (notifications) settings.js Site defaults through setAdminNotifyDefault; used by notification resolution.
Domains (domains) peopleBody.js Server-backed domain membership counts, search and pagination.
Organizations (organizations) tenant.js Organization membership, tenant fields and administrator scope.
Teams (teams) team.js Team records and membership operations; scoped server permissions.
People (people) users.js Create/edit, roles, password/email operations, impersonation and removal.
Locked Users (locked-users) lockedUsers.js Locked-account listing and administrator unlock methods.
Audit log (audit-log) adminAudit.js New: every administrative method a site administrator calls, one document each for a year, secrets redacted; site administrators only. Real wrapper in adminAudit.test.cjs.
Roles (roles) inviteToBoardRolesSettings.js Invitation-role defaults and per-role settings.
Shared Templates (shared-templates) users.js Shared-template administration with tenant boundaries.

Attachments

Pane / URL slug Implementation Behavior and limits
Backup (backup) backup.js Repaired: scheduler startup, full database/file archive, checksums, portable paths and error handling. See Backup.md.
Continuous backup (continuous-backup) continuousBackup.js New: streams database (oplog or SQLite pages, optional Litestream), attachments, avatars and logs; point-in-time restore verified before writing. Unit, real-database integration, server-method and Chromium/WebKit UI tests. See Continuous-Backup.md.
Move Attachment (move) attachmentBulkMove.js Persisted move jobs, progress, pause/resume/cancel and location repair. Cloud endpoints require live-service tests.
Default Save Storage (default-save-storage) attachmentStorageSettings.js Validates backend and persists default for new files.
Limits (limits) attachmentStorageSettings.js Saves size/blocking policies used by upload/download routes.
Retention (retention) attachmentRetention.js New (#6789): the shared override form on the catalog's attachmentRetention section; the nightly job soft-deletes through the card's Delete and purges through Attachments.removeAsync. Rules in attachmentRetention.test.cjs; the pane in a Chromium/Firefox/WebKit UI spec.
MongoDB GridFS Storage (gridfs) fileStoreStrategy.js Native GridFS read/write and metadata statistics; compaction requires actual MongoDB, not SQLite.
Filesystem Storage (filesystem) fileStoreStrategy.js Filesystem read/write strategies and metadata statistics.
S3/MinIO Storage (s3) cloudStorage.js Real S3 adapter, connection test and secret-preserving settings; configured live storage not exercised here.
Azure Blob Storage (azure) cloudStorage.js Real Azure adapter and connection test; configured live storage not exercised here.
Google Cloud Storage (gcs) cloudStorage.js Real GCS adapter and connection test; configured live storage not exercised here.
WebDAV (Nextcloud Files) (webdav) webdavAdapter.js WebDAV adapter (PUT, GET, DELETE, PROPFIND, MKCOL) and its address rules in webdavStorage.test.cjs; a live Nextcloud not exercised here.
Database migration (database-migration) migrateTextDatabase.js Migration process/status and verification; needs source and destination databases for an end-to-end migration.

Problems

Pane / URL slug Implementation Behavior and limits
Summary (summary) systemStatus.js Actual startup/login checks, active migrations and problem streams.
Backup (backup) backup.js Recorded backup runs, health of the instance backup and its history (backupHistory method); settings stay in Attachments / Backup.
Security Report (security-report) eventLog.js Recorded security events, search, detail and acknowledgement.
Impersonation Report (impersonation) impersonationReport.js Scoped event publication and counts.
Password length (password-length) shortPasswordLogins.js The minimum password length and whether it is enforced, saved as Login settings; one row per account that signed in with a shorter password, reported by its browser, with the Too short / Fixed / All filter.
Performance (performance) adminProblems.js Persisted performance options; card loading uses the active loading policy.
Speed (speed) eventLog.js Recorded speed events; no events is a valid empty report.
Tests (tests) eventLog.js Recorded test results; opening the pane does not run every repository test.
CPU usage (cpu) systemStatus.js CPU detail and recorded governor events.
Memory usage (ram) ramMonitor.js Live RAM and swap, and recorded high-memory periods.
Disk usage (disk) diskMonitor.js Live use of each filesystem WeKan writes to, and recorded high-usage periods.
Instrumentation (instrumentation) instrumentationReport.js Local Meteor operation counters; no external telemetry upload.
Broken Cards (broken-cards) repairBrokenCards.js Broken-card repair and reports, with administrator checks.
Files (files) fileStatusAudit.js Read-only file/status/type/history scans and report data.
Rules (rules) rules.js Rules report subscriptions, search and pagination.
Boards (boards) boards.js Board report with server-side visibility filtering.
Cards (cards) cards.js Card report with server-side counts and pagination.
Recovery (recovery) recovery.js Recorded maintenance/recovery events and actions; actual corruption recovery is a separate destructive scenario.
Offices (office) loginOffices.js People/address counts, location summaries and IPv4/IPv6 evidence.
API (api) eventLog.js Recorded REST endpoint usage and actors.
Database problems (database) databaseProblems.js Database event ingestion/classification and problem reporting.
Filesystem integrity (integrity) fileIntegrityScan.js Integrity scans/baselines plus file-status audit; scans report their coverage limits.
Email (mail) mailProblems.js Sends the mail server refused, IMAP mailboxes that cannot be read, unreadable email and email for a board that no longer takes it - one folded row per kind; runtime-tested against local SMTP and IMAP servers.

Cloud

Admin Panel / Cloud exists only where the server has CLOUD; it is not one of the four pages this audit follows. cloudPanel.js refuses every method without CLOUD and records the attempt; the real methods, the customer login, the support boards and the allowed addresses are in cloudPanelAccess.test.cjs, the gate in cloudPanelGate.test.cjs (Cloud Panel).

Reproduce the checks

Run the focused Node suites with node tests/run-node-suites.cjs and the relevant suite-name filters. The database integration test is fullBackup.test.cjs: set WEKAN_BACKUP_TEST_MONGO_URL to an isolated MongoDB/FerretDB instance. It creates and deletes only fresh randomly named test databases.

The browser checks are in admin-full-backup.e2e.js. Use an isolated app and database, set WEKAN_BASE_URL, WEKAN_MONGO_URL and WEKAN_BACKUP_TEST_FILES_ROOT to that app's local files directory, then run that spec with the repository Playwright configuration. The backup test restores all collections in that test instance; never point it at a working installation.

See Backup for supported procedures and limitations.

Commits