-while ((s = string_nextinlist(&prompts, &sep, big_buffer, big_buffer_size))
- != NULL && expand_nmax < EXPAND_MAXN)
- {
- if (number++ <= expand_nmax) continue;
- if ((rc = auth_get_data(&data, s, Ustrlen(s))) != OK) return rc;
- if ((len = auth_b64decode(data, &clear)) < 0) return BAD64;
- end = clear + len;
-
- /* This loop must run at least once, in case the length is zero */
- do
- {
- expand_nstring[++expand_nmax] = clear;
- while (*clear != 0) clear++;
- expand_nlength[expand_nmax] = clear++ - expand_nstring[expand_nmax];
- }
- while (clear < end && expand_nmax < EXPAND_MAXN);
- }
-
-/* We now have a number of items of data in $1, $2, etc. Match against the
-decoded data by expanding the condition. Also expand the id to set if
-authentication succeeds. */
-
-cond = expand_string(ob->server_condition);
-
-HDEBUG(D_auth)
- {
- int i;
- debug_printf("%s authenticator:\n", ablock->name);
- for (i = 1; i <= expand_nmax; i++)
- debug_printf(" $%d = %.*s\n", i, expand_nlength[i], expand_nstring[i]);
- debug_print_string(ablock->server_debug_string); /* customized debug */
- if (cond == NULL)
- debug_printf("expansion failed: %s\n", expand_string_message);
- else
- debug_printf("expanded string: %s\n", cond);
- }
-
-/* A forced expansion failure causes authentication to fail. Other expansion
-failures yield DEFER, which will cause a temporary error code to be returned to
-the AUTH command. The problem is at the server end, so the client should try
-again later. */
+while ( (s = string_nextinlist(&prompts, &sep, NULL, 0))
+ && expand_nmax < EXPAND_MAXN)
+ if (number++ > expand_nmax)
+ if ((rc = auth_prompt(CUS s)) != OK)
+ return rc;