20#define PORT_POP3S "995"
31 r = timeoutread(1200,
fd,
buf,len);
39 r = timeoutwrite(1200,
fd,
buf,len);
82void logn(
char *s) {
if (buffer_puts(&
bl,s) == -1)
_exit(1);
if (buffer_flush(&
bl) == -1)
_exit(1); }
84void log_pop(
char *s1,
char *s2,
char *s3,
char *s4,
char *s5,
char *s6)
96 err(
"TLS required but not negotiated");
146 switch (child = fork()) {
167 if (wait_pid(&wstat,child) == -1)
die();
171 if (wait_exitcode(wstat)) {
184 s += fmt_uint(s,getpid());
186 s += fmt_ulong(s,(
unsigned long)
now());
224 space = arg + str_chr(arg,
' ');
233 outs(
"+OK capability list follows\r\n");
248 return err(
"STLS not available");
249 outs(
"+OK starting TLS negotiation\r\n");
292 pop3auth = env_get(
"POP3AUTH");
294 if (case_starts(pop3auth,
"apop"))
apop = 2;
295 if (case_starts(pop3auth,
"+apop"))
apop = 1;
int stralloc_copys(stralloc *, char const *)