diff options
| author | shtrophic <christoph@liebender.dev> | 2025-01-24 22:24:05 +0100 |
|---|---|---|
| committer | shtrophic <christoph@liebender.dev> | 2025-01-24 22:24:05 +0100 |
| commit | 3d96c576287736ebdf87e4a7b956842a6c6e055f (patch) | |
| tree | ad5f4cc5ebc9913ccfd753edfc934b82e34be72e /activitypub.c | |
| parent | 1c4c15540360a5db9d56e6ae8d206a1f30a4f52b (diff) | |
enforce tls when supported && add tests
Diffstat (limited to 'activitypub.c')
| -rw-r--r-- | activitypub.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/activitypub.c b/activitypub.c index 4cb779a..f3b2bae 100644 --- a/activitypub.c +++ b/activitypub.c @@ -2538,8 +2538,9 @@ int send_email(const xs_dict *mailinfo) *from = xs_dict_get(mailinfo, "from"), *to = xs_dict_get(mailinfo, "to"), *body = xs_dict_get(mailinfo, "body"); + int smtp_port = parse_port(url, NULL); - return xs_smtp_request(url, user, pass, from, to, body); + return xs_smtp_request(url, user, pass, from, to, body, smtp_port == 465 || smtp_port == 587); } |