Commit graph

175 commits

Author SHA1 Message Date
c6ef40a088 Add checker interface: api routes and frontend to manage user checker 2026-03-16 23:09:09 +07:00
857745b19b web-admin: Implement checkers interface with option editor 2026-03-16 23:08:55 +07:00
f16ae2991e fix: refresh ButtonZonePublish after zone apply
All checks were successful
continuous-integration/drone/push Build is passing
2026-03-16 21:00:35 +07:00
72fa2b3904 fix: wire ActionOnEditableZone into all zone mutation facades
All checks were successful
continuous-integration/drone/push Build is passing
Add/update/delete service calls in the Service facade were bypassing
ActionOnEditableZone, so mutations could silently target a committed or
published zone instead of deriving a new editable snapshot first.

Wraps AddServiceToZone, RemoveServiceFromZone, and UpdateZoneService
with ActionOnEditableZone so the decorator is applied consistently.

Fixes regression introduced by b2b6467575.
2026-03-16 20:07:47 +07:00
a7b225b9df Rework zone diff/apply flow: separate diff from provider API, support partial apply
Decouple diff computation from executable provider closures by fetching
provider records and computing diffs locally via DNSControlDiffByRecord.
On apply, build a target record set from user-selected corrections using
BuildTargetRecords, then ask the provider for executable corrections
against that target. A published snapshot is inserted at ZoneHistory[1]
while the WIP zone at position 0 remains unchanged.
2026-03-16 19:46:09 +07:00
8a2a28e4be providers: Mark secret fields with secret tag; add eye toggle for secret inputs
All checks were successful
continuous-integration/drone/push Build is passing
Also fix a typo in oracle.go label ("Private hey" → "Private key").
2026-03-16 19:44:14 +07:00
e341ea6beb chore(deps): lock file maintenance 2026-03-16 19:44:14 +07:00
9203e71494 web: Rename /join route to /register for clarity 2026-03-16 19:44:14 +07:00
36a7d8e9d3 Fix email validation HMAC weakness and prevent user enumeration on registration 2026-03-16 19:44:14 +07:00
07b5553369 Add public DNS record generator pages at /generator
Expose service editors publicly (no auth required) at /generator for
SEO discoverability. Each page shows an interactive editor alongside
a live DNS zone record preview powered by a new POST
/service_specs/:ssid/records backend endpoint.
2026-03-16 19:44:13 +07:00
572b4ea167 web: New helper domainJoin, fix OpenPGPKEY and SMIMECERT records when dn is empty 2026-03-15 21:35:45 +07:00
89362f473f ci: fix yarn v1 vite hoisting issue for vitest on amd64
All checks were successful
continuous-integration/drone/push Build is passing
2026-03-15 17:40:15 +07:00
943d9b2a0c web: Add drag-and-drop domain group reassignment in ZoneList
When display_by_groups is enabled, domains are now draggable and group
containers act as drop targets. Dropping a domain onto a different group
updates its group via the API and refreshes the domain list.
2026-03-15 17:40:15 +07:00
b4ad9f8092 fix: preserve post-login redirect destination through OIDC flow
The next query parameter was silently dropped when users chose OIDC
login, always redirecting to / after authentication. Forward the
validated next value to /auth/oidc, store it in the session during
redirect, and use it for the final redirect in the callback, matching
the behaviour of password-based login.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 15:03:56 +07:00
d979ccefe6 security: validate next redirect parameter to prevent open redirect
Decode and validate the next query parameter before navigating,
ensuring it is a same-origin relative path (starts with / but not //)
to prevent attackers from redirecting users to external sites after login.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 15:03:56 +07:00
ca206cf24e fix: make updateSession reject calls without an id
The function silently fell back to creating a new session when session.id
was falsy, which could create unintended API tokens from a partial object.
Session creation is already handled by addSession(); updateSession() now
throws early when no id is present.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 15:03:49 +07:00
b0b79efceb security: decouple failure tracking from captcha provider
Previously, RecordFailure/RecordSuccess were only called when a captcha
provider was configured, making brute-force tracking entirely inactive
on deployments without one.

- Always track login failures and successes regardless of captcha config
- When threshold is crossed with a captcha provider: 401 + captcha_required (existing behaviour)
- When threshold is crossed without a captcha provider: 429 + rate_limited flag
- Frontend: show a rate-limited message and disable the submit button on 429
- Add errors.rate-limited translation key to all locales

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 15:03:49 +07:00
dcde50f56a web: Highlight current session with a Badge 2026-03-11 18:30:41 +07:00
6565b25473 fix: use first 6 bytes of SHA-256 for session fingerprint display
SHA-1 is cryptographically broken. Replace with SHA-256 and slice to
the first 6 bytes (12 hex chars) for a compact, human-readable token
fingerprint. 48 bits is more than sufficient to distinguish a handful
of active sessions without sacrificing readability.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-11 18:30:41 +07:00
36890cc432 web: Fix infinite loop on 401 when user is not logged in 2026-03-11 18:30:41 +07:00
d99e31d587 web: Increase margin under root domain name 2026-03-11 18:30:41 +07:00
8cf643131d web: fix ServiceCombined JSON serialization for new service creation 2026-03-11 18:30:41 +07:00
54857e19c6 web: cache zone diff API results to avoid redundant network calls 2026-03-06 14:43:09 +07:00
7b8e6600fe web: replace /domains/new navigation with PickProvider modal
Introduces ProviderPicker and PickProvider reusable components so that
adding a domain from NewDomainInput or FilterDomainInput opens an
inline provider-selection modal instead of navigating away to
/domains/new/:dn.
2026-03-06 14:43:09 +07:00
e8af55a989 web: display onboarding form on home page with ?onboarding 2026-03-06 14:43:09 +07:00
03be1f7348 web: replace domains home page with an interactive table 2026-03-06 14:43:09 +07:00
0677b82dfc web: relook provider edit page and add provider sidebar 2026-03-06 14:43:09 +07:00
5f6b9a22b9 web: sync home filter state with URL query params 2026-03-06 14:43:02 +07:00
2e7713fec0 web: Format files and remove unused dependencies 2026-03-06 12:44:15 +07:00
827a92e77e web: replace providers list with an interactive table
Replace the ListGroup-based provider list with a Bootstrap Table on the
providers page. Rows are clickable to edit, the domain count links to
the domains page pre-filtered by provider, and action buttons handle
propagation correctly.
2026-03-06 12:44:15 +07:00
6a00090d0c web: replace providers/new page with NewProvider modal
Replace the dedicated provider type selection page with a modal,
using a module-level controller pattern. The /providers/new route
now redirects to /providers?newProvider, which auto-opens the modal.
2026-03-06 12:44:15 +07:00
77f9dde4bf web: add PageTitle component and apply it across all pages
Introduces a reusable PageTitle component with a teal overline accent,
display-3 heading, optional monospace domain label, subtitle, and a
children slot for future domain health/check badges. Applied consistently
to the zone viewer, history, logs, export, import, resolver, providers,
account settings, and new-domain pages.
2026-03-06 12:44:15 +07:00
5ece0f15ca web: document all functions in dns.ts with JSDoc 2026-03-06 12:44:15 +07:00
ba29d13a17 web: add service details offcanvas with DNS records and actions
Introduce ServiceDetailsOffcanvas, an offcanvas panel that opens when
clicking a service card. It displays the service description, its DNS
records, and provides actions buttons.

Also remove raw DNS record from service form.
2026-03-06 12:44:15 +07:00
efebd7e4e2 web: add DNS syntax highlighting with highlight.js
Install highlight.js and apply DNS zone file syntax highlighting on the
export page and in the RecordText component. Uses the github theme and
imports only the dns language to keep the bundle small.
2026-03-05 16:25:44 +07:00
044c6da31a web: replace ModalViewZone with a dedicated export page
Convert the zone file viewer from a modal dialog to a dedicated page at
/domains/[dn]/export, following the same pattern used for service pages.
Adds a "Copy to clipboard" button in the page title bar and adds the
common.copy-clipboard translation key to all supported locales.
2026-03-05 16:25:44 +07:00
91c431f23c web: Improve abstract view 2026-03-05 16:25:44 +07:00
35ea32dcea web: centralize service help link logic in HelpButton component
Introduce a helpLinkOverride store so the Header's help button can
display context-sensitive service docs. Move the svctype-to-URL
computation into Help.svelte (service prop + $effect), removing the
duplicated helpLink functions from the service edit page and the modal
Footer. Pages now render <HelpButton {service} /> to drive the override
without showing a redundant per-page button.
2026-03-05 16:25:44 +07:00
acf7c0d152 web: replace service modal with dedicated page and sidebar
Replace the Service modal component with a dedicated service page route
and a ServiceSidebar component, improving navigation by giving each
service its own URL under [subdomain]/[serviceid].
2026-03-05 16:25:44 +07:00
633a3d6c72 web: focus newly added SPF directive input on creation 2026-03-04 02:24:38 +07:00
36bf664eaa web: sync sidebar scroll with visible subdomain in main content
Use IntersectionObserver to track which subdomain section is currently
visible in the top 30% of the viewport, bold the matching sidebar link,
and auto-scroll the sidebar to keep it in view with scroll-margin-block
so adjacent items remain visible.
2026-03-04 02:24:38 +07:00
7217b6ab18 web: improve subdomain list styling with domain part highlighting
Split subdomain display to show the subdomain and domain parts
separately, making the root domain bold and dimming the domain
suffix. Add hover bold effect for text-dark links.
2026-03-04 02:24:38 +07:00
eb5e0adc0f web: extract zone sidebar into dedicated ZoneSidebar component
Refactor the domain layout by moving the zone-specific sidebar content
(subdomain list, zone actions dropdown) into a new ZoneSidebar.svelte
component, improving separation of concerns between zone and service views.
2026-03-04 02:24:38 +07:00
d588ade59d web: replace deprecated cuid with @paralleldrive/cuid2
All checks were successful
continuous-integration/drone/push Build is passing
2026-03-02 10:08:27 +07:00
ec51c095d8 chore(deps): lock file maintenance
All checks were successful
continuous-integration/drone/push Build is passing
2026-03-02 01:18:49 +00:00
e8a6f2bdbd web: Add transition to VoxPeople card and fix URL param
All checks were successful
continuous-integration/drone/push Build is passing
2026-03-01 17:41:02 +07:00
f0bf1b0b62 web: Integrate BasePath support into frontend and fix web route serving 2026-03-01 17:41:02 +07:00
64c86df9ac Support configurable BasePath for hosting at a sub-path 2026-03-01 17:41:01 +07:00
bf34051069 Reformat manifest.json, add id and fix spelling 2026-03-01 17:40:20 +07:00
ac441a0a25 web: fix service worker caching bugs
- Add network fallback for asset cache misses (prevents broken requests
  on install race conditions)
- Fix query string stripping to use a clean Request instead of copying
  event.request options
- Await cache.put() calls to prevent incomplete writes on SW termination
- Expand auth path exclusion to startsWith("/api/auth") to cover all
  auth-related endpoints
2026-03-01 17:40:20 +07:00