public class BasicServerAuthHandler extends Object implements ServerAuthHandler
Modifier and Type | Class and Description |
---|---|
static interface |
BasicServerAuthHandler.BasicAuthValidator
Interface that this handler delegates for determining if credentials are valid.
|
ServerAuthHandler.ServerAuthSender
NO_OP
Constructor and Description |
---|
BasicServerAuthHandler(BasicServerAuthHandler.BasicAuthValidator authValidator) |
Modifier and Type | Method and Description |
---|---|
boolean |
authenticate(ServerAuthHandler.ServerAuthSender outgoing,
Iterator<byte[]> incoming)
Handle the initial handshake with the client.
|
Optional<String> |
isValid(byte[] token)
Validate the client token provided on each call.
|
public BasicServerAuthHandler(BasicServerAuthHandler.BasicAuthValidator authValidator)
public boolean authenticate(ServerAuthHandler.ServerAuthSender outgoing, Iterator<byte[]> incoming)
ServerAuthHandler
authenticate
in interface ServerAuthHandler
outgoing
- A writer to send messages to the client.incoming
- An iterator of messages from the client.public Optional<String> isValid(byte[] token)
ServerAuthHandler
isValid
in interface ServerAuthHandler
Copyright © 2023 The Apache Software Foundation. All rights reserved.