1<?php
2
3/**
4 * This file is part of the FreeDSx LDAP package.
5 *
6 * (c) Chad Sikorra <Chad.Sikorra@gmail.com>
7 *
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
10 */
11
12namespace FreeDSx\Ldap\Protocol\ServerProtocolHandler;
13
14use FreeDSx\Ldap\Exception\OperationException;
15use FreeDSx\Ldap\Protocol\LdapMessageRequest;
16use FreeDSx\Ldap\Protocol\Queue\ServerQueue;
17use FreeDSx\Ldap\Server\RequestHandler\RequestHandlerInterface;
18use FreeDSx\Ldap\Server\Token\TokenInterface;
19
20/**
21 * Used for handlers dealing with bind requests to send back tokens.
22 *
23 * @author Chad Sikorra <Chad.Sikorra@gmail.com>
24 */
25interface BindHandlerInterface
26{
27    /**
28     * Returns a token indicating the outcome of a bind request.
29     *
30     * @throws OperationException
31     */
32    public function handleBind(LdapMessageRequest $message, RequestHandlerInterface $dispatcher, ServerQueue $queue, array $options): TokenInterface;
33}
34