We have a long-standing cyrus-imapd installation that is currently running on RHEL8 using the cyrus-imapd-3.0.7-24.el8.ppc64le version that's installed via standard RPM package management. This system has only ever supported imapd connections using unadorned user names, and all user mailboxes are of the form "user.mailbox". Authentication is done via saslauthd and a special PAM module that we've written to authenticate users against our corporate employee database. I've been trying to configure the system to also allow authentication using the user's email address (in addition to their unadorned cyrus mailbox name), but I've not been successful. Authentication is not a problem, but I cannot convince cyrus-imapd to map an email-based login to the user's underlying mailbox that is not based on an email address.
I've seen all the discussions about using virtual domains, but no configuration changes related to that topic have any bearing on the behavior I'm seeing.
The only thing that allows email-based authentication to work is to list the relevant domain(s) in a "loginrealms" statement. I've also modified my saslauthd invocation to pass the "-r" option, and our PAM authentication module returns success for both types of logins. However, logging in with an email address causes the connecting clients to report a "mailbox not found" error, even though the authentication succeeds. The Roundcube client (for example) reports: "Server Error: STATUS: Mailbox does not exist".
I've built debug versions of the code with additional syslog() statements so I can get an idea what's happening, and there doesn't appear to be any configuration setting that will cause cyrus-imapd to authenticate with an email address (e.g., "person@sample.domain.com") but map that to an unadorned user name (e.g. "person.mailbox"). It looks to me like some additional imapd.conf option like "striploginrealm" would need to be implemented, but I can't see an opportune place in the code where the logic for such an option could be inserted.