Mercurial > prosody-hg
comparison core/s2smanager.lua @ 2538:0db17d1f77fb
s2smanager: require_s2s_encryption -> s2s_require_encryption
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Sat, 30 Jan 2010 17:00:47 +0000 |
| parents | 80641e786b35 |
| children | 7174e6ea069d |
comparison
equal
deleted
inserted
replaced
| 2537:80641e786b35 | 2538:0db17d1f77fb |
|---|---|
| 453 end | 453 end |
| 454 | 454 |
| 455 function make_authenticated(session, host) | 455 function make_authenticated(session, host) |
| 456 if not session.secure then | 456 if not session.secure then |
| 457 local local_host = session.direction == "incoming" and session.to_host or session.from_host; | 457 local local_host = session.direction == "incoming" and session.to_host or session.from_host; |
| 458 if config.get(local_host, "core", "require_s2s_encryption")) then | 458 if config.get(local_host, "core", "s2s_require_encryption")) then |
| 459 session:close({ | 459 session:close({ |
| 460 condition = "policy-violation", | 460 condition = "policy-violation", |
| 461 text = "Encrypted server-to-server communication is required but was not " | 461 text = "Encrypted server-to-server communication is required but was not " |
| 462 ..((session.direction == "outgoing" and "offered") or "used") | 462 ..((session.direction == "outgoing" and "offered") or "used") |
| 463 }); | 463 }); |
