Repository navigation
Conversation
…core Replaces the v2 controllers (laravel/ui traits) and the abstract User with user types, Route::authRoutes(), actions, controllers, middleware and Blade pages. Drops javaabu/helpers, javaabu/activitylog, javaabu/passport, javaabu/schema, laravel/ui and medialibrary. Closes #1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e, security and two-factor Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…gin methods, session driver Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…abu/permissions
Route::userAccountActions() adds unlock, reset two-factor, require password update and
log out everywhere for one user type's accounts, behind the auth.* abilities of
UserAccountPolicy. Permissions ({action}_{type plural}) are registered per user type.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…nticator Passkeys (laravel/passkeys) live in one table with a morph to the user, so admins and users with the same id keep separate keys and can't use each other's. WebAuthn failures answer 422. The tests register and sign with a real P-256 key. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Route::authApiRoutes() issues and revokes Sanctum tokens per user type (with the two-factor code when the user has one). The security page manages personal access tokens with either driver. Passport uses its own per-provider clients; auth:install publishes, makes keys and prints the guards for each user type. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… checks The React pages (auth::Login, …, auth::Settings/Security) ship through javaabu/manifest with the same props as the Blade pages, and a shared WebAuthn client for passkeys. lang/dv.json covers every string. Tests check both stacks, the translations, logical direction utilities only, and that the package works without its optional packages. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Docusaurus pages for every flow, option and public class, Blade and React side by side, an upgrade guide from v2, AGENTS.md and the changelog. Records last_login_at on login. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e models without MustVerifyEmail Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
llms.txt and the Boost skill point at vendor/javaabu/auth/docs, so docs must not be export-ignored. Dev-only JS tooling files are now export-ignored instead. Closes #16 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
UserTypes::accountLink() adds a link for every user type that has the route, and UserType::accountLink() / withoutAccountLink() change one type. The Blade navigation and React AccountLayout render Profile, Security and the added links from the new account_links prop, marking the current page; the Blade partial also works on pages that didn't come from auth. Documented for package authors. Closes #15 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Blade-only apps' manifest:check no longer asks them to install React, @inertiajs/react, @javaabu/forms or @javaabu/onu (Javaabu/manifest#17). The Blade scripts import no npm packages, and a test keeps it that way. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Composer read composer.json from every branch and tag of each VCS repository through the GitHub API: about 350 calls per CI job, around 3,800 per run. A second run within the hour exhausted the workflow token's limit, and Composer failed with "Could not authenticate against github.com" (Javaabu/exports#2, Javaabu/translatable#4). "no-api": true makes Composer clone these repositories instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every job downloaded each package's zipball from api.github.com, around 140 calls a job, which counts against the workflow token's hourly limit. Each job now restores Composer's files cache, keyed by job, matrix entry and composer.json/composer.lock, and falls back to the job's last cache when those change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
javaabu/auth v3.0: a rewrite around user types, matching Laravel's current starter kits, with multi-auth at the centre. Tracked in n4ff4h#14 (developed on the fork because the orchestrating account has read-only access here).
What's in it
config('javaabu-auth.user_types'),UserTypes::register()): each kind of user has its own model, guard, password broker, route names, home, Blade/Inertia stack, layouts, features, two-factor mode, lockout limit and login methods. Nothing assumesweborApp\Models\User.Route::authRoutes('admin', ['prefix' => 'admin'])registers login/logout, registration, password reset, email verification, password confirmation, the 2FA challenge, passkeys, account status, required password change, and the profile and security pages, with starter-kit route names (admin.login,admin.password.request, …). AlsoRoute::authApiRoutes()andRoute::userAccountActions().CreatesNewUsers, …), controllers overridable from config, rebindable responses,auth.type:{type}middleware for app pages, password confirmation kept per user type.laravel/passkeys: login, confirmation and management for every type, one morph table. Tested end to end with a software authenticator (real P-256 keys and CBOR).php artisan auth:install --api=…), Sanctum token logins with 2FA, Passport per-provider tokens, personal access tokens on the security page.UserAccountPolicyand permissions registered through javaabu/permissions.LoginMethod+StartAuthenticatedSessionfor other ways to log in, and account navigation links (UserTypes::accountLink('mobile-number', 'Mobile number'), per type with$type->accountLink()/withoutAccountLink()), shown in Blade and React wherever the type has the route (Let packages add links to the account navigation n4ff4h/auth#15).lang/dv.json) and right to left.docs/(including a "For package authors" page),llms.txt, Laravel Boost guideline and skill,AGENTS.md,CHANGELOG.md.docs/,llms.txtandresources/boostship in the Composer package (no longer export-ignored), so assistants find them undervendor/javaabu/auth(docs/ is export-ignored, but llms.txt and the Boost skill point at vendor/javaabu/auth/docs n4ff4h/auth#16).Decisions and why are on the issues: not building on Fortify (n4ff4h#2), laravel/passkeys (n4ff4h#5), gate abilities instead of a model policy (n4ff4h#12), no javaabu/stencil for these small forms (n4ff4h#11), javaabu/passport dropped (n4ff4h#6).
Upgrading from v2
Breaking. Full guide:
docs/upgrading.md. The short version:config/auth.phptoconfig/javaabu-auth.php; describe each user type there. Guards, providers and brokers stay inconfig/auth.php.Javaabu\Auth\Http\Controllers\Auth\*and their routes; callRoute::authRoutes()per type. Route names follow the starter kits (password.new-passwordis nowpassword.required).Javaabu\Auth\User→Javaabu\Auth\Models\User(built from traits); theUserContractmethods (guardName(),homeUrl(), …) go away in favour of the user type. Add the 2FA columns withUserSchema::twoFactorColumns().auth:x+active:x+password-update-not-required:x→auth.type:{type};password.confirm→auth.password.confirm:{type}.javaabu-auth.layoutsat your layouts, or publish them.Session\SessionandAgentmove toSessions\;Events\PasswordChangedis nowPasswordUpdated; translations are JSON.new_emailverification flow, the media-library avatar,IsAdminModel/LogsActivityon the model.Checks
CI on the fork is green: Pint, PHP 8.4/8.5 × Laravel 12/13 × lowest/stable, the React pages (typecheck + Vitest), and a run without the optional packages (Inertia, Sanctum, Passport, activitylog). 146 PHP tests, 12 JS tests.
For you
CODECOV_TOKENfor the coverage upload and badge.docs/advanced-usage/translations.md.🤖 Generated with Claude Code