Includes: API (Express/TypeScript), Astro site, Python workers, document generators, FCC compliance tools, Canada CRTC formation, Ansible infrastructure, and deployment scripts. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
21 lines
603 B
Python
21 lines
603 B
Python
"""FTPS (explicit TLS) transport — inherits FTP transport behavior."""
|
|
|
|
from __future__ import annotations
|
|
|
|
import ftplib
|
|
|
|
from .ftp_transport import FTPTransport
|
|
|
|
|
|
class FTPSTransport(FTPTransport):
|
|
TRANSPORT_SLUG = "ftps"
|
|
_FTP_CLASS = ftplib.FTP_TLS
|
|
|
|
def _connect(self):
|
|
conn = self._FTP_CLASS(timeout=self.timeout)
|
|
conn.connect(self.host, self.port or 21)
|
|
conn.login(self.username or "", self.password or "")
|
|
# Enable encryption on the data channel too (most servers require this)
|
|
conn.prot_p()
|
|
conn.sendcmd("TYPE I")
|
|
return conn
|