NAME
Mojolicious::Plugin::Fondation::Auth::Provider::DBIx - DBIx::Class-backed authentication provider for Fondation::Auth
VERSION
version 0.02
SYNOPSIS
$app->plugin('Fondation::Auth' => {
model => 'user',
username_column => 'username', # optional, default: 'username'
password_column => 'password', # optional, default: 'password'
});
DESCRIPTION
This provider authenticates users against a DBIx::Class schema, using Mojolicious::Plugin::Fondation::Model::DBIx::Async for backend configuration discovery.
Authentication operations (validate_user, load_user) use a synchronous DBIx::Class::Schema instance built from the same backend config. This is necessary because Mojolicious::Plugin::Authentication requires synchronous callbacks.
Password hashing (Argon2id) is handled by the Result class (Mojolicious::Plugin::Fondation::Auth::Schema::Result::User) via insert/update hooks — the provider only verifies.
NAME
Mojolicious::Plugin::Fondation::Auth::Provider::DBIx - DBIx::Class-backed authentication provider
CONFIGURATION
- model
-
Model name as configured in
Fondation::Model::DBIx::Async(required). Used to discover the tablesourceviamodel_config(). - username_column
-
Column name for usernames (default:
username). - password_column
-
Column name for Argon2id password hashes (default:
password).
REQUIREMENTS
The application must load Fondation::Model::DBIx::Async before Fondation::Auth. This is handled automatically via fondation_meta dependencies when using the Fondation plugin loader.
The schema class must include the users Result source (typically via load_namespaces and Mojolicious::Plugin::Fondation::Auth::Schema::Result::User).
SEE ALSO
Mojolicious::Plugin::Fondation::Auth, Mojolicious::Plugin::Fondation::Model::DBIx::Async, DBIx::Class::Schema, Mojolicious::Plugin::Fondation::Auth::Schema::Result::User
AUTHOR
Daniel Brosseau <dab@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2026 by Daniel Brosseau.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.