tarickb / sasl-xoauth2

SASL plugin for XOAUTH2
Other
72 stars 20 forks source link

include a simple way to test a sasl-xoauth2 configuration #32

Closed dkg closed 1 year ago

dkg commented 2 years ago

It would be great to have a way to test a sasl-xoauth2 configuration, even if the test only knows how to test the authentication against one particular network service. That is, even a test that only knows how to confirm that (for example) it can successfully authenticate to a gmail account (and it doesn't know how to authenticate against outlook) that would be really useful. But i'm not sure the best way to do that. I took a look at trying to drive the module with python-sasl but i hit a wall due to lack of documentation for that module and my general confusion around the twisty SASL maze.

Maybe there's some way to coax /usr/lib/postfix/sbin/smtp to do the test for us if it's installed? Or dynamically generate a narrow, targeted postfix instance and tear it down after the test? I'm open to suggestions on how to test, as long as they don't require integration with a live, full-blown, functional MTA on the local machine (i want to be able to test without interfering with the local MTA).

I'd like to package this tool for distribution in Debian, and not having a programmatic way to easily tell whether a given installation is working makes me nervous.

tarickb commented 1 year ago

Thanks, this was a great suggestion. I've included sasl-xoauth2-test-config in 0.15, and described its use in the README.