Field list for oAuth authentication

@return array|null
324712
private function getOauthFields()
    {
        $this->oAuthFields = [
            'grant_type' => 'client_credentials',
            'scope' => $this->scope,
            'client_secret' => $this->mpClientSecret,
            'client_id' => $this->mpClientId,
        ];

        $this->fieldCount = count($this->oAuthFields);

        return $this->oAuthFields;
    }
157685
public function getRequestCredentials()
    {
        if ($this->requestCredentials === null) {
            $this->requestCredentials = function () {
                $credentials = [];

                if (isset($_SERVER['PHP_AUTH_USER'])) {
                    $credentials['login'] = $_SERVER['PHP_AUTH_USER'];
                }

                if (isset($_SERVER['PHP_AUTH_PW'])) {
                    $credentials['password'] = $_SERVER['PHP_AUTH_PW'];
                }

                if (count($credentials) > 0) {
                    return $credentials;
                }
            };
        }

        $credentials = $this->requestCredentials;

        return $credentials();
    }
407671
public function getCredentials(Request $request)
    {
        // Get token and key
        $parameterToken = $request->query->get('rd-auth-token');

        if (!$parameterToken) {
            // no token, nonce or app? Return null and no other methods will be called
            return;
        }

        // What you return here will be passed to getUser() as $credentials
        $token = new Token;
        $token->fromParameter($parameterToken);

        return array(
            'token'     => $token,
            'parameter' => $parameterToken,
        );
    }
184791
public function getLoginForms()
    {
        Deprecation::notice('5.0.0', 'Now handled by delegateToMultipleHandlers');

        return array_map(
            function (Authenticator $authenticator) {
                return [
                    $authenticator->getLoginHandler($this->Link())->loginForm()
                ];
            },
            $this->getApplicableAuthenticators()
        );
    }
43505
public function getAccessToken() 
    {
        $result = null;
        $options = $this->config->getAccessTokenConfiguration();
        $token = $this->getResponse('/oauth/token', $options);
        if (isset($token['access_token'])) {
            $this->config->setBearer($token['access_token']);
        }else {
            echo 'ERROR: no access token in API response';
        }
    }
598331
public function getAuthenticationScopes(): array
    {

        // If we don't have any authentication data, then
        // only public calls can be made.
        if (is_null($this->getAuthentication()))
            return ['public'];

        // If there are no scopes that we know of, update them.
        // There will always be at least 1 as we add the internal
        // 'public' scope.
        if (count($this->getAuthentication()->scopes) <= 0)
            $this->setAuthenticationScopes();

        return $this->getAuthentication()->scopes;
    }
972370
protected function getBasicAuthorizationHeaderInfo()
    {
        $dateTime = new \DateTime();
        $headerParameters = [
            'oauth_callback'         => $this->credentials->getCallbackUrl(),
            'oauth_consumer_key'     => $this->credentials->getConsumerId(),
            'oauth_nonce'            => $this->generateNonce(),
            'oauth_signature_method' => $this->getSignatureMethod(),
            'oauth_timestamp'        => $dateTime->format('U'),
            'oauth_version'          => $this->getVersion(),
        ];

        return $headerParameters;
    }
797461
public function getServerCredentials()
    {
        if (is_null($this->server)) {
            return [];
        }

        return isset($this->servers[$this->server]) ? $this->servers[$this->server] : [];
    }
700197
public static function get_headers() {
    $headers = OAuthUtil::get_headers_internal();
    if ( ! is_array($headers) ) return $headers;
    if ( (! isset($headers['Authorization'])) && isset($headers['X-Oauth1-Authorization']) ) {
        $headers['Authorization'] = $headers['X-Oauth1-Authorization'];
    }
    return $headers;
  }
81819
public function listAction()
    {
        $clients = $this->oauthManager->findVisibleClients();
        $friendRequests = $this->oauthManager->findAllFriendRequests();
        $pendingFriends = $this->oauthManager->findAllPendingFriends();

        return [
            'clients' => $clients,
            'friendRequests' => $friendRequests,
            'pendingFriends' => $pendingFriends,
        ];
    }
215837
protected function obtainOAuthClientData()
    {
        $oauth = resolve(\Acacha\LaravelSocial\Services\OAuthApp::class);
        $oauth->setId(trim($this->command->ask('OAuth client id?')));
        $oauth->setSecret(trim($this->command->ask('OAuth client secret?')));
        $oauth->setRedirectUrl(trim($this->command->ask('OAuth client redirect URL?', $this->getDefaultRedirectURL())));

        $service = resolve(\Acacha\LaravelSocial\Services\LaravelSocialiteService::class);
        $service->app($oauth)->social(strtolower($this->name()))->handle();
        $this->command->info(ucfirst($this->name()) . ' added to config/services.php file');
    }
432246
public function getMetaInfo()
    {
        if ($this->getAuthenticationDetails() instanceof AuthenticationDetails) {
            $authId     = $this->getAuthenticationDetails()->getAuthId();
            $authMethod = $this->getAuthenticationDetails()->getAuthMethod();
            $authRole   = $this->getAuthenticationDetails()->getAuthRole();
            $authRoles  = $this->getAuthenticationDetails()->getAuthRoles();
        } else {
            $authId     = 'anonymous';
            $authMethod = 'anonymous';
            $authRole   = 'anonymous';
            $authRoles  = [];
        }

        return [
            'realm'         => $this->getRealm()->getRealmName(),
            'authprovider'  => null,
            'authid'        => $authId,
            'authrole'      => $authRole,
            'authroles'     => $authRoles,
            'authmethod'    => $authMethod,
            'session'       => $this->getSessionId(),
            'role_features' => $this->getRoleFeatures()
        ];
    }
1250567
public function getAccountActivationToken()
    {
        $username = $this->httpRequest()->post('username');
        $token = $this->getLoginInstance()->getAccountConfirmationToken($username);

        return ['accountActivationToken' => $token];
    }
429210
protected function getResetPasswordMailFields()
    {
    	if ($this->user->getUserId()) {
    		$result = $this->user->getResetPasswordMailFields();
    	} else {
    		$result['reset_key'] = '';
        	$result['reset_url'] = '';

    	}
    	return $result;
    }
911721
function get($field_name, $default=null)
    {
        if (!Auth_OpenID_checkFieldName($field_name)) {
            return null;
        }

        return Auth_OpenID::arrayGet($this->data, $field_name, $default);
    }
133468
private function get_defaults() {
    $defaults = array(
      'oauth_version'          => $this->config['oauth_version'],
      'oauth_nonce'            => $this->config['nonce'],
      'oauth_timestamp'        => $this->config['timestamp'],
      'oauth_consumer_key'     => $this->config['consumer_key'],
      'oauth_signature_method' => $this->config['oauth_signature_method'],
    );

    // include the user token if it exists
    if ( $this->config['user_token'] )
      $defaults['oauth_token'] = $this->config['user_token'];

    // safely encode
    foreach ($defaults as $k => $v) {
      $_defaults[$this->safe_encode($k)] = $this->safe_encode($v);
    }

    return $_defaults;
  }
662871
public function fields(): array
    {
        return [
            Input::make('role.name')
                ->type('text')
                ->max(255)
                ->required()
                ->title(__('Name'))
                ->placeholder(__('Name'))
                ->help(__('User role display name')),

            Input::make('role.slug')
                ->type('text')
                ->max(255)
                ->required()
                ->title(__('Slug'))
                ->placeholder(__('Slug'))
                ->help(__('Actual name in the system')),
        ];
    }