Commit graph

176 commits

Author SHA1 Message Date
XiaoSeS
f993ad6533
Merge pull request #712 from Vast-Stars/feat/personal-namespace-provisioning
feat(namespace): auto-provision a personal namespace on registration
2026-08-28 17:04:21 +08:00
XiaoSeS
37e3c63236
Merge pull request #688 from iflytek/fix/auth-email-assurance-guard-main
fix(auth): enforce trusted OAuth identity attributes
2026-08-28 17:04:15 +08:00
XiaoSeS
eeb63613f2 fix(namespace): enable personal provisioning by default 2026-08-28 16:42:26 +08:00
XiaoSeS
ee0f0763db refactor(namespace): keep personal provisioning configuration-only 2026-08-28 15:55:29 +08:00
XiaoSeS
dc31bb97f4 Revert "feat(namespace): backfill personal namespaces for existing accounts"
This reverts commit 2d50437e4f.
2026-08-28 15:19:56 +08:00
XiaoSeS
eba2762b5b Revert "feat(namespace): let operators choose which namespaces new accounts join"
This reverts commit a9e7f43e5a.
2026-08-28 15:19:56 +08:00
FenjuFu
26f49e6819
docs(governance): add DPGA policy evidence
Validated documentation, links, markdown checks, and CI.
2026-08-27 15:07:42 +08:00
FenjuFu
7fc1df5043
feat(ratelimit): make thresholds runtime-configurable
Validated locally and in CI, including runtime configuration documentation.
2026-08-27 15:07:31 +08:00
FenjuFu
f846da230c
feat: add initial RISC-V image support (#725)
Some checks failed
Security / Dependency Review (push) Waiting to run
Security / CodeQL (java-kotlin) (push) Waiting to run
Security / CodeQL (javascript-typescript) (push) Waiting to run
Security / CodeQL (python) (push) Waiting to run
Deploy Docs / build (push) Has been cancelled
Deploy Docs / Deploy (push) Has been cancelled
* feat: add initial RISC-V image support

Signed-off-by: FenjuFu <92919259+FenjuFu@users.noreply.github.com>

* chore(ci): tighten riscv64 image guardrails

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

---------

Signed-off-by: FenjuFu <92919259+FenjuFu@users.noreply.github.com>
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
Co-authored-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-24 16:37:34 +08:00
XiaoSeS
1b7a6d5544
chore(deps): resolve dependabot npm alerts
Resolve open npm Dependabot alerts for the web app and docs site by refreshing dependency overrides and lockfiles.

Also sets the staging web forwarded-proto default so `make staging` can render the shared Nginx template when using the bare nginx image.

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-24 16:08:07 +08:00
青柠
a9e7f43e5a feat(namespace): let operators choose which namespaces new accounts join
A deployment that stands up its own organisation-wide namespace — to use
instead of the built-in global one — finds it invisible to everybody. The
namespace listing only returns namespaces the caller belongs to, and the
only thing that ever added members automatically was hard-wired to the slug
"global".

Make that list a setting. namespace.default-membership holds the slugs every
newly activated account is enrolled in, defaulting to ["global"], which is
what every deployment did before. Publishing only requires membership of any
role, so being enrolled is enough to publish there; no extra grant needed.

GlobalNamespaceMembershipService becomes DefaultNamespaceMembershipService,
since it no longer means one specific namespace.

Where the strictness sits:

- Saving validates every slug resolves to an ACTIVE namespace, so a typo
  fails at the moment an administrator makes it.
- Enrolling tolerates a slug that no longer resolves: it logs and skips.
  A namespace that was deleted or renamed must not cost somebody their
  login.

Adding a namespace to the list after people have signed up leaves them out,
the same trap the personal-namespace work hit, so this ships with the same
preview-then-apply backfill.

Verified against a real PostgreSQL, end to end: create a namespace, reject an
unknown slug, save with whitespace and duplicates and see them normalised,
preview, apply, re-preview showing nothing left, and a fresh registration
landing in the global namespace, the new shared one, and its own personal one
at once.
2026-08-16 20:31:46 +08:00
青柠
2d50437e4f feat(namespace): backfill personal namespaces for existing accounts
Turning provisioning on only affects accounts activated afterwards, which
on a registry that has already been running means nobody. The first person
to hit this on our deployment was the operator who enabled it: they signed
in, got no namespace, and had no way to find out why.

Two fixes.

Backfill. POST /api/v1/admin/settings/personal-namespace/backfill walks the
active accounts and gives a namespace to those without one, skipping system
accounts and anyone who already owns a non-global namespace. Details worth
knowing:

- dryRun reports the plan — each account and the slug it would take —
  without writing. The console requires a preview before it will enable the
  apply button.
- The response lists only accounts that changed or could not be placed;
  the rest are counted, so an operator reads the work rather than the whole
  directory.
- A run stops at a per-run account cap and reports truncated rather than
  looking like it covered everything.
- Slugs promised earlier in a run are reserved, so one batch cannot hand
  the same slug to two accounts.
- Not @Transactional: each namespace is created in its own transaction, so
  an account that cannot be placed does not discard the rest of the run.

Diagnosability. The skip paths — provisioning disabled, account already owns
a namespace, no slug available — were silent returns, which is why "nothing
happened and I cannot tell why" was the actual user experience. They now log
their reason; account activation is rare enough that the extra lines cost
nothing.
2026-08-15 01:11:51 +08:00
青柠
ae23d1a051 feat(namespace): auto-provision a personal namespace on registration
Self-hosted deployments want every new account to have somewhere of its
own to publish, without asking an administrator for a namespace first and
without pushing drafts into `global`.

Add an operator-controlled policy, off by default so upgrading changes no
behaviour. When enabled, an account that becomes usable gets a namespace
it owns. "Private" here means a team namespace whose only member is that
account: namespaces have no visibility flag, and skill visibility stays a
property of each skill.

Trigger points. UserActivatedEvent is published wherever an account first
becomes usable:

- LocalAuthService.register
- IdentityBindingService.bindOrCreate, for ACTIVE first logins
- AdminUserAppService.updateUserStatus, on a transition into ACTIVE

The third matters for deployments that gate access behind approval: those
accounts are created PENDING at the first OAuth attempt and only become
usable when an administrator approves them.

Why an AFTER_COMMIT listener rather than a call alongside
GlobalNamespaceMembershipService.ensureMember. Both namespace.created_by
and namespace_member.user_id reference user_account(id), which rules out
each obvious alternative:

- Joining the registration transaction lets a slug clash roll the
  registration back, so a namespace failure costs the user their account
  — or, on OAuth, their login.
- Suspending it with REQUIRES_NEW leaves the new transaction unable to see
  the uncommitted user_account row, so the foreign key check blocks on the
  outer transaction's row lock and the two wait on each other.

Provisioning after commit avoids both. The listener is deliberately not
@Async, so the namespace exists by the time the user's next request
arrives, and it swallows failures.

Naming. Two templates over ${username}, ${email_prefix} and ${user_id};
unknown placeholders are left in place so a typo is visible rather than
silently dropped. ${username} falls back to the email local part and then
to the user id. Slugs go through the existing slug rules, which is why the
console renders a live preview: underscores are not legal in a slug, so
`${username}_space` yields `alice-space`. A taken or reserved candidate
gets a numeric suffix, so `admin` becomes `admin-2`. Owning any non-global
namespace already skips provisioning, which keeps re-enabling an account
from handing out a second one.

The templates are not exposed in application.yml: they contain ${...},
which Spring would resolve as property references, and Boot 3.2 predates
placeholder escaping. Only the enable flag lives there; templates are set
in the console and default from PersonalNamespaceProvisioningProperties.

Updating the policy writes an audit entry with the before and after.
2026-08-13 18:17:25 +08:00
XiaoSeS
76d95b615e
docs(compliance): document runtime integration contract (#704)
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-11 13:43:42 +08:00
XiaoSeS
1dfe3756a9 feat(search): refine compliance discovery interactions
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-10 10:42:19 +08:00
XiaoSeS
725bbe165b feat(metadata): add x-astron compliance snapshot
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-07 15:46:06 +08:00
philsun
34f244e7a4 feat(web): support configurable base-path deployment
Signed-off-by: philsun <xinyi.sun@daocloud.io>
2026-08-05 12:50:26 +08:00
ylhu16
833270bb31 fix(auth): enforce trusted OAuth identity attributes
Signed-off-by: ylhu16 <ylhu16@iflytek.com>
2026-08-05 11:21:41 +08:00
XiaoSeS
fc457a0651
test(smoke): decouple admin checks from bootstrap credentials (#686)
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-04 19:20:34 +08:00
XiaoSeS
55e5c1e10e
feat(observability): add generic request correlation and tracing foundation (#664)
* feat(observability): establish request correlation boundary

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* feat(observability): add selectable tracing modes

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* feat(observability): propagate async trace context

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* docs(observability): document tracing deployment modes

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* fix(observability): tighten tracing integration boundaries

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* fix(observability): harden operational log privacy

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* feat(observability): propagate message trace context

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* fix(observability): document message propagation semantics

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* test(auth): isolate security context between tests

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* fix(observability): skip otlp exporter without endpoint

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

---------

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-08-04 10:26:42 +08:00
XiaoSeS
5be758846e
Merge pull request #625 from michael-xiii/feat/web-label-search-navigation
feat(web): link skill labels to search and wrap filter chips
2026-08-04 09:29:53 +08:00
XiaoSeS
5f7c48b7a4 feat(bootstrap): publish starter skills in runtime manifest
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-31 18:27:25 +08:00
XiaoSeS
b20ad397ad Merge codex/builtin-skills-content into codex/builtin-skills-release
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-31 18:27:25 +08:00
wowo-zZ
7885cc568b feat(builtin-skills): add reviewed starter collection
Signed-off-by: wowo-zZ <zhenggui5228@126.com>
2026-07-31 14:22:23 +08:00
XiaoSeS
09db71ffa7 docs(weekly): mirror reports into project Pages
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-31 11:18:22 +08:00
wowo-zZ
7f934e63ab feat(bootstrap): verify built-in skill artifacts
Signed-off-by: wowo-zZ <zhenggui5228@126.com>
2026-07-31 11:14:42 +08:00
wowo-zZ
0bf822290b feat(builtin-skills): add reviewed starter collection
Signed-off-by: wowo-zZ <zhenggui5228@126.com>
2026-07-30 15:54:09 +08:00
XiaoSeS
6817d98007
Merge pull request #367 from xring/fix/postgres-lostfound
Some checks are pending
Deploy Docs / build (push) Waiting to run
Deploy Docs / Deploy (push) Blocked by required conditions
Security / Dependency Review (push) Waiting to run
Security / CodeQL (java-kotlin) (push) Waiting to run
Security / CodeQL (javascript-typescript) (push) Waiting to run
Security / CodeQL (python) (push) Waiting to run
fix(deploy): isolate PostgreSQL data from volume root
2026-07-30 09:56:00 +08:00
Mikhail Neradkov
6d714c68ab docs(labels): document detail chip navigation and filter wrap
Align the label system design with click-through chips on skill detail
and wrapping search filter chips when many labels are present.

Signed-off-by: Mikhail Neradkov <michael.neradkov@gmail.com>
2026-07-29 22:57:51 +03:00
XiaoSeS
3db3c9685f feat(redis): complete cluster connection support
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-29 17:36:06 +08:00
XiaoSeS
13b3f2da92 chore(cli): integrate contributor merge update (#606)
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-29 10:37:03 +08:00
XiaoSeS
a9007a4e8c fix(cli): preserve download error contract (#606)
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-29 10:31:49 +08:00
dongmucat
c1835fc9e9 merge(main): resolve CLI error mapping conflicts (#606)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-29 10:24:23 +08:00
XiaoSeS
ad4a2dbc2f chore(cli): merge main into PR #608
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-29 10:19:03 +08:00
XiaoSeS
7872e64177
Merge pull request #609 from iflytek/fix/auth-revoked-token-validation
test(auth): cover revoked CLI token lifecycles
2026-07-29 03:37:47 +08:00
XiaoSeS
0dd600ce13 fix(deploy): preserve PostgreSQL PVC data layout 2026-07-29 01:41:20 +08:00
XiaoSeS
e4fb26d4ba fix(nginx): trust forwarded proto only when configured
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-28 20:03:50 +08:00
gale-popai
d977ea9dc4
fix(api): tell callers why a request was forbidden (#610)
* fix(api): tell callers why a request was forbidden

The scope filter already computes an exact reason ("Missing API token
scope: skill:delete", "API token cannot access endpoint: /x") and the
access-denied handler discarded it, returning a bare "Forbidden" for
every case: missing scope, endpoint closed to API tokens, and paths
that simply don't exist. Clients cannot tell those apart, so they
guess — the published CLI reports every 403 as "token may lack
required scope", which sent us debugging token scopes for an hour when
the real causes were a revoked token and a mistyped namespace path.

The reason now rides in the response via a new error.forbidden.detail
message (en + zh), and is logged alongside the exception type.

Signed-off-by: Gal Eyal <gal.e@popai.health>

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(api): safely expose API token denial reasons

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

---------

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-28 17:42:20 +08:00
dongmucat
d4d1f65705 fix(cli): scope local remove by namespace (#606)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 16:58:32 +08:00
dongmucat
a94073004f docs(cli): define namespace error fix plan (#606)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 16:58:31 +08:00
dongmucat
5012b31af2 test(auth): cover CLI session fallback (#605)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 15:22:11 +08:00
dongmucat
8163a48e9e docs(auth): align Bearer-only response contract (#605)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 13:52:42 +08:00
FenjuFu
e5f0cc140a
docs(faq): add community-sourced deployment and operations Q&A (#593)
* docs(faq): add community-sourced deployment and operations Q&A

Adds entries collected from real user-support threads to the reference FAQ
(both zh and en):

- 502 on auth APIs while the page loads, traced to server startup failure
  on the SKILLHUB_DOWNLOAD_ANON_COOKIE_SECRET placeholder guard
- config changes not taking effect (.env.release.example vs .env.release,
  restart vs recreate)
- built-in skill sync failure in offline environments
- upgrade path with Flyway auto-migration and volume retention
- external dependencies and the lack of MySQL support
- granting SUPER_ADMIN to an OAuth account via the bootstrap admin
- telling CLI and server versions apart
- installing skills into a target directory on an intranet

Signed-off-by: FenjuFu <fufenjupku@gmail.com>

* docs(faq): move entries to the published docs source and fix inaccuracies

Move the new FAQ entries from document/ (a generated tree that the docs
build does not read) to docs/skillhub/, which is what make docs-build and
the Pages deploy actually publish.

Also address review feedback:
- drop the SKILLHUB_BUILTIN_SKILLS_ENABLED tip; compose.release.yml does
  not pass that variable through, so setting it has no effect
- correct the dependency list: object storage defaults to local, S3 is
  recommended for production
- soften the 502 wording, since upstream/DNS/network can also cause it
- state the 32-character minimum for the cookie secret
- give a real bulk-install example and qualify v0.2.12 as a server version
- drop entries already covered by existing upgrade/MySQL/version questions

Signed-off-by: FenjuFu <92919259+FenjuFu@users.noreply.github.com>

* docs(faq): correct deployment and admin guidance

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* docs(faq): fix remaining recreate guidance

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

* docs(faq): clarify bulk install paths

Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>

---------

Signed-off-by: FenjuFu <fufenjupku@gmail.com>
Signed-off-by: FenjuFu <92919259+FenjuFu@users.noreply.github.com>
Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
Co-authored-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com>
2026-07-28 13:49:38 +08:00
dongmucat
5805e0f1d3 docs(auth): document CLI token failure semantics (#605)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 12:55:35 +08:00
dongmucat
e5b8439678 docs(auth): plan revoked token regression coverage (#605)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 11:37:07 +08:00
dongmucat
6567c19664 docs(auth): tighten runtime validation gates (#605)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 11:20:08 +08:00
dongmucat
03085f19b5 docs(auth): define revoked token validation design (#605)
Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-28 11:08:37 +08:00
dongmucat
982258d032
Merge pull request #585 from betterlmy/agent/generic-user-install-target
feat(cli): add generic user-level install target
2026-07-22 17:20:14 +08:00
dongmucat
9af4d391f3
docs(integrations): add Hermes Agent skill guide (#584)
* docs(integrations): add Hermes skill guide

Signed-off-by: dongmucat <1127093059@qq.com>

* docs(integrations): clarify Hermes skill collision handling

Signed-off-by: dongmucat <1127093059@qq.com>

---------

Signed-off-by: dongmucat <1127093059@qq.com>
2026-07-22 15:01:50 +08:00
betterlmy
f519b08a73 fix(cli): preflight canonical install targets
Signed-off-by: betterlmy <betterlmy@icloud.com>
2026-07-17 17:20:22 +08:00