Support the ongoing development of Laravel.io →
Authentication Packages

I have a Lumen app that need to lookup user details form LDAP.

I am trying to use the adLDAP package (https://packagist.org/packages/adldap/adldap) and have pulled the package in via composer. The package exists in the vendor directory.

However I am unable to reference it in my controller and get the following error:

ReflectionException in Container.php line 595: Class lib\adLDAP\adLDAP does not exist

I have tried the following paths but all fail with the same error:

adldap/adldap/lib/adLDAP/adLDAP
adldap/lib/adLDAP/adLDAP
lib/adLDAP/adLDAP
adLDAP/adLDAP

here's my controller

<?php namespace App\Http\Controllers;

use App\Http\Controllers\Controller;
use lib\adLDAP\adLDAP as LDAP;

class UserController extends Controller
{
    /**
     * Authenticate and Load User from LDAP
     * @return JSON 
     */
    public function authenticate(LDAP $ldap)
    {	

        dd($ldap);
    }
}

What do I need to do to use this package properly?

Last updated 3 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Blackpig blackpig Joined 6 May 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.