Skip to content

Commit

Permalink
SESSION_SSL=NEVER
Browse files Browse the repository at this point in the history
Signed-off-by: Neil Johnson <najohnsn@us.ibm.com>
  • Loading branch information
najohnsn committed Sep 18, 2024
1 parent a934485 commit 589a323
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tnz/tnz.py
Original file line number Diff line number Diff line change
Expand Up @@ -2144,7 +2144,8 @@ def _process(self, data):
self.send_do(25, buffer=True)

elif data[2] == 46: # START_TLS
if not hasattr(self.__loop, "start_tls"):
ssl_never = os.environ.get("SESSION_SSL") == "NEVER"
if ssl_never or not hasattr(self.__loop, "start_tls"):
self._log_warn("START_TLS unsupported.")
self._log_warn("Python >= 3.7 required")
self.send_wont(data[2], buffer=True)
Expand Down

0 comments on commit 589a323

Please sign in to comment.