Skip to content

Conversation

@nevans
Copy link
Collaborator

@nevans nevans commented Sep 29, 2023

Making some minor API changes to SASL::Authenticators. This class hasn't been included in a release yet, so there's no need to deprecate anything... if the change is made before the release. :)

Since they haven't been in any release yet, `SASL.initial_response?` and
`SASL.done?` have been removed without deprecation.  The logic has been
moved directly into `Net::IMAP#authenticate` (for now).

Implementing `#initial_response?` is still optional.  But, to simplify
the tests, `#initial_response? => false` was added to all of the
deprecated SASL mechanisms.
Reversed the `use_defaults` default, and added another option for
`use_deprecated`.
Abstracts running a command with a continuation handler.

In the base specifications (both RFC-3501 and RFC-9051), the only
command to need this is `AUTHENTICATE`.  The only other continuations
are for sending literals, which are simple command arguments.  Are there
any IMAP extensions that use continuations in this way?

Even with only one command, this still makes that code a little more
readable.  More importantly, it also simplifies the creation of a
generic SASL protocol adapter, for use by `net-sasl`, `net-pop`, and
others.
@nevans nevans merged commit cb52a2d into master Sep 29, 2023
@nevans nevans deleted the sasl/prerelease-api-changes branch September 29, 2023 14:14
@nevans nevans added the SASL 🔒 Authentication and authentication mechanisms label Oct 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

SASL 🔒 Authentication and authentication mechanisms

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants