Skip to content
This repository has been archived by the owner on May 7, 2019. It is now read-only.

Commit

Permalink
Add Honeypot service to further reduce spambots registering
Browse files Browse the repository at this point in the history
  • Loading branch information
TheReverend403 committed Jul 2, 2016
1 parent 448d3e6 commit a265940
Show file tree
Hide file tree
Showing 6 changed files with 148 additions and 90 deletions.
4 changes: 3 additions & 1 deletion app/Http/Controllers/Auth/AuthController.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public function postRegister(Request $request)
});

if (config('upste.require_user_approval')) {
flash()->success(trans('messages.activation_pending'))->important();
flash()->success(trans('messages.activation_pending', ['email' => $user->email]))->important();
} else {
Auth::login($user);
}
Expand All @@ -82,6 +82,8 @@ protected function validator(array $data)
'name' => 'required|max:255|unique:users|alpha_num',
'email' => 'required|email|max:255|unique:users',
'password' => 'required|confirmed|min:6',
'my_name' => 'honeypot',
'my_time' => 'required|honeytime:5'
];

if (config('upste.recaptcha_enabled')) {
Expand Down
6 changes: 5 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
"laracasts/flash": "1.3.*",
"shrikeh/teapot": "1.0.*",
"intervention/image": "^2.3",
"greggilbert/recaptcha": "^2.1"
"greggilbert/recaptcha": "^2.1",
"msurguy/honeypot": "^1.0"
},
"require-dev": {
"fzaninotto/faker": "~1.4",
Expand Down Expand Up @@ -66,6 +67,9 @@
"php artisan down"
],
"post-update-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postUpdate",
"php artisan ide-helper:generate",
"php artisan ide-helper:meta",
"npm update",
"gulp --production",
"php artisan migrate",
Expand Down
Loading

0 comments on commit a265940

Please sign in to comment.