Anvil
Anvil - The mobile companion for Laravel Forge. Available now. Download for iOS

Introducing Laravel Authentication Log

Laravel Authentication Log is a package which tracks your user's authentication information such as login/logout time, IP, Browser, Location, etc. as well as sends out notifications via mail, slack, or sms for new devices and failed logins.

AR
Anthony Rappa
1 min read - 12,390 views -

I just release Laravel Authentication Log which tracks your user's authentication information such as login/logout time, IP, Browser, Location, etc. as well as sends out notifications via mail, slack, or sms for new devices and failed logins.

It's pretty plug and play. Just install and add a trait to the authenticable models you want to track.

It keeps a log of a user's authentication activity (Socialite included), as well as sends them emails about their activity (currently new device and failed logins with more to come).

Here are an example of those e-mails:

As you can see it also (optionally) logs the user's location at the time using the torann/geoip package, marks if the user was successful at authenticating or not, as well as marks if the user cleared the sessions themselves using Laravel's logoutOtherBrowsers functionality.

I also included an example Livewire Tables table in the read me if you would like to output the log which would look like this:

I hope you get some good use out of it. Check back soon for updates as I have more functionality in the pipeline.

Read next

Laravel Patches v4.0.0

We are excited to announce the release of Laravel Patches v4.0, featuring a completely rewritten test suite using Pest, enhanced CLI tools for better visibility, and robust safeguards for your patch workflow. This release focuses on developer experience and reliability, ensuring you can manage your database patches with the same confidence as your migrations.

2 min read - 2,696 views -