Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
9871a20
fix(kits): resolve a local path before trusting it, so a ?redirect= l…
entity Nov 28, 2026
f586dcc
fix(nuxt): collapse a leading slash and backslash too, so /\elsewhere…
entity Nov 28, 2026
fae3e7c
test(nuxt): check the pages emailed links open get their route rules …
entity Nov 28, 2026
51195e0
fix(kits): recognise an emailed link opened with a trailing slash or …
entity Nov 28, 2026
7ff5c0b
fix(kits): require the production settings whenever node_env isn't de…
entity Nov 28, 2026
18620a1
fix(kits): look up keyring's pages by their own names only, never a n…
entity Nov 28, 2026
b966cad
fix(tanstack): keep a sign in's alerts in the browser only, never in …
entity Nov 28, 2026
3db1e6f
fix(ui): only follow an enrollment's continue to a page on this site,…
entity Nov 28, 2026
a05374a
fix(proxies): trim each trusted proxy and drop the empty ones
entity Nov 28, 2026
2095160
fix(hosts): only answer for app_url's host and a headless frontend's
entity Nov 28, 2026
774d18c
fix(headers): send keyring's security headers with the app's own pages
entity Nov 28, 2026
0e4f1f3
fix(appearance): only let light, dark or system reach the page's inli…
entity Nov 28, 2026
50fa72e
fix(mail): build the password reset link from app_url, or fail, never…
entity Nov 28, 2026
a100f59
docs: keep laravel's port for the kit alone, and turn debug off in pr…
entity Nov 28, 2026
a9a4c07
fix(export): refuse unreleasable lockfiles, unknown monorepo-only tag…
entity Nov 28, 2026
485cf2a
fix(ci): pin node and the playwright image, keep .git out of the rele…
entity Nov 28, 2026
18cae39
test(export): list the kit.json path cases as plain objects, so the l…
entity Nov 28, 2026
6dd66d9
fix(hosts): check a trusted proxy's forwarded host, answer the health…
entity Nov 28, 2026
599bf3e
fix(ui): check a continue on this site before visiting it without rec…
entity Nov 28, 2026
be85295
fix(demo): let the email gallery frame its emails from the same site
entity Nov 28, 2026
28b8639
fix(tanstack): treat a built server as production whatever node_env s…
entity Nov 28, 2026
04723df
docs(headers): describe the security headers and that no-store keeps …
entity Nov 28, 2026
e8157f0
fix(ci): check for a re-run of a release before refusing an older tag
entity Nov 28, 2026
f9176fc
test(ui): run the inertia app's and the shared sameOriginUrl() agains…
entity Nov 28, 2026
7bf732c
fix(export): resolve symlinks as the file system does and refuse dang…
entity Nov 28, 2026
04f0061
fix(export): refuse git dependencies in a released lockfile, and docu…
entity Nov 28, 2026
297aa11
fix(nuxt): collapse the leading slashes of an absolute-form target's …
entity Nov 28, 2026
5fcc8f9
docs(e2e): say that bumping playwright means updating the image's tag…
entity Nov 28, 2026
59eae36
fix(hosts): take a refused host off the request, so the error page an…
entity Nov 28, 2026
ad3223a
fix(proxies): trust x-forwarded-prefix in headless mode only, and ign…
entity Nov 28, 2026
e9cd36c
fix(kits): cap proxied bodies at 256 KiB with a 15 second deadline, a…
entity Nov 28, 2026
fe68885
fix(kits): answer a path no page matches with a 404 without reading /…
entity Nov 28, 2026
3e45dc3
docs(kits): say to run behind a reverse proxy with its own limits, an…
entity Nov 28, 2026
35978cd
fix(registration): only take email addresses symfony mailer can send to
entity Nov 28, 2026
8c6c087
fix(proxies): believe x-forwarded-prefix only as one path of plain se…
entity Nov 28, 2026
0a7b46b
docs(hosts): say why a refused host gets a 400
entity Nov 28, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
APP_NAME="Keyring Example"
APP_ENV=local
APP_KEY=
# For local work only: on a server, APP_ENV=production and APP_DEBUG=false.
APP_DEBUG=true
APP_URL=http://localhost:8000

Expand All @@ -17,10 +18,12 @@ APP_URL=http://localhost:8000
# FRONTEND_URL=http://localhost:3000

# A proxy in front of the app (tailscale serve, a load balancer, a headless
# frontend's server), believed about HTTPS, the host, the path prefix and the
# visitor's address: comma-separated addresses, or *. Unset, headless mode
# trusts a proxy on this machine (127.0.0.1,::1) and Inertia mode none, so in
# headless mode anything on loopback that forwards to Laravel is trusted.
# frontend's server), believed about HTTPS, the host and the visitor's
# address, and in headless mode the path prefix: comma-separated addresses, or
# *. Unset, headless mode trusts a proxy on this machine (127.0.0.1,::1) and
# Inertia mode none, so in headless mode anything on loopback that forwards to
# Laravel is trusted: keep Laravel's port reachable by the frontend's server
# only, or pin this.
# TRUSTED_PROXIES=127.0.0.1

APP_LOCALE=en
Expand Down
51 changes: 44 additions & 7 deletions .github/workflows/kits.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ on:
permissions:
contents: read

env:
# The current LTS, pinned so every job builds and tests with the same
# Node: bump it on purpose, not whenever lts/* moves.
NODE_VERSION: '26.13.1'

concurrency:
group: kits-${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
Expand Down Expand Up @@ -76,7 +81,7 @@ jobs:

- uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
with:
node-version: lts/*
node-version: ${{ env.NODE_VERSION }}
cache: npm

- run: composer install --no-interaction --no-progress
Expand All @@ -86,11 +91,15 @@ jobs:
run: node --test bin/
- run: npm run build
- run: npm test
# Its tests run packages/ui-react's too. After the build,
# test/build.test.mjs checks how the built server starts and
# what it passes on to Laravel.
- name: TanStack Start kit
run: |
npm test -w kits/tanstack-start
npm run types:check -w kits/tanstack-start
npm run build -w kits/tanstack-start
node --test kits/tanstack-start/test/build.test.mjs
# Its tests run packages/ui-vue's too, and its typecheck the
# shared components it imports; vue-tsc checks the rest.
# test:build builds it, then checks what the built server sends.
Expand All @@ -108,12 +117,14 @@ jobs:
# against the same screenshots, made in this same image (the README's
# "Screenshots"), so the browser, its fonts and its libraries render them
# pixel for pixel. Its version is the @playwright/test in
# package-lock.json.
# package-lock.json, and it's pinned by digest, so a re-pushed tag can't
# change what runs: `docker buildx imagetools inspect` gives the digest
# of a new version's tag.
browser:
name: Browser tests (${{ matrix.kit }})
runs-on: ubuntu-latest
container:
image: mcr.microsoft.com/playwright:v1.65.0-noble
image: mcr.microsoft.com/playwright:v1.65.0-noble@sha256:9beb546099e11f52d62e505537914870e01a67e0e6b00ae41da4775324e73dbe
strategy:
fail-fast: false
matrix:
Expand All @@ -130,7 +141,7 @@ jobs:

- uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
with:
node-version: lts/*
node-version: ${{ env.NODE_VERSION }}
cache: npm

- run: composer install --no-interaction --no-progress
Expand Down Expand Up @@ -166,7 +177,7 @@ jobs:

- uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
with:
node-version: lts/*
node-version: ${{ env.NODE_VERSION }}
cache: npm

# The export formats the files it rewrites with the monorepo's tools.
Expand Down Expand Up @@ -278,14 +289,26 @@ jobs:
echo 'github.com ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl' > "$hosts"
export GIT_SSH_COMMAND="ssh -i $key -o IdentitiesOnly=yes -o UserKnownHostsFile=$hosts -o StrictHostKeyChecking=yes"

# A release is vMAJOR.MINOR.PATCH (prereleases never get
# here), which also keeps the tag from reading as an option.
semver='^v(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)$'

if ! [[ "$TAG" =~ $semver ]]; then
echo "::error::$TAG isn't a release tag like v1.2.3."
exit 1
fi

# Keep the repository's history: each release is one commit
# on top of the last, and an empty repository gets its first.
target="$RUNNER_TEMP/target"
git clone --depth 1 "git@github.com:$REPOSITORY.git" "$target"
cd "$target"

git checkout -B main
find . -mindepth 1 -maxdepth 1 ! -name .git -exec rm -rf {} +
tar -xzf "$RUNNER_TEMP/export.tgz" -C .
# The export never has a .git, and one in the archive
# mustn't replace this clone's.
tar -xzf "$RUNNER_TEMP/export.tgz" -C . --exclude=./.git --exclude=.git
git add -A

# A re-run: the tag is there already. Fine if it holds these
Expand All @@ -302,6 +325,20 @@ jobs:
exit 1
fi

# Never an older release over a newer one: past a re-run,
# which is checked first, so an older release can be re-run,
# the tag has to be newer than every release tag there.
latest=$(git ls-remote --tags --refs origin 'refs/tags/v*' \
| sed 's#^.*refs/tags/##' \
| { grep -E "$semver" || true; } \
| sort -V | tail -n 1)

if [ -n "$latest" ] &&
[ "$(printf '%s\n%s\n' "$latest" "$TAG" | sort -V | tail -n 1)" != "$TAG" ]; then
echo "::error::$REPOSITORY already has $latest, which is newer than $TAG."
exit 1
fi

git config user.name 'github-actions[bot]'
git config user.email '41898282+github-actions[bot]@users.noreply.github.com'

Expand All @@ -311,5 +348,5 @@ jobs:
git commit -q -m "chore(release): $TAG from $SOURCE"
fi

git tag -a "$TAG" -m "$TAG from $SOURCE"
git tag -a -m "$TAG from $SOURCE" -- "$TAG"
git push --atomic origin main "refs/tags/$TAG"
Loading
Loading