Mercurial > hg > nginx-tests
changeset 1984:81519d01f238
Tests: added test that EXTERNAL mail auth clears old password.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Mon, 03 Jun 2024 18:15:22 +0300 |
parents | c7315caf2110 |
children | b5e2609d34a3 |
files | mail_imap.t |
diffstat | 1 files changed, 18 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mail_imap.t Mon Jun 03 04:17:28 2024 +0300 +++ b/mail_imap.t Mon Jun 03 18:15:22 2024 +0300 @@ -93,7 +93,7 @@ EOF $t->run_daemon(\&Test::Nginx::IMAP::imap_test_daemon); -$t->run()->plan(29); +$t->run()->plan(30); $t->waitforsocket('127.0.0.1:' . port(8144)); @@ -184,6 +184,23 @@ $s->send('1 AUTHENTICATE EXTERNAL ' . encode_base64('test@example.com', '')); $s->ok('auth external with username'); +# auth external after failed plain + +TODO: { +local $TODO = 'not yet' unless $t->has_version('1.27.1'); + +$s = Test::Nginx::IMAP->new(); +$s->read(); + +$s->send('1 AUTHENTICATE PLAIN ' + . encode_base64("\0test\@example.com\0bad", '')); +$s->read(); + +$s->send('1 AUTHENTICATE EXTERNAL ' . encode_base64('test@example.com', '')); +$s->ok('auth external after plain'); + +} + # quoted strings $s = Test::Nginx::IMAP->new();