A modern and framework agnostic authorization and authentication package featuring groups, permissions, custom hashing algorithms and additional security features.
Questions tagged [cartalyst-sentry]
196 questions
24
votes
2 answers
How to: implement sentry 2 permissions with Laravel 4?
I'm trying to use cartalyst sentry 2 in my site being built with Laravel 4. Basically I don't understand how to implement permissions.
The examples I've seen for permissions for a group specify the following as an example:
{
"name" :…

Ray
- 3,018
- 8
- 50
- 91
12
votes
2 answers
Laravel: Enable Sentry user account be used in multiple computers
While using Sentry in L4, is it possible to make an account be used in multiple computers at the same time? Right now, Sentry logs out the user the moment the same account is used in another computer.
Right now I'm trying for that not to happen and…

enchance
- 29,075
- 35
- 87
- 127
10
votes
4 answers
How can I use sentry with laravel 5?
I have tried installing sentry in laravel 5 but it doesn't work. I would like to know if anyone has done it and how to do it.
Update: I used the instructions for Laravel 4.

Ogie
- 1,304
- 2
- 14
- 17
10
votes
2 answers
How to force a package to be installed?
I'm trying to install the following package through composer:
https://packagist.org/packages/cartalyst/sentry#dev-feature/laravel-5
When I do:
composer require cartalyst/sentry dev-feature/laravel-5
I always receive this…

user2094178
- 9,204
- 10
- 41
- 70
9
votes
3 answers
Sentry/Sentinel if user is in role
I am trying to run a check to see if the current user is in a certain role with Cartalyst's Sentinel/Sentry package.
I have found Sentinel::inRole('admin') but can't seem to get it to work. I want something like…

T2theC
- 542
- 3
- 10
- 23
7
votes
4 answers
A hasher has not been provided for the user
I can't seem to get sentry working. I keep getting this error: A hasher has not been provided for the user. Does anyone know what would make this happen?
I am running MAMP on OS X 10.9.
I am using php 5.4.4
MCrypt is installed and enabled.
This…

jamespick
- 1,974
- 3
- 23
- 45
6
votes
1 answer
Laravel: Overriding a Bundle's Service Providers
I have a project that uses the Sentinel bundle for Laravel.
A while ago, I asked a question about extending a model provided in the bundle. The answer I accepted worked, but it required editing the bundle's code in the vendor folder.
Since then,…

Chris Schmitz
- 20,160
- 30
- 81
- 137
6
votes
1 answer
How can I specify Partial Mockup for a Laravel Facade?
First I tried this
$mock = m::mock('Cartalyst\Sentry\Facades\Laravel\Sentry');
$mock->shouldReceive('getUser')->once()->andReturn($userInst);
But it gave me
Fatal error: Cannot redeclare…

user391986
- 29,536
- 39
- 126
- 205
6
votes
4 answers
laravel sentry redirect::intended not working
I'm trying to get the sentry package set up in my app correctly.
I can log a user in and out and protect routes but I can't seem to get the redirect::intended to work properly. My understanding is that a user will be taken back to the route they…

Ray
- 3,018
- 8
- 50
- 91
6
votes
1 answer
Tutorial for Laravel 4 - Authentication
I looked around and found some tutorials about Laravel 4 authentication using Sentry or Confide and Entrust. Which are good but a little vague for me, I am Laravel beginner and this is my first framework.
Does anyone know of any tutorial or…

tinyhook
- 342
- 3
- 15
5
votes
1 answer
why is laravel login me out when using sentry?
I'm new to Laravel and I am working on an application. I am using sentry to handle users and the login system. But even though my session expiration is set very high, I keep being logged out very frequently, at random times. Is that a laravel…

David Ross
- 197
- 1
- 1
- 6
4
votes
2 answers
Laravel ranking field how to use set variables in MySQL?
I have a users table with an integer field called ep.
Now, I want to retrieve all users from a specific group ordered by the EP field, and with a generated MySQL field called rank.
This is what I tried:
DB::transaction(function()
{
…

goldlife
- 1,949
- 3
- 29
- 48
4
votes
1 answer
Using Sentry with Codesleeve Stapler?
Update #1
So I think I found out where the problem is but since I lack the knowledge, there's no way for me to solve it.
When using Sentry, I've tried extending both 'Model' which is default with the Sentry package and Laravel's 'Eloquent' under…

Gabriel Rebello
- 1,077
- 1
- 11
- 17
4
votes
3 answers
Getting a specific row other than first()
I'm having a little problem with laravel that may be easily solved. To be short, the situation is: I have two tables, one for the users and the other one for products that has a column 'user_id' so I can identify the associated user.
In Laravel, I…

Gabriel Rebello
- 1,077
- 1
- 11
- 17
4
votes
1 answer
Correct way in using Laravel 4 User model relations with Sentry 2 package
I'm trying to find out how to return the relations I set up for my User model when using Sentry 2.
Normally, I have a user retrieved like this:
$user = User::find(1);
// get some relation
return $user->profile->profile_name;
However, now when I…

Marty
- 463
- 2
- 6
- 14