2017 © Pedro PelĂĄez
 

library ntlm-http-auth

Extension for Nette Framework: NTLM authenticate for authenticator

image

sivin/ntlm-http-auth

Extension for Nette Framework: NTLM authenticate for authenticator

  • Sunday, January 29, 2017
  • by SiViN
  • Repository
  • 1 Watchers
  • 0 Stars
  • 16 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

License Total Downloads, (*1)

NtlmHttpAuth

  1. Install via composer
composer require sivin/ntlm-http-auth
  1. Register extension in config.neon:
extensions:
    ntlmHttpAuth: SiViN\NtlmHttpAuth\DI\NtlmHttpAuthExtension

3, Tell which presenters should not be secured (in case no presenter name given, all presenters are secured). Format - Module:Presenter:, (*2)

ntlmHttpAuth:
    excludedPresenters: [Front:Nonsecured] # Exlude presenter class App\FrontModule\Presenters\NonsecuredPresenter

4, Implement SiViN\NtlmHttpAuth\INtlmAuthenticator to your authenticator Inconfig.neon:, (*3)

services:
    authenticator: NtlmAuthenticator

File NtlmAuthenticator.php:, (*4)

class NtlmAuthenticator implements \Nette\Security\IAuthenticator, \SiViN\NtlmHttpAuth\INtlmAuthenticator
{
    function authenticate(array $credentials)
    {
        ...
    }

    function ntlmAuthenticate(\SiViN\NtlmHttpAuth\AuthenticateResult $authenticateResult)
    {
        if($this->LdapOrDbOrSomething($authenticateResult->username, $authenticateResult->domain, $authenticateResult->workstation))
        {
            return new \Nette\Security\Identity(...);
        }
        else
        {
            throw new \Nette\Security\AuthenticationException('User not found', self::IDENTITY_NOT_FOUND);
        }
    }
}

The Versions

29/01 2017

dev-master

9999999-dev

Extension for Nette Framework: NTLM authenticate for authenticator

  Sources   Download

MIT

The Requires

 

by Milan SiViN SivĂĄk

extension security ntlm ntlm-http-auth

29/01 2017

1.0.0

1.0.0.0

Extension for Nette Framework: NTLM authenticate for authenticator

  Sources   Download

MIT

The Requires

 

by Milan SiViN SivĂĄk

extension security ntlm ntlm-http-auth