Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php namespace App\Http\Controllers\Admin; use App\Http\Controllers\Controller; use Ill..

Decoded Output download

<?php 
 namespace App\Http\Controllers\Admin; use App\Http\Controllers\Controller; use Illuminate\Foundation\Auth\ThrottlesLogins; use Illuminate\Http\Request; use Illuminate\Http\Response; use App\Models\NoCaptcha; use Hash; use Validator; use Auth; class AuthController extends Controller { use ThrottlesLogins; public function index() { return view("admin.auth.login"); } public function login(Request $request) { $credentials = $this->getCredentials($request); $validator = Validator::make($credentials, $this->getValidatorRules()); if ($this->hasTooManyLoginAttempts($request)) { $this->fireLockoutEvent($request); return $this->sendLockoutResponse($request); } if ($validator->fails()) { return redirect()->route("admin::login")->withErrors($validator)->withInput(); } if ($this->guard()->attempt($credentials)) { return redirect()->intended(route("admin::base")); } $this->incrementLoginAttempts($request); flash()->error(trans("auth.failed")); return redirect()->route("admin::login")->withInput(); } public function getValidatorRules() { return array("login" => "required|regex:/[a-zA-Z0-9]$/|max:16", "password" => "required|regex:/[a-zA-Z0-9\#\@\!]$/|max:16"); } public function getCredentials(Request $request) { return array("login" => strtolower($request->login), "password" => $request->password, "enable" => 1); } protected function guard() { return Auth::guard("adm"); } public function username() { return "login"; } public function logout(Request $request) { $this->guard()->logout(); $request->session()->flush(); $request->session()->regenerate(); flash()->success(trans("strings.logoutdone")); return redirect()->route("admin::login"); } } ?>

Did this file decode correctly?

Original Code

<?php
 namespace App\Http\Controllers\Admin; use App\Http\Controllers\Controller; use Illuminate\Foundation\Auth\ThrottlesLogins; use Illuminate\Http\Request; use Illuminate\Http\Response; use App\Models\NoCaptcha; use Hash; use Validator; use Auth; class AuthController extends Controller { use ThrottlesLogins; public function index() { return view("\x61\x64\x6d\x69\x6e\56\141\x75\164\x68\x2e\154\157\147\151\x6e"); } public function login(Request $request) { $credentials = $this->getCredentials($request); $validator = Validator::make($credentials, $this->getValidatorRules()); if ($this->hasTooManyLoginAttempts($request)) { $this->fireLockoutEvent($request); return $this->sendLockoutResponse($request); } if ($validator->fails()) { return redirect()->route("\141\x64\155\x69\156\x3a\x3a\x6c\157\147\x69\x6e")->withErrors($validator)->withInput(); } if ($this->guard()->attempt($credentials)) { return redirect()->intended(route("\x61\144\155\151\156\x3a\x3a\142\141\163\x65")); } $this->incrementLoginAttempts($request); flash()->error(trans("\x61\x75\x74\150\x2e\146\141\x69\154\145\x64")); return redirect()->route("\x61\144\x6d\x69\x6e\x3a\x3a\x6c\157\147\151\156")->withInput(); } public function getValidatorRules() { return array("\154\x6f\147\151\x6e" => "\x72\x65\x71\165\151\162\x65\x64\x7c\x72\145\x67\x65\x78\72\x2f\133\141\55\172\101\55\132\x30\55\71\135\x24\x2f\174\155\x61\x78\72\x31\x36", "\x70\x61\x73\163\x77\157\162\144" => "\x72\x65\161\x75\151\162\145\x64\x7c\162\x65\147\x65\x78\72\x2f\x5b\141\55\172\x41\55\132\60\55\71\134\x23\x5c\100\134\x21\x5d\44\57\174\x6d\x61\x78\72\61\66"); } public function getCredentials(Request $request) { return array("\154\x6f\x67\x69\156" => strtolower($request->login), "\x70\x61\x73\x73\167\x6f\162\144" => $request->password, "\145\x6e\x61\142\154\145" => 1); } protected function guard() { return Auth::guard("\x61\x64\155"); } public function username() { return "\154\x6f\147\151\x6e"; } public function logout(Request $request) { $this->guard()->logout(); $request->session()->flush(); $request->session()->regenerate(); flash()->success(trans("\163\x74\162\x69\156\x67\x73\x2e\154\x6f\147\x6f\x75\164\144\x6f\x6e\145")); return redirect()->route("\x61\144\x6d\x69\x6e\x3a\x3a\154\157\x67\x69\156"); } }

Function Calls

None

Variables

None

Stats

MD5 0f6f995c7580fef9316416a18d7a7205
Eval Count 0
Decode Time 45 ms