stat.S_ISCHR()

stat.S_ISCHR(mode) Return non-zero if the mode is from a character special device file.

stat.S_IMODE()

stat.S_IMODE(mode) Return the portion of the file’s mode that can be set by os.chmod()—that is, the file’s permission bits, plus the sticky bit, set-group-id, and set-user-id bits (on systems that support them).

stat.S_ISDOOR()

stat.S_ISDOOR(mode) Return non-zero if the mode is from a door. New in version 3.4.

stat.S_ISDIR()

stat.S_ISDIR(mode) Return non-zero if the mode is from a directory.

stat.S_ISBLK()

stat.S_ISBLK(mode) Return non-zero if the mode is from a block special device file.

ssl.wrap_socket()

ssl.wrap_socket(sock, keyfile=None, certfile=None, server_side=False, cert_reqs=CERT_NONE, ssl_version={see docs}, ca_certs=None, do_handshake_on_connect=True, suppress_ragged_eofs=True, ciphers=None) Takes an instance sock of socket.socket, and returns an instance of ssl.SSLSocket, a subtype of socket.socket, which wraps the underlying socket in an SSL context. sock must be a SOCK_STREAM socket; other socket types are unsupported. For client-side sockets, the context construction is lazy; i

stat.filemode()

stat.filemode(mode) Convert a file’s mode to a string of the form ‘-rwxrwxrwx’. New in version 3.3. Changed in version 3.4: The function supports S_IFDOOR, S_IFPORT and S_IFWHT.

ssl.SSLZeroReturnError

exception ssl.SSLZeroReturnError A subclass of SSLError raised when trying to read or write and the SSL connection has been closed cleanly. Note that this doesn’t mean that the underlying transport (read TCP) has been closed. New in version 3.3.

ssl.SSLWantWriteError

exception ssl.SSLWantWriteError A subclass of SSLError raised by a non-blocking SSL socket when trying to read or write data, but more data needs to be sent on the underlying TCP transport before the request can be fulfilled. New in version 3.3.

ssl.SSLSocket.version()

SSLSocket.version() Return the actual SSL protocol version negotiated by the connection as a string, or None is no secure connection is established. As of this writing, possible return values include "SSLv2", "SSLv3", "TLSv1", "TLSv1.1" and "TLSv1.2". Recent OpenSSL versions may define more return values. New in version 3.5.