diff options
author | Gilles Chehade <gilles@poolp.org> | 2018-06-15 20:22:40 +0200 |
---|---|---|
committer | Gilles Chehade <gilles@poolp.org> | 2018-06-15 20:22:40 +0200 |
commit | 44d280914d95bbb2967ac84bf9151b7f0ce48df4 (patch) | |
tree | 6e36357bcda5cca4ff5009aa381b949fd1f8cee9 /smtpd/to.c | |
parent | sync (diff) | |
download | OpenSMTPD-44d280914d95bbb2967ac84bf9151b7f0ce48df4.tar.xz OpenSMTPD-44d280914d95bbb2967ac84bf9151b7f0ce48df4.zip |
sync with openbsd
Diffstat (limited to 'smtpd/to.c')
-rw-r--r-- | smtpd/to.c | 26 |
1 files changed, 13 insertions, 13 deletions
@@ -1,4 +1,4 @@ -/* $OpenBSD: to.c,v 1.30 2018/05/29 21:05:52 eric Exp $ */ +/* $OpenBSD: to.c,v 1.31 2018/06/07 11:31:51 eric Exp $ */ /* * Copyright (c) 2009 Jacek Masiulaniec <jacekm@dobremiasto.net> @@ -311,14 +311,14 @@ text_to_relayhost(struct relayhost *relay, const char *s) * schema index needs to be updated later in this function. */ { "smtp://", 0 }, - { "lmtp://", F_LMTP }, - { "smtp+tls://", F_TLS_OPTIONAL }, - { "smtps://", F_SMTPS }, - { "tls://", F_STARTTLS }, - { "smtps+auth://", F_SMTPS|F_AUTH }, - { "tls+auth://", F_STARTTLS|F_AUTH }, - { "secure://", F_SMTPS|F_STARTTLS }, - { "secure+auth://", F_SMTPS|F_STARTTLS|F_AUTH } + { "lmtp://", RELAY_LMTP }, + { "smtp+tls://", RELAY_TLS_OPTIONAL }, + { "smtps://", RELAY_SMTPS }, + { "tls://", RELAY_STARTTLS }, + { "smtps+auth://", RELAY_SMTPS|RELAY_AUTH }, + { "tls+auth://", RELAY_STARTTLS|RELAY_AUTH }, + { "secure://", RELAY_SMTPS|RELAY_STARTTLS }, + { "secure+auth://", RELAY_SMTPS|RELAY_STARTTLS|RELAY_AUTH } }; const char *errstr = NULL; char *p, *q; @@ -351,7 +351,7 @@ text_to_relayhost(struct relayhost *relay, const char *s) relay->flags = schemas[i].flags; /* need to specify an explicit port for LMTP */ - if (relay->flags & F_LMTP) + if (relay->flags & RELAY_LMTP) relay->port = 0; /* first, we extract the label if any */ @@ -395,11 +395,11 @@ text_to_relayhost(struct relayhost *relay, const char *s) if (!valid_domainpart(relay->hostname)) return 0; - if ((relay->flags & F_LMTP) && (relay->port == 0)) + if ((relay->flags & RELAY_LMTP) && (relay->port == 0)) return 0; - if (relay->authlabel[0] == '\0' && relay->flags & F_AUTH) + if (relay->authlabel[0] == '\0' && relay->flags & RELAY_AUTH) return 0; - if (relay->authlabel[0] != '\0' && !(relay->flags & F_AUTH)) + if (relay->authlabel[0] != '\0' && !(relay->flags & RELAY_AUTH)) return 0; return 1; } |