Git Product home page Git Product logo

Comments (4)

nickyvanurk avatar nickyvanurk commented on May 27, 2024 1

It actually works! It doesn't log me in automatically but when I went to a location on the site that needs authentication, it worked. Any idea on how to make it so it logs the user in when they visit the site when the cookie is set?

EDIT

Got it working, in the beforeFilter I now check if the identity of the user is set ($this->Auth->identity()) and if it is, set the user. The plugin works great, it was a problem the way the application I am working on is implemented.

from cakephp-remember-me.

nojimage avatar nojimage commented on May 27, 2024

I have never used TinyAuth, so I don't know the details.
The possibility is that there is not enough user data to be during authorize.

The RememberMe.Cookie setting seems to lack the finder option. Try the following:

                'RememberMe.Cookie' => [
                    'userModel' => 'Users',
                    'fields' => ['username' => 'email', 'password' => 'password'],
                    'finder' => 'auth',
                    'inputKey' => 'remember_me',
                    'cookie' => [
                        'name' => 'rememberMe',
                        'expires' => '+90 days',
                        'secure' => true,
                        'httpOnly' => true,
                    ],
                ],

from cakephp-remember-me.

nickyvanurk avatar nickyvanurk commented on May 27, 2024

Does the remember-me plugin automatically detect and read the cookie and authenticate? Or do I manually do that in a beforeFilter? I assumed it would read the cookie automatically. Adding the finder didn't work.

from cakephp-remember-me.

nojimage avatar nojimage commented on May 27, 2024

Yes, the RememberMe.Cookie Authenticator is automatically processing cookie.
Is it impossible to authenticate even if you disable the authorize option?

from cakephp-remember-me.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.