H12-891_V1.0 · Question #177
Python Paramiko implements the SSH protocol. In the Python Paramiko module, which of the following classes is used to create an SFTP session connection and perform remote file operations?
The correct answer is C. SFTP Client class. SFTPClient is the class specifically designed for SFTP sessions - it provides methods like get(), put(), listdir(), and remove() for interacting with remote files over SSH, making it the direct answer for remote file operations. The distractors each play a different layer of…
Question
Python Paramiko implements the SSH protocol. In the Python Paramiko module, which of the following classes is used to create an SFTP session connection and perform remote file operations?
Options
- ATransport class
- BPacketizer class
- CSFTP Client class
- DChannel class
How the community answered
(32 responses)- A6% (2)
- B3% (1)
- C81% (26)
- D9% (3)
Explanation
SFTPClient is the class specifically designed for SFTP sessions - it provides methods like get(), put(), listdir(), and remove() for interacting with remote files over SSH, making it the direct answer for remote file operations.
The distractors each play a different layer of the SSH stack: Transport (A) manages the underlying encrypted SSH connection and negotiates keys, but it doesn't expose file operations directly - you actually call Transport.open_sftp_client() to get an SFTPClient, which hints at the relationship. Packetizer (B) operates even lower, handling raw SSH packet framing and encryption; it's an internal implementation detail that application code never touches directly. Channel (D) represents a generic SSH channel used for things like executing remote commands or port forwarding, not file transfer.
Memory tip: Think of the class hierarchy as a stack - Packetizer → Transport → Channel/SFTPClient. If the exam question mentions files, you want SFTPClient; if it mentions commands or tunnels, think Channel.
Topics
Community Discussion
No community discussion yet for this question.