Software / code / verse
Comparison
plugins/tls.lua @ 428:bde804b01f28
Fix typos (thanks Link Mauve and codespell)
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Mon, 24 Dec 2018 17:35:07 +0100 |
| parent | 384:532a379acfea |
| child | 463:98fe3ed54639 |
comparison
equal
deleted
inserted
replaced
| 427:fafb3639d4aa | 428:bde804b01f28 |
|---|---|
| 8 if features_stanza:get_child("starttls", xmlns_tls) and stream.conn.starttls then | 8 if features_stanza:get_child("starttls", xmlns_tls) and stream.conn.starttls then |
| 9 stream:debug("Negotiating TLS..."); | 9 stream:debug("Negotiating TLS..."); |
| 10 stream:send(verse.stanza("starttls", { xmlns = xmlns_tls })); | 10 stream:send(verse.stanza("starttls", { xmlns = xmlns_tls })); |
| 11 return true; | 11 return true; |
| 12 elseif not stream.conn.starttls and not stream.secure then | 12 elseif not stream.conn.starttls and not stream.secure then |
| 13 stream:warn("SSL libary (LuaSec) not loaded, so TLS not available"); | 13 stream:warn("SSL library (LuaSec) not loaded, so TLS not available"); |
| 14 elseif not stream.secure then | 14 elseif not stream.secure then |
| 15 stream:debug("Server doesn't offer TLS :("); | 15 stream:debug("Server doesn't offer TLS :("); |
| 16 end | 16 end |
| 17 end | 17 end |
| 18 local function handle_tls(tls_status) | 18 local function handle_tls(tls_status) |