World Library  
Flag as Inappropriate
Email this Article

Files transferred over shell protocol

Article Id: WHEBN0005514699
Reproduction Date:

Title: Files transferred over shell protocol  
Author: World Heritage Encyclopedia
Language: English
Subject: Secure Shell, Comparison of file managers, Dropbear (software), Network file transfer protocols, Fish (disambiguation)
Collection: Network File Transfer Protocols
Publisher: World Heritage Encyclopedia
Publication
Date:
 

Files transferred over shell protocol

Files transferred over Shell protocol (FISH) is a network protocol that uses Secure Shell (SSH) or Remote Shell (RSH) to transfer files between computers and manage remote files.

The advantage of FISH is that all it requires on the server-side is an SSH or RSH implementation, Unix shell, and a set of standard Unix utilities (like ls, cat or dd—unlike other methods of remote access to files via a remote shell, scp for example, which requires scp on the server side). Optionally, there can be a special FISH server program (called start_fish_server) on the server, which executes FISH commands instead of Unix shell and thus speeds up operations.

The protocol was designed by Pavel Machek in 1998 for the Midnight Commander software tool.

Contents

  • Protocol messages 1
  • Session initiation 2
  • Implementations 3
  • See also 4
  • External links 5

Protocol messages

Client sends text requests of the following form:

#FISH_COMMAND arguments...
equivalent shell commands,
which may be multi-line

Fish commands are all defined, shell equivalents may vary. Fish commands always have priority: the server is expected to execute a fish command if it understands it. If it does not, however, it can try and execute a shell command. When there is no special server program, Unix shell ignores the fish command as a comment and executes the equivalent shell command(s).

Server replies are multi-line, but always end with

### xyz

line. ### is a prefix to mark this line, xyz is the return code. Return codes are superset to those used in ftp. The codes 000 and 001 are special, their meaning depends on presence of server output before the end line.

Session initiation

The client initiates SSH or RSH connection with echo FISH:;/bin/sh as the command executed on remote machine. This should make it possible for the server to distinguish FISH connections from normal RSH or SSH.

The first two commands sent to the server are FISH and VER to negotiate FISH protocol, its version and extensions.

#FISH
echo; start_fish_server; echo '### 200'
#VER 0.0.2   <...>
echo '### 000'

The server may reply to VER command with a lines like

VER 0.0.0  <...>
### 200

which indicates supported version of the FISH protocol and supported extensions.

Implementations

See also

External links

  • README.fish from Midnight Commander
This article was sourced from Creative Commons Attribution-ShareAlike License; additional terms may apply. World Heritage Encyclopedia content is assembled from numerous content providers, Open Access Publishing, and in compliance with The Fair Access to Science and Technology Research Act (FASTR), Wikimedia Foundation, Inc., Public Library of Science, The Encyclopedia of Life, Open Book Publishers (OBP), PubMed, U.S. National Library of Medicine, National Center for Biotechnology Information, U.S. National Library of Medicine, National Institutes of Health (NIH), U.S. Department of Health & Human Services, and USA.gov, which sources content from all federal, state, local, tribal, and territorial government publication portals (.gov, .mil, .edu). Funding for USA.gov and content contributors is made possible from the U.S. Congress, E-Government Act of 2002.
 
Crowd sourced content that is contributed to World Heritage Encyclopedia is peer reviewed and edited by our editorial staff to ensure quality scholarly research articles.
 
By using this site, you agree to the Terms of Use and Privacy Policy. World Heritage Encyclopedia™ is a registered trademark of the World Public Library Association, a non-profit organization.
 


Copyright © World Library Foundation. All rights reserved. eBooks from Project Gutenberg are sponsored by the World Library Foundation,
a 501c(4) Member's Support Non-Profit Organization, and is NOT affiliated with any governmental agency or department.