User Management
InspireCMS provides a comprehensive system for managing users, roles, and permissions
Overview
The user management system in InspireCMS is built on:
- A flexible authentication system
- Role-based access control
- Granular permissions
- User profiles and preferences
User Roles
Managing Roles
Access role management through: Admin Panel > Users > Roles
From here you can:
- Create new roles
- Edit existing roles
- Assign permissions to roles
- Delete roles
Creating a Custom Role (only on Pro)
- Navigate to Users > Roles in the admin panel
- Click Create Role
- Fill in the form:
- Name: Unique identifier for the role (e.g., "Marketing")
- Guard Name: Set to "inspirecms" (this is the default guard used by InspireCMS, which can configure on
config/inspirecms.php
) - Permissions: Select the permissions for this role
- Click Save to create the role
Permissions
Permission Structure
Permissions follow a standard naming convention:
[resource].[action]
For example:
content.view
: Ability to view contentcontent.create
: Ability to create content
Managing Users
Access user management through: Users > Users
User Operations
From the users section, you can:
- View Users: See all registered users in the system
- Create Users: Add new user accounts manually
- Edit Users: Modify user information and roles
- Delete Users: Remove user accounts from the system
User Authentication
InspireCMS supports various authentication features:
- Password-based login
- Password reset functionality
- Remember me capability
- Account lockout after failed attempts
Configuring Authentication
Authentication settings can be modified in config/inspirecms.php
, please reference on configuration documentation
User Profiles
Each user has a profile that includes:
- Basic information (name, email)
- Profile picture
- Role assignments
- Last login information
Users can edit their own profiles through the user menu: User Menu (top-right) > Profile
Custom User Authentication
To use a custom user provider:
config/inspirecms.php
'auth' => [
'provider' => [
'name' => 'cms_users',
'driver' => 'eloquent',
'model' => \App\Models\CmsUser::class, // Your custom user model
],
],
//...
'models' => [
'fqcn' => [
'user' => \App\Models\CmsUser::class,
],
],
Ensure your custom user model implements required interfaces:
namespace App\Models;
use SolutionForest\InspireCms\Models\Contracts\User as UserContract;
use SolutionForest\InspireCms\Models\User as Authenticatable;
class CmsUser extends Authenticatable implements UserContract
{
// Your custom implementation...
}