Your Own SaslClient and ClientFactory

Your SASL client class must implement the SASLClient interface. You need to implement the following methods in your class:

  • public String getMechanismName returns the IANA-registered mechanism name of this SASL client (for example, "CRAM-MD5", "GSSAPI").

  • public byte[] createInitialResponse throws SaslException returns the initial authentication request that will be sent to the server. Not all mechanisms involve an initial request from the client. If there is no initial request, the method returns null.

  • public byte[] evaluateChallenge(byte[] challenge) throws SaslException evaluates a server challenge and returns a response to the challenge. The return value should be null if (1) the challenge accompanied a ...

Get LDAP Programming with Java™ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.