annotate docs/rfcs/draft-ietf-secsh-filexfer-04.txt @ 962:26fb4e66736c

2008-11-29 Brian Masney <masneyb@gftp.org> * lib/fsplib/* - updated to use fsplib 0.9
author masneyb
date Sat, 29 Nov 2008 12:49:37 +0000
parents e60a6ec4aa85
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
497
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
3
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
4 Secure Shell Working Group J. Galbraith
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
5 Internet-Draft VanDyke Software
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
6 Expires: June 18, 2003 T. Ylonen
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
7 S. Lehtinen
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
8 SSH Communications Security Corp
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
9 December 18, 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
10
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
11
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
12 SSH File Transfer Protocol
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
13 draft-ietf-secsh-filexfer-04.txt
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
14
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
15 Status of this Memo
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
16
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
17 This document is an Internet-Draft and is in full conformance with
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
18 all provisions of Section 10 of RFC2026.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
19
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
20 Internet-Drafts are working documents of the Internet Engineering
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
21 Task Force (IETF), its areas, and its working groups. Note that
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
22 other groups may also distribute working documents as
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
23 Internet-Drafts.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
24
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
25 Internet-Drafts are draft documents valid for a maximum of six months
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
26 and may be updated, replaced, or obsoleted by other documents at any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
27 time. It is inappropriate to use Internet-Drafts as reference
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
28 material or to cite them other than as "work in progress."
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
29
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
30 The list of current Internet-Drafts can be accessed at http://
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
31 www.ietf.org/ietf/1id-abstracts.txt.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
32
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
33 The list of Internet-Draft Shadow Directories can be accessed at
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
34 http://www.ietf.org/shadow.html.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
35
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
36 This Internet-Draft will expire on June 18, 2003.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
37
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
38 Copyright Notice
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
39
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
40 Copyright (C) The Internet Society (2002). All Rights Reserved.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
41
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
42 Abstract
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
43
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
44 The SSH File Transfer Protocol provides secure file transfer
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
45 functionality over any reliable data stream. It is the standard file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
46 transfer protocol for use with the SSH2 protocol. This document
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
47 describes the file transfer protocol and its interface to the SSH2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
48 protocol suite.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
49
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
50
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
51
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
52
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
53
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
54
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
55
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
56 Galbraith, et al. Expires June 18, 2003 [Page 1]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
57
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
58 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
59
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
60
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
61 Table of Contents
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
62
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
63 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . 3
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
64 2. Use with the SSH Connection Protocol . . . . . . . . . . . 4
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
65 3. General Packet Format . . . . . . . . . . . . . . . . . . 5
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
66 3.1 The use of stderr in the server . . . . . . . . . . . . . 6
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
67 4. Protocol Initialization . . . . . . . . . . . . . . . . . 8
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
68 4.1 Client Initialization . . . . . . . . . . . . . . . . . . 8
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
69 4.2 Server Initialization . . . . . . . . . . . . . . . . . . 8
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
70 4.3 Determining Server Newline Convention . . . . . . . . . . 9
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
71 5. File Attributes . . . . . . . . . . . . . . . . . . . . . 10
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
72 5.1 Flags . . . . . . . . . . . . . . . . . . . . . . . . . . 10
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
73 5.2 Type . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
74 5.3 Size . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
75 5.4 Owner and Group . . . . . . . . . . . . . . . . . . . . . 11
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
76 5.5 Permissions . . . . . . . . . . . . . . . . . . . . . . . 12
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
77 5.6 Times . . . . . . . . . . . . . . . . . . . . . . . . . . 12
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
78 5.7 ACL . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
79 5.8 Extended attributes . . . . . . . . . . . . . . . . . . . 14
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
80 6. Requests From the Client to the Server . . . . . . . . . . 15
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
81 6.1 Request Synchronization and Reordering . . . . . . . . . . 15
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
82 6.2 File Names . . . . . . . . . . . . . . . . . . . . . . . . 16
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
83 6.3 Opening, Creating, and Closing Files . . . . . . . . . . . 16
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
84 6.4 Reading and Writing . . . . . . . . . . . . . . . . . . . 19
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
85 6.5 Removing and Renaming Files . . . . . . . . . . . . . . . 20
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
86 6.6 Creating and Deleting Directories . . . . . . . . . . . . 21
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
87 6.7 Scanning Directories . . . . . . . . . . . . . . . . . . . 21
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
88 6.8 Retrieving File Attributes . . . . . . . . . . . . . . . . 22
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
89 6.9 Setting File Attributes . . . . . . . . . . . . . . . . . 23
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
90 6.10 Dealing with Symbolic links . . . . . . . . . . . . . . . 24
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
91 6.11 Canonicalizing the Server-Side Path Name . . . . . . . . . 25
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
92 6.11.1 Best practice for dealing with paths . . . . . . . . . . . 25
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
93 7. Responses from the Server to the Client . . . . . . . . . 26
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
94 8. Vendor-Specific Extensions . . . . . . . . . . . . . . . . 30
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
95 9. Security Considerations . . . . . . . . . . . . . . . . . 31
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
96 10. Changes from previous protocol versions . . . . . . . . . 32
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
97 10.1 Changes between versions 4 and 3 . . . . . . . . . . . . . 32
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
98 10.2 Changes between versions 3 and 2 . . . . . . . . . . . . . 33
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
99 10.3 Changes between versions 2 and 1 . . . . . . . . . . . . . 33
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
100 10.4 Changes between versions 1 and 0 . . . . . . . . . . . . . 33
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
101 11. Trademark Issues . . . . . . . . . . . . . . . . . . . . . 34
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
102 References . . . . . . . . . . . . . . . . . . . . . . . . 35
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
103 Authors' Addresses . . . . . . . . . . . . . . . . . . . . 35
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
104 Intellectual Property and Copyright Statements . . . . . . 37
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
105
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
106
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
107
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
108
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
109
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
110
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
111
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
112 Galbraith, et al. Expires June 18, 2003 [Page 2]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
113
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
114 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
115
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
116
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
117 1. Introduction
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
118
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
119 This protocol provides secure file transfer (and more generally file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
120 system access) functionality over a reliable data stream, such as a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
121 channel in the SSH2 protocol [5].
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
122
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
123 This protocol is designed so that it could be used to implement a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
124 secure remote file system service, as well as a secure file transfer
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
125 service.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
126
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
127 This protocol assumes that it runs over a secure channel, and that
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
128 the server has already authenticated the user at the client end, and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
129 that the identity of the client user is externally available to the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
130 server implementation.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
131
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
132 In general, this protocol follows a simple request-response model.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
133 Each request and response contains a sequence number and multiple
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
134 requests may be pending simultaneously. There are a relatively large
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
135 number of different request messages, but a small number of possible
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
136 response messages. Each request has one or more response messages
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
137 that may be returned in result (e.g., a read either returns data or
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
138 reports error status).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
139
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
140 The packet format descriptions in this specification follow the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
141 notation presented in the secsh architecture draft. [5]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
142
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
143 Even though this protocol is described in the context of the SSH2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
144 protocol, this protocol is general and independent of the rest of the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
145 SSH2 protocol suite. It could be used in a number of different
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
146 applications, such as secure file transfer over TLS RFC 2246 [1] and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
147 transfer of management information in VPN applications.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
148
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
149
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
150
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
151
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
152
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
153
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
154
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
155
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
156
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
157
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
158
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
159
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
160
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
161
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
162
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
163
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
164
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
165
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
166
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
167
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
168 Galbraith, et al. Expires June 18, 2003 [Page 3]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
169
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
170 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
171
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
172
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
173 2. Use with the SSH Connection Protocol
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
174
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
175 When used with the SSH2 Protocol suite, this protocol is intended to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
176 be used from the SSH Connection Protocol [7] as a subsystem, as
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
177 described in section ``Starting a Shell or a Command''. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
178 subsystem name used with this protocol is "sftp".
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
179
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
180
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
181
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
182
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
183
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
184
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
185
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
186
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
187
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
188
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
189
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
190
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
191
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
192
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
193
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
194
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
195
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
196
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
197
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
198
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
199
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
200
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
201
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
202
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
203
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
204
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
205
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
206
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
207
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
208
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
209
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
210
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
211
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
212
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
213
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
214
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
215
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
216
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
217
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
218
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
219
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
220
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
221
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
222
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
223
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
224 Galbraith, et al. Expires June 18, 2003 [Page 4]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
225
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
226 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
227
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
228
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
229 3. General Packet Format
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
230
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
231 All packets transmitted over the secure connection are of the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
232 following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
233
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
234 uint32 length
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
235 byte type
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
236 byte[length - 1] data payload
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
237
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
238 That is, they are just data preceded by 32-bit length and 8-bit type
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
239 fields. The `length' is the length of the data area, and does not
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
240 include the `length' field itself. The format and interpretation of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
241 the data area depends on the packet type.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
242
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
243 All packet descriptions below only specify the packet type and the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
244 data that goes into the data field. Thus, they should be prefixed by
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
245 the `length' and `type' fields.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
246
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
247 The maximum size of a packet is in practice determined by the client
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
248 (the maximum size of read or write requests that it sends, plus a few
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
249 bytes of packet overhead). All servers SHOULD support packets of at
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
250 least 34000 bytes (where the packet size refers to the full length,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
251 including the header above). This should allow for reads and writes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
252 of at most 32768 bytes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
253
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
254 There is no limit on the number of outstanding (non-acknowledged)
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
255 requests that the client may send to the server. In practice this is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
256 limited by the buffering available on the data stream and the queuing
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
257 performed by the server. If the server's queues are full, it should
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
258 not read any more data from the stream, and flow control will prevent
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
259 the client from sending more requests. Note, however, that while
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
260 there is no restriction on the protocol level, the client's API may
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
261 provide a limit in order to prevent infinite queuing of outgoing
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
262 requests at the client.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
263
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
264 The following values are defined for packet types.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
265
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
266
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
267
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
268
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
269
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
270
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
271
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
272
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
273
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
274
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
275
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
276
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
277
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
278
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
279
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
280 Galbraith, et al. Expires June 18, 2003 [Page 5]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
281
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
282 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
283
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
284
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
285 #define SSH_FXP_INIT 1
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
286 #define SSH_FXP_VERSION 2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
287 #define SSH_FXP_OPEN 3
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
288 #define SSH_FXP_CLOSE 4
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
289 #define SSH_FXP_READ 5
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
290 #define SSH_FXP_WRITE 6
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
291 #define SSH_FXP_LSTAT 7
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
292 #define SSH_FXP_FSTAT 8
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
293 #define SSH_FXP_SETSTAT 9
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
294 #define SSH_FXP_FSETSTAT 10
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
295 #define SSH_FXP_OPENDIR 11
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
296 #define SSH_FXP_READDIR 12
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
297 #define SSH_FXP_REMOVE 13
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
298 #define SSH_FXP_MKDIR 14
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
299 #define SSH_FXP_RMDIR 15
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
300 #define SSH_FXP_REALPATH 16
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
301 #define SSH_FXP_STAT 17
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
302 #define SSH_FXP_RENAME 18
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
303 #define SSH_FXP_READLINK 19
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
304 #define SSH_FXP_SYMLINK 20
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
305
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
306 #define SSH_FXP_STATUS 101
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
307 #define SSH_FXP_HANDLE 102
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
308 #define SSH_FXP_DATA 103
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
309 #define SSH_FXP_NAME 104
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
310 #define SSH_FXP_ATTRS 105
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
311
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
312 #define SSH_FXP_EXTENDED 200
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
313 #define SSH_FXP_EXTENDED_REPLY 201
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
314
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
315 RESERVED_FOR_EXTENSIONS 210-255
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
316
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
317 Additional packet types should only be defined if the protocol
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
318 version number (see Section ``Protocol Initialization'') is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
319 incremented, and their use MUST be negotiated using the version
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
320 number. However, the SSH_FXP_EXTENDED and SSH_FXP_EXTENDED_REPLY
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
321 packets can be used to implement vendor-specific extensions. See
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
322 Section ``Vendor-Specific-Extensions'' for more details.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
323
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
324 3.1 The use of stderr in the server
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
325
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
326 Packets are sent and received on stdout and stdin. Data sent on
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
327 stderr by the server SHOULD be considered debug or supplemental error
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
328 information, and MAY be displayed to the user.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
329
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
330 For example, during initialization, there is no client request
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
331 active, so errors or warning information cannot be sent to the client
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
332 as part of the SFTP protocol at this early stage. However, the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
333
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
334
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
335
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
336 Galbraith, et al. Expires June 18, 2003 [Page 6]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
337
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
338 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
339
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
340
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
341 errors or warnings MAY be sent as stderr text.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
342
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
343
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
344
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
345
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
346
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
347
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
348
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
349
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
350
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
351
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
352
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
353
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
354
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
355
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
356
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
357
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
358
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
359
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
360
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
361
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
362
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
363
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
364
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
365
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
366
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
367
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
368
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
369
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
370
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
371
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
372
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
373
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
374
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
375
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
376
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
377
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
378
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
379
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
380
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
381
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
382
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
383
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
384
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
385
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
386
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
387
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
388
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
389
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
390
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
391
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
392 Galbraith, et al. Expires June 18, 2003 [Page 7]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
393
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
394 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
395
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
396
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
397 4. Protocol Initialization
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
398
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
399 When the file transfer protocol starts, the client first sends a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
400 SSH_FXP_INIT (including its version number) packet to the server.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
401 The server responds with a SSH_FXP_VERSION packet, supplying the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
402 lowest of its own and the client's version number. Both parties
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
403 should from then on adhere to particular version of the protocol.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
404
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
405 The version number of the protocol specified in this document is 4.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
406 The version number should be incremented for each incompatible
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
407 revision of this protocol.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
408
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
409 4.1 Client Initialization
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
410
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
411 The SSH_FXP_INIT packet (from client to server) has the following
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
412 data:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
413
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
414 uint32 version
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
415
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
416 Version 3 of this protocol allowed clients to include extensions in
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
417 the SSH_FXP_INIT packet; however, this can cause interoperability
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
418 problems with version 1 and version 2 servers because the client must
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
419 send this packet before knowing the servers version.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
420
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
421 In this version of the protocol, clients MUST use the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
422 SSH_FXP_EXTENDED packet to send extensions to the server after
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
423 version exchange has completed. Clients MUST NOT include extensions
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
424 in the version packet. This will prevent interoperability problems
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
425 with older servers
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
426
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
427 4.2 Server Initialization
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
428
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
429 The SSH_FXP_VERSION packet (from server to client) has the following
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
430 data:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
431
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
432 uint32 version
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
433 <extension data>
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
434
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
435 'version' is the lower of the protocol version supported by the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
436 server and the version number received from the client.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
437
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
438 The extension data may be empty, or may be a sequence of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
439
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
440 string extension_name
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
441 string extension_data
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
442
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
443 pairs (both strings MUST always be present if one is, but the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
444 `extension_data' string may be of zero length). If present, these
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
445
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
446
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
447
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
448 Galbraith, et al. Expires June 18, 2003 [Page 8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
449
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
450 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
451
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
452
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
453 strings indicate extensions to the baseline protocol. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
454 `extension_name' field(s) identify the name of the extension. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
455 name should be of the form "name@domain", where the domain is the DNS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
456 domain name of the organization defining the extension. Additional
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
457 names that are not of this format may be defined later by the IETF.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
458 Implementations MUST silently ignore any extensions whose name they
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
459 do not recognize.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
460
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
461 4.3 Determining Server Newline Convention
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
462
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
463 In order to correctly process text files in a cross platform
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
464 compatible way, the newline convention must be converted from that of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
465 the server to that of the client, or, during an upload, from that of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
466 the client to that of the server.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
467
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
468 Versions 3 and prior of this protocol made no provisions for
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
469 processing text files. Many clients implemented some sort of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
470 conversion algorithm, but without either a 'canonical' on the wire
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
471 format or knowledge of the servers newline convention, correct
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
472 conversion was not always possible.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
473
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
474 Starting with Version 4, the SSH_FXF_TEXT file open flag (Section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
475 6.3) makes it possible to request that the server translate a file to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
476 a 'canonical' on the wire format. This format uses \r\n as the line
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
477 separator.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
478
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
479 Servers for systems using multiple newline characters (for example,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
480 Mac OS X or VMS) or systems using counted records, MUST translate to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
481 the canonical form.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
482
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
483 However, to ease the burden of implementation on servers that use a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
484 single, simple separator sequence, the following extension allows the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
485 canonical format to be changed.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
486
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
487 string "newline"
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
488 string new-canonical-separator (usually "\r" or "\n" or "\r\n")
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
489
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
490 All clients MUST support this extension.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
491
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
492 When processing text files, clients SHOULD NOT translate any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
493 character or sequence that is not an exact match of the servers
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
494 newline separator.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
495
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
496 In particular, if the newline sequence being used is the canonical
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
497 "\r\n" sequence, a lone \r or a lone \n SHOULD be written through
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
498 without change.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
499
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
500
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
501
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
502
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
503
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
504 Galbraith, et al. Expires June 18, 2003 [Page 9]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
505
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
506 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
507
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
508
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
509 5. File Attributes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
510
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
511 A new compound data type is defined for encoding file attributes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
512 The same encoding is used both when returning file attributes from
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
513 the server and when sending file attributes to the server. When
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
514 sending it to the server, the flags field specifies which attributes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
515 are included, and the server will use default values for the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
516 remaining attributes (or will not modify the values of remaining
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
517 attributes). When receiving attributes from the server, the flags
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
518 specify which attributes are included in the returned data. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
519 server normally returns all attributes it knows about.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
520
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
521 uint32 flags
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
522 byte type always present
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
523 uint64 size present only if flag SIZE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
524 string owner present only if flag OWNERGROUP
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
525 string group present only if flag OWNERGROUP
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
526 uint32 permissions present only if flag PERMISSIONS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
527 uint64 atime present only if flag ACCESSTIME
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
528 uint32 atime_nseconds present only if flag SUBSECOND_TIMES
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
529 uint64 createtime present only if flag CREATETIME
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
530 uint32 createtime_nseconds present only if flag SUBSECOND_TIMES
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
531 uint64 mtime present only if flag MODIFYTIME
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
532 uint32 mtime_nseconds present only if flag SUBSECOND_TIMES
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
533 string acl present only if flag ACL
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
534 uint32 extended_count present only if flag EXTENDED
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
535 string extended_type
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
536 string extended_data
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
537 ... more extended data (extended_type - extended_data pairs),
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
538 so that number of pairs equals extended_count
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
539
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
540
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
541 5.1 Flags
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
542
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
543 The `flags' specify which of the fields are present. Those fields
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
544 for which the corresponding flag is not set are not present (not
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
545 included in the packet). New flags can only be added by incrementing
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
546 the protocol version number (or by using the extension mechanism
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
547 described below).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
548
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
549 The flags bits are defined to have the following values:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
550
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
551
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
552
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
553
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
554
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
555
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
556
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
557
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
558
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
559
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
560 Galbraith, et al. Expires June 18, 2003 [Page 10]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
561
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
562 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
563
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
564
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
565 #define SSH_FILEXFER_ATTR_SIZE 0x00000001
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
566 #define SSH_FILEXFER_ATTR_PERMISSIONS 0x00000040
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
567 #define SSH_FILEXFER_ATTR_ACCESSTIME 0x00000008
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
568 #define SSH_FILEXFER_ATTR_CREATETIME 0x00000010
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
569 #define SSH_FILEXFER_ATTR_MODIFYTIME 0x00000020
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
570 #define SSH_FILEXFER_ATTR_ACL 0x00000040
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
571 #define SSH_FILEXFER_ATTR_OWNERGROUP 0x00000080
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
572 #define SSH_FILEXFER_ATTR_SUBSECOND_TIMES 0x00000100
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
573 #define SSH_FILEXFER_ATTR_EXTENDED 0x80000000
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
574
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
575 In previous versions of this protocol flags value 0x00000002 was
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
576 SSH_FILEXFER_ATTR_UIDGID. This value is now unused, and OWNERGROUP
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
577 was given a new value in order to ease implementation burden.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
578 0x00000002 MUST NOT appear in the mask. Some future version of this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
579 protocol may reuse flag 0x00000002.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
580
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
581 5.2 Type
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
582
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
583 The type field is always present. The following types are defined:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
584
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
585 #define SSH_FILEXFER_TYPE_REGULAR 1
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
586 #define SSH_FILEXFER_TYPE_DIRECTORY 2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
587 #define SSH_FILEXFER_TYPE_SYMLINK 3
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
588 #define SSH_FILEXFER_TYPE_SPECIAL 4
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
589 #define SSH_FILEXFER_TYPE_UNKNOWN 5
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
590
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
591 On a POSIX system, these values would be derived from the permission
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
592 field.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
593
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
594 5.3 Size
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
595
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
596 The `size' field specifies the size of the file on disk, in bytes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
597 If it is present during file creation, it should be considered a hint
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
598 as to the files eventual size.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
599
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
600 Files opened with the SSH_FXF_TEXT flag may have a size that is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
601 greater or less than the value of the size field.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
602
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
603 5.4 Owner and Group
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
604
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
605 The `owner' and `group' fields are represented as UTF-8 strings; this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
606 is the form used by NFS v4. See NFS version 4 Protocol. [3] The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
607 following text is selected quotations from section 5.6.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
608
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
609 To avoid a representation that is tied to a particular underlying
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
610 implementation at the client or server, the use of UTF-8 strings has
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
611 been chosen. The string should be of the form user@dns_domain".
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
612 This will allow for a client and server that do not use the same
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
613
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
614
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
615
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
616 Galbraith, et al. Expires June 18, 2003 [Page 11]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
617
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
618 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
619
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
620
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
621 local representation the ability to translate to a common syntax that
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
622 can be interpreted by both. In the case where there is no
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
623 translation available to the client or server, the attribute value
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
624 must be constructed without the "@". Therefore, the absence of the @
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
625 from the owner or owner_group attribute signifies that no translation
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
626 was available and the receiver of the attribute should not place any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
627 special meaning with the attribute value. Even though the attribute
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
628 value can not be translated, it may still be useful. In the case of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
629 a client, the attribute string may be used for local display of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
630 ownership.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
631
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
632 5.5 Permissions
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
633
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
634 The `permissions' field contains a bit mask of file permissions as
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
635 defined by POSIX [1].
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
636
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
637 5.6 Times
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
638
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
639 The 'atime', 'createtime', and 'mtime' contain the access, creation,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
640 and modification times of the files, respectively. They are
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
641 represented as seconds from Jan 1, 1970 in UTC.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
642
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
643 A negative value indicates number of seconds before Jan 1, 1970. In
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
644 both cases, if the SSH_FILEXFER_ATTR_SUBSECOND_TIMES flag is set, the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
645 nseconds field is to be added to the seconds field for the final time
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
646 representation. For example, if the time to be represented is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
647 one-half second before 0 hour January 1, 1970, the seconds field
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
648 would have a value of negative one (-1) and the nseconds fields would
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
649 have a value of one-half second (500000000). Values greater than
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
650 999,999,999 for nseconds are considered invalid.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
651
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
652 5.7 ACL
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
653
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
654 The 'ACL' field contains an ACL similar to that defined in section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
655 5.9 of NFS version 4 Protocol [3].
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
656
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
657 uint32 ace-count
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
658
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
659 repeated ace-count time:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
660 uint32 ace-type
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
661 uint32 ace-flag
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
662 uint32 ace-mask
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
663 string who [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
664
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
665 ace-type is one of the following four values (taken from NFS Version
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
666 4 Protocol [3]:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
667
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
668
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
669
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
670
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
671
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
672 Galbraith, et al. Expires June 18, 2003 [Page 12]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
673
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
674 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
675
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
676
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
677 const ACE4_ACCESS_ALLOWED_ACE_TYPE = 0x00000000;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
678 const ACE4_ACCESS_DENIED_ACE_TYPE = 0x00000001;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
679 const ACE4_SYSTEM_AUDIT_ACE_TYPE = 0x00000002;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
680 const ACE4_SYSTEM_ALARM_ACE_TYPE = 0x00000003;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
681
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
682 ace-flag is a combination of the following flag values. See NFS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
683 Version 4 Protocol [3] section 5.9.2:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
684
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
685 const ACE4_FILE_INHERIT_ACE = 0x00000001;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
686 const ACE4_DIRECTORY_INHERIT_ACE = 0x00000002;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
687 const ACE4_NO_PROPAGATE_INHERIT_ACE = 0x00000004;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
688 const ACE4_INHERIT_ONLY_ACE = 0x00000008;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
689 const ACE4_SUCCESSFUL_ACCESS_ACE_FLAG = 0x00000010;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
690 const ACE4_FAILED_ACCESS_ACE_FLAG = 0x00000020;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
691 const ACE4_IDENTIFIER_GROUP = 0x00000040;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
692
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
693 ace-mask is any combination of the following flags (taken from NFS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
694 Version 4 Protocol [3] section 5.9.3:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
695
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
696 const ACE4_READ_DATA = 0x00000001;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
697 const ACE4_LIST_DIRECTORY = 0x00000001;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
698 const ACE4_WRITE_DATA = 0x00000002;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
699 const ACE4_ADD_FILE = 0x00000002;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
700 const ACE4_APPEND_DATA = 0x00000004;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
701 const ACE4_ADD_SUBDIRECTORY = 0x00000004;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
702 const ACE4_READ_NAMED_ATTRS = 0x00000008;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
703 const ACE4_WRITE_NAMED_ATTRS = 0x00000010;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
704 const ACE4_EXECUTE = 0x00000020;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
705 const ACE4_DELETE_CHILD = 0x00000040;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
706 const ACE4_READ_ATTRIBUTES = 0x00000080;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
707 const ACE4_WRITE_ATTRIBUTES = 0x00000100;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
708 const ACE4_DELETE = 0x00010000;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
709 const ACE4_READ_ACL = 0x00020000;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
710 const ACE4_WRITE_ACL = 0x00040000;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
711 const ACE4_WRITE_OWNER = 0x00080000;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
712 const ACE4_SYNCHRONIZE = 0x00100000;
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
713
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
714 who is a UTF-8 string of the form described in 'Owner and Group'
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
715 (Section 5.4)
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
716
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
717 Also, as per '5.9.4 ACE who' [3] there are several identifiers that
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
718 need to be understood universally. Some of these identifiers cannot
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
719 be understood when an client access the server, but have meaning when
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
720 a local process accesses the file. The ability to display and modify
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
721 these permissions is permitted over SFTP.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
722
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
723 OWNER The owner of the file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
724
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
725
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
726
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
727
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
728 Galbraith, et al. Expires June 18, 2003 [Page 13]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
729
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
730 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
731
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
732
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
733 GROUP The group associated with the file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
734
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
735 EVERYONE The world.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
736
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
737 INTERACTIVE Accessed from an interactive terminal.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
738
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
739 NETWORK Accessed via the network.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
740
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
741 DIALUP Accessed as a dialup user to the server.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
742
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
743 BATCH Accessed from a batch job.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
744
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
745 ANONYMOUS Accessed without any authentication.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
746
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
747 AUTHENTICATED Any authenticated user (opposite of ANONYMOUS).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
748
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
749 SERVICE Access from a system service.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
750
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
751 To avoid conflict, these special identifiers are distinguish by an
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
752 appended "@" and should appear in the form "xxxx@" (note: no domain
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
753 name after the "@"). For example: ANONYMOUS@.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
754
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
755 5.8 Extended attributes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
756
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
757 The SSH_FILEXFER_ATTR_EXTENDED flag provides a general extension
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
758 mechanism for vendor-specific extensions. If the flag is specified,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
759 then the `extended_count' field is present. It specifies the number
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
760 of extended_type-extended_data pairs that follow. Each of these
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
761 pairs specifies an extended attribute. For each of the attributes,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
762 the extended_type field should be a string of the format
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
763 "name@domain", where "domain" is a valid, registered domain name and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
764 "name" identifies the method. The IETF may later standardize certain
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
765 names that deviate from this format (e.g., that do not contain the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
766 "@" sign). The interpretation of `extended_data' depends on the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
767 type. Implementations SHOULD ignore extended data fields that they
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
768 do not understand.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
769
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
770 Additional fields can be added to the attributes by either defining
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
771 additional bits to the flags field to indicate their presence, or by
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
772 defining extended attributes for them. The extended attributes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
773 mechanism is recommended for most purposes; additional flags bits
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
774 should only be defined by an IETF standards action that also
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
775 increments the protocol version number. The use of such new fields
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
776 MUST be negotiated by the version number in the protocol exchange.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
777 It is a protocol error if a packet with unsupported protocol bits is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
778 received.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
779
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
780
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
781
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
782
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
783
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
784 Galbraith, et al. Expires June 18, 2003 [Page 14]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
785
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
786 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
787
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
788
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
789 6. Requests From the Client to the Server
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
790
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
791 Requests from the client to the server represent the various file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
792 system operations. Each request begins with an `id' field, which is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
793 a 32-bit identifier identifying the request (selected by the client).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
794 The same identifier will be returned in the response to the request.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
795 One possible implementation is a monotonically increasing request
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
796 sequence number (modulo 2^32).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
797
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
798 Many operations in the protocol operate on open files. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
799 SSH_FXP_OPEN request can return a file handle (which is an opaque
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
800 variable-length string) which may be used to access the file later
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
801 (e.g. in a read operation). The client MUST NOT send requests the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
802 server with bogus or closed handles. However, the server MUST
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
803 perform adequate checks on the handle in order to avoid security
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
804 risks due to fabricated handles.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
805
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
806 This design allows either stateful and stateless server
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
807 implementation, as well as an implementation which caches state
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
808 between requests but may also flush it. The contents of the file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
809 handle string are entirely up to the server and its design. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
810 client should not modify or attempt to interpret the file handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
811 strings.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
812
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
813 The file handle strings MUST NOT be longer than 256 bytes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
814
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
815 6.1 Request Synchronization and Reordering
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
816
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
817 The protocol and implementations MUST process requests relating to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
818 the same file in the order in which they are received. In other
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
819 words, if an application submits multiple requests to the server, the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
820 results in the responses will be the same as if it had sent the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
821 requests one at a time and waited for the response in each case. For
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
822 example, the server may process non-overlapping read/write requests
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
823 to the same file in parallel, but overlapping reads and writes cannot
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
824 be reordered or parallelized. However, there are no ordering
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
825 restrictions on the server for processing requests from two different
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
826 file transfer connections. The server may interleave and parallelize
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
827 them at will.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
828
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
829 There are no restrictions on the order in which responses to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
830 outstanding requests are delivered to the client, except that the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
831 server must ensure fairness in the sense that processing of no
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
832 request will be indefinitely delayed even if the client is sending
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
833 other requests so that there are multiple outstanding requests all
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
834 the time.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
835
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
836
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
837
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
838
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
839
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
840 Galbraith, et al. Expires June 18, 2003 [Page 15]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
841
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
842 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
843
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
844
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
845 6.2 File Names
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
846
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
847 This protocol represents file names as strings. File names are
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
848 assumed to use the slash ('/') character as a directory separator.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
849
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
850 File names starting with a slash are "absolute", and are relative to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
851 the root of the file system. Names starting with any other character
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
852 are relative to the user's default directory (home directory). Note
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
853 that identifying the user is assumed to take place outside of this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
854 protocol.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
855
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
856 Servers SHOULD interpret a path name component ".." as referring to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
857 the parent directory, and "." as referring to the current directory.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
858 If the server implementation limits access to certain parts of the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
859 file system, it must be extra careful in parsing file names when
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
860 enforcing such restrictions. There have been numerous reported
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
861 security bugs where a ".." in a path name has allowed access outside
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
862 the intended area.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
863
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
864 An empty path name is valid, and it refers to the user's default
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
865 directory (usually the user's home directory).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
866
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
867 Otherwise, no syntax is defined for file names by this specification.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
868 Clients should not make any other assumptions; however, they can
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
869 splice path name components returned by SSH_FXP_READDIR together
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
870 using a slash ('/') as the separator, and that will work as expected.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
871
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
872 In order to comply with IETF Policy on Character Sets and Languages
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
873 [2], all filenames are to be encoded in UTF-8. The shortest valid
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
874 UTF-8 encoding of the UNICODE data MUST be used. The server is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
875 responsible for converting the UNICODE data to whatever canonical
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
876 form it requires.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
877
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
878 For example, if the server requires that precomposed characters
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
879 always be used, the server MUST NOT assume the filename as sent by
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
880 the client has this attribute, but must do this normalization itself.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
881
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
882 It is understood that the lack of well-defined semantics for file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
883 names may cause interoperability problems between clients and servers
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
884 using radically different operating systems. However, this approach
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
885 is known to work acceptably with most systems, and alternative
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
886 approaches that e.g. treat file names as sequences of structured
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
887 components are quite complicated.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
888
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
889 6.3 Opening, Creating, and Closing Files
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
890
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
891 Files are opened and created using the SSH_FXP_OPEN message, whose
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
892 data part is as follows:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
893
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
894
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
895
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
896 Galbraith, et al. Expires June 18, 2003 [Page 16]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
897
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
898 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
899
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
900
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
901 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
902 string filename [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
903 uint32 pflags
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
904 ATTRS attrs
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
905
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
906 The `id' field is the request identifier as for all requests.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
907
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
908 The `filename' field specifies the file name. See Section ``File
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
909 Names'' for more information.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
910
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
911 The `pflags' field is a bitmask. The following bits have been
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
912 defined.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
913
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
914 #define SSH_FXF_READ 0x00000001
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
915 #define SSH_FXF_WRITE 0x00000002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
916 #define SSH_FXF_APPEND 0x00000004
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
917 #define SSH_FXF_CREAT 0x00000008
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
918 #define SSH_FXF_TRUNC 0x00000010
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
919 #define SSH_FXF_EXCL 0x00000020
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
920 #define SSH_FXF_TEXT 0x00000040
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
921
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
922 These have the following meanings:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
923
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
924 SSH_FXF_READ
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
925 Open the file for reading.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
926
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
927 SSH_FXF_WRITE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
928 Open the file for writing. If both this and SSH_FXF_READ are
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
929 specified, the file is opened for both reading and writing.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
930
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
931 SSH_FXF_APPEND
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
932 Force all writes to append data at the end of the file. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
933 offset parameter to write will be ignored.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
934
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
935 SSH_FXF_CREAT
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
936 If this flag is specified, then a new file will be created if one
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
937 does not already exist (if O_TRUNC is specified, the new file will
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
938 be truncated to zero length if it previously exists).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
939
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
940 SSH_FXF_TRUNC
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
941 Forces an existing file with the same name to be truncated to zero
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
942 length when creating a file by specifying SSH_FXF_CREAT.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
943 SSH_FXF_CREAT MUST also be specified if this flag is used.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
944
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
945 SSH_FXF_EXCL
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
946 Causes the request to fail if the named file already exists.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
947 SSH_FXF_CREAT MUST also be specified if this flag is used.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
948
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
949
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
950
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
951
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
952 Galbraith, et al. Expires June 18, 2003 [Page 17]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
953
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
954 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
955
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
956
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
957 SSH_FXF_TEXT
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
958 Indicates that the server should treat the file as text and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
959 convert it to the canonical newline convention in use. (See
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
960 Determining Server Newline Convention. (Section 4.3)
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
961
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
962 When a file is opened with the FXF_TEXT flag, the offset field in
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
963 both the read and write function are ignored.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
964
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
965 Servers MUST correctly process multiple parallel reads and writes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
966 correctly in this mode. Naturally, it is permissible for them to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
967 do this by serializing the requests. It would not be possible for
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
968 a client to reliably detect a server that does not implement
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
969 parallel writes in time to prevent damage.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
970
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
971 Clients SHOULD use the SSH_FXF_APPEND flag to append data to a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
972 text file rather then using write with a calculated offset.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
973
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
974 To support seeks on text file the following SSH_FXP_EXTENDED
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
975 packet is defined.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
976
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
977
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
978
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
979 string "text-seek"
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
980 string file-handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
981 uint64 line-number
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
982
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
983 line-number is the index of the line number to seek to, where byte
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
984 0 in the file is line number 0, and the byte directly following
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
985 the first newline sequence in the file is line number 1 and so on.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
986
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
987 The response to a "text-seek" request is an SSH_FXP_STATUS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
988 message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
989
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
990 An attempt to seek past the end-of-file should result in a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
991 SSH_FX_EOF status.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
992
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
993 Servers SHOULD support at least one "text-seek" in order to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
994 support resume. However, a client MUST be prepared to receive
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
995 SSH_FX_OP_UNSUPPORTED when attempting a "text-seek" operation.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
996 The client can then try a fall-back strategy, if it has one.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
997
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
998 Clients MUST be prepared to handle SSH_FX_OP_UNSUPPORTED returned
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
999 for read or write operations that are not sequential.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1000
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1001 The `attrs' field specifies the initial attributes for the file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1002 Default values will be used for those attributes that are not
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1003 specified. See Section ``File Attributes'' for more information.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1004
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1005
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1006
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1007
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1008 Galbraith, et al. Expires June 18, 2003 [Page 18]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1009
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1010 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1011
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1012
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1013 The response to this message will be either SSH_FXP_HANDLE (if the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1014 operation is successful) or SSH_FXP_STATUS (if the operation fails).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1015
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1016 A file is closed by using the SSH_FXP_CLOSE request. Its data field
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1017 has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1018
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1019 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1020 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1021
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1022 where `id' is the request identifier, and `handle' is a handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1023 previously returned in the response to SSH_FXP_OPEN or
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1024 SSH_FXP_OPENDIR. The handle becomes invalid immediately after this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1025 request has been sent.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1026
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1027 The response to this request will be a SSH_FXP_STATUS message. One
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1028 should note that on some server platforms even a close can fail.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1029 This can happen e.g. if the server operating system caches writes,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1030 and an error occurs while flushing cached writes during the close.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1031
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1032 6.4 Reading and Writing
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1033
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1034 Once a file has been opened, it can be read using the following
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1035 message:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1036
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1037 byte SSH_FXP_READ
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1038 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1039 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1040 uint64 offset
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1041 uint32 len
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1042
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1043 where `id' is the request identifier, `handle' is an open file handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1044 returned by SSH_FXP_OPEN, `offset' is the offset (in bytes) relative
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1045 to the beginning of the file from where to start reading, and `len'
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1046 is the maximum number of bytes to read.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1047
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1048 In response to this request, the server will read as many bytes as it
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1049 can from the file (up to `len'), and return them in a SSH_FXP_DATA
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1050 message. If an error occurs or EOF is encountered before reading any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1051 data, the server will respond with SSH_FXP_STATUS.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1052
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1053 For normal disk files, it is normally guaranteed that this will read
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1054 the specified number of bytes, or up to end of file. However, if the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1055 read length is very long, the server may truncate it if it doesn't
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1056 support packets of that length. See General Packet Format (Section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1057 3).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1058
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1059 For e.g. device files this may return fewer bytes than requested.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1060
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1061
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1062
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1063
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1064 Galbraith, et al. Expires June 18, 2003 [Page 19]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1065
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1066 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1067
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1068
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1069 Writing to a file is achieved using the following message:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1070
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1071 byte SSH_FXP_WRITE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1072 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1073 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1074 uint64 offset
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1075 string data
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1076
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1077 where `id' is a request identifier, `handle' is a file handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1078 returned by SSH_FXP_OPEN, `offset' is the offset (in bytes) from the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1079 beginning of the file where to start writing, and `data' is the data
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1080 to be written.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1081
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1082 The write will extend the file if writing beyond the end of the file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1083 It is legal to write way beyond the end of the file; the semantics
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1084 are to write zeroes from the end of the file to the specified offset
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1085 and then the data. On most operating systems, such writes do not
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1086 allocate disk space but instead leave "holes" in the file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1087
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1088 The server responds to a write request with a SSH_FXP_STATUS message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1089
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1090 6.5 Removing and Renaming Files
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1091
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1092 Files can be removed using the SSH_FXP_REMOVE message. It has the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1093 following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1094
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1095 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1096 string filename [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1097
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1098 where `id' is the request identifier and `filename' is the name of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1099 the file to be removed. See Section ``File Names'' for more
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1100 information. This request cannot be used to remove directories.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1101
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1102 The server will respond to this request with a SSH_FXP_STATUS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1103 message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1104
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1105 Files (and directories) can be renamed using the SSH_FXP_RENAME
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1106 message. Its data is as follows:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1107
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1108 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1109 string oldpath [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1110 string newpath [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1111
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1112 where `id' is the request identifier, `oldpath' is the name of an
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1113 existing file or directory, and `newpath' is the new name for the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1114 file or directory. It is an error if there already exists a file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1115 with the name specified by newpath. The server may also fail rename
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1116 requests in other situations, for example if `oldpath' and `newpath'
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1117
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1118
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1119
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1120 Galbraith, et al. Expires June 18, 2003 [Page 20]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1121
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1122 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1123
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1124
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1125 point to different file systems on the server.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1126
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1127 The server will respond to this request with a SSH_FXP_STATUS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1128 message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1129
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1130 6.6 Creating and Deleting Directories
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1131
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1132 New directories can be created using the SSH_FXP_MKDIR request. It
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1133 has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1134
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1135 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1136 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1137 ATTRS attrs
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1138
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1139 where `id' is the request identifier.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1140
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1141 `path' specifies the directory to be created. See Section ``File
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1142 Names'' for more information on file names.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1143
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1144 `attrs' specifies the attributes that should be applied to it upon
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1145 creation. Attributes are discussed in more detail in Section ``File
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1146 Attributes''.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1147
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1148 The server will respond to this request with a SSH_FXP_STATUS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1149 message. If a file or directory with the specified path already
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1150 exists, an error will be returned.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1151
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1152 Directories can be removed using the SSH_FXP_RMDIR request, which has
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1153 the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1154
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1155 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1156 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1157
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1158 where `id' is the request identifier, and `path' specifies the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1159 directory to be removed. See Section ``File Names'' for more
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1160 information on file names.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1161
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1162 The server responds to this request with a SSH_FXP_STATUS message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1163 Errors may be returned from this operation for various reasons,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1164 including, but not limited to, the path does not exist, the path does
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1165 not refer to a directory object, the directory is not empty, or the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1166 user has insufficient access or permission to perform the requested
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1167 operation.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1168
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1169 6.7 Scanning Directories
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1170
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1171 The files in a directory can be listed using the SSH_FXP_OPENDIR and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1172 SSH_FXP_READDIR requests. Each SSH_FXP_READDIR request returns one
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1173
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1174
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1175
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1176 Galbraith, et al. Expires June 18, 2003 [Page 21]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1177
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1178 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1179
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1180
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1181 or more file names with full file attributes for each file. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1182 client should call SSH_FXP_READDIR repeatedly until it has found the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1183 file it is looking for or until the server responds with a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1184 SSH_FXP_STATUS message indicating an error (normally SSH_FX_EOF if
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1185 there are no more files in the directory). The client should then
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1186 close the handle using the SSH_FXP_CLOSE request.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1187
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1188 The SSH_FXP_OPENDIR opens a directory for reading. It has the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1189 following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1190
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1191 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1192 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1193
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1194 where `id' is the request identifier and `path' is the path name of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1195 the directory to be listed (without any trailing slash). See Section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1196 ``File Names'' for more information on file names. This will return
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1197 an error if the path does not specify a directory or if the directory
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1198 is not readable. The server will respond to this request with either
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1199 a SSH_FXP_HANDLE or a SSH_FXP_STATUS message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1200
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1201 Once the directory has been successfully opened, files (and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1202 directories) contained in it can be listed using SSH_FXP_READDIR
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1203 requests. These are of the format
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1204
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1205 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1206 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1207
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1208 where `id' is the request identifier, and `handle' is a handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1209 returned by SSH_FXP_OPENDIR. (It is a protocol error to attempt to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1210 use an ordinary file handle returned by SSH_FXP_OPEN.)
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1211
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1212 The server responds to this request with either a SSH_FXP_NAME or a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1213 SSH_FXP_STATUS message. One or more names may be returned at a time.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1214 Full status information is returned for each name in order to speed
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1215 up typical directory listings.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1216
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1217 If there are no more names available to be read, the server MUST
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1218 respond with a SSH_FXP_STATUS message with error code of SSH_FX_EOF.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1219
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1220 When the client no longer wishes to read more names from the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1221 directory, it SHOULD call SSH_FXP_CLOSE for the handle. The handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1222 should be closed regardless of whether an error has occurred or not.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1223
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1224 6.8 Retrieving File Attributes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1225
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1226 Very often, file attributes are automatically returned by
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1227 SSH_FXP_READDIR. However, sometimes there is need to specifically
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1228 retrieve the attributes for a named file. This can be done using the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1229
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1230
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1231
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1232 Galbraith, et al. Expires June 18, 2003 [Page 22]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1233
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1234 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1235
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1236
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1237 SSH_FXP_STAT, SSH_FXP_LSTAT and SSH_FXP_FSTAT requests.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1238
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1239 SSH_FXP_STAT and SSH_FXP_LSTAT only differ in that SSH_FXP_STAT
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1240 follows symbolic links on the server, whereas SSH_FXP_LSTAT does not
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1241 follow symbolic links. Both have the same format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1242
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1243 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1244 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1245 uint32 flags
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1246
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1247 where `id' is the request identifier, and `path' specifies the file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1248 system object for which status is to be returned. The server
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1249 responds to this request with either SSH_FXP_ATTRS or SSH_FXP_STATUS.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1250
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1251 The flags field specify the attribute flags in which the client has
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1252 particular interest. This is a hint to the server. For example,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1253 because retrieving owner / group and acl information can be an
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1254 expensive operation under some operating systems, the server may
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1255 choose not to retrieve this information unless the client expresses a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1256 specific interest in it.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1257
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1258 The client has no guarantee the server will provide all the fields
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1259 that it has expressed an interest in.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1260
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1261 SSH_FXP_FSTAT differs from the others in that it returns status
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1262 information for an open file (identified by the file handle). Its
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1263 format is as follows:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1264
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1265 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1266 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1267 uint32 flags
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1268
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1269 where `id' is the request identifier and `handle' is a file handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1270 returned by SSH_FXP_OPEN. The server responds to this request with
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1271 SSH_FXP_ATTRS or SSH_FXP_STATUS.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1272
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1273 6.9 Setting File Attributes
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1274
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1275 File attributes may be modified using the SSH_FXP_SETSTAT and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1276 SSH_FXP_FSETSTAT requests. These requests are used for operations
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1277 such as changing the ownership, permissions or access times, as well
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1278 as for truncating a file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1279
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1280 The SSH_FXP_SETSTAT request is of the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1281
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1282
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1283
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1284
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1285
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1286
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1287
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1288 Galbraith, et al. Expires June 18, 2003 [Page 23]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1289
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1290 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1291
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1292
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1293 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1294 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1295 ATTRS attrs
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1296
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1297 where `id' is the request identifier, `path' specifies the file
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1298 system object (e.g. file or directory) whose attributes are to be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1299 modified, and `attrs' specifies the modifications to be made to its
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1300 attributes. Attributes are discussed in more detail in Section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1301 ``File Attributes''.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1302
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1303 An error will be returned if the specified file system object does
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1304 not exist or the user does not have sufficient rights to modify the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1305 specified attributes. The server responds to this request with a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1306 SSH_FXP_STATUS message.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1307
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1308 The SSH_FXP_FSETSTAT request modifies the attributes of a file which
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1309 is already open. It has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1310
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1311 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1312 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1313 ATTRS attrs
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1314
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1315 where `id' is the request identifier, `handle' (MUST be returned by
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1316 SSH_FXP_OPEN) identifies the file whose attributes are to be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1317 modified, and `attrs' specifies the modifications to be made to its
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1318 attributes. Attributes are discussed in more detail in Section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1319 ``File Attributes''. The server will respond to this request with
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1320 SSH_FXP_STATUS.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1321
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1322 6.10 Dealing with Symbolic links
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1323
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1324 The SSH_FXP_READLINK request may be used to read the target of a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1325 symbolic link. It would have a data part as follows:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1326
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1327 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1328 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1329
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1330 where `id' is the request identifier and `path' specifies the path
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1331 name of the symlink to be read.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1332
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1333 The server will respond with a SSH_FXP_NAME packet containing only
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1334 one name and a dummy attributes value. The name in the returned
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1335 packet contains the target of the link. If an error occurs, the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1336 server may respond with SSH_FXP_STATUS.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1337
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1338 The SSH_FXP_SYMLINK request will create a symbolic link on the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1339 server. It is of the following format
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1340
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1341
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1342
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1343
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1344 Galbraith, et al. Expires June 18, 2003 [Page 24]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1345
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1346 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1347
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1348
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1349 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1350 string linkpath [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1351 string targetpath [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1352
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1353 where `id' is the request identifier, `linkpath' specifies the path
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1354 name of the symlink to be created and `targetpath' specifies the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1355 target of the symlink. The server shall respond with a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1356 SSH_FXP_STATUS indicating either success (SSH_FX_OK) or an error
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1357 condition.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1358
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1359 6.11 Canonicalizing the Server-Side Path Name
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1360
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1361 The SSH_FXP_REALPATH request can be used to have the server
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1362 canonicalize any given path name to an absolute path. This is useful
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1363 for converting path names containing ".." components or relative
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1364 pathnames without a leading slash into absolute paths. The format of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1365 the request is as follows:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1366
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1367 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1368 string path [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1369
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1370 where `id' is the request identifier and `path' specifies the path
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1371 name to be canonicalized. The server will respond with a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1372 SSH_FXP_NAME packet containing the name in canonical form and a dummy
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1373 attributes value. If an error occurs, the server may also respond
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1374 with SSH_FXP_STATUS.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1375
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1376 6.11.1 Best practice for dealing with paths
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1377
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1378 The client SHOULD treat the results of SSH_FXP_REALPATH as a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1379 canonical absolute path, even if the path does not appear to be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1380 absolute. A client that use REALPATH(".") and treats the result as
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1381 absolute, even if there is no leading slash, will continue to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1382 function correctly, even when talking to a Windows NT or VMS style
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1383 system, where absolute paths may not begin with a slash.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1384
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1385 For example, if the client wishes to change directory up, and the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1386 server has returned "c:/x/y/z" from REALPATH, the client SHOULD use
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1387 "c:/x/y/z/..".
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1388
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1389 As a second example, if the client wishes to open the file "x.txt" in
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1390 the current directory, and server has returned "dka100:/x/y/z" as the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1391 canonical path of the directory, the client SHOULD open "dka100:/x/y/
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1392 z/x.txt"
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1393
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1394
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1395
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1396
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1397
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1398
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1399
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1400 Galbraith, et al. Expires June 18, 2003 [Page 25]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1401
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1402 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1403
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1404
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1405 7. Responses from the Server to the Client
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1406
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1407 The server responds to the client using one of a few response
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1408 packets. All requests can return a SSH_FXP_STATUS response upon
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1409 failure. When the operation is successful, any of the responses may
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1410 be returned (depending on the operation). If no data needs to be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1411 returned to the client, the SSH_FXP_STATUS response with SSH_FX_OK
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1412 status is appropriate. Otherwise, the SSH_FXP_HANDLE message is used
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1413 to return a file handle (for SSH_FXP_OPEN and SSH_FXP_OPENDIR
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1414 requests), SSH_FXP_DATA is used to return data from SSH_FXP_READ,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1415 SSH_FXP_NAME is used to return one or more file names from a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1416 SSH_FXP_READDIR or SSH_FXP_REALPATH request, and SSH_FXP_ATTRS is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1417 used to return file attributes from SSH_FXP_STAT, SSH_FXP_LSTAT, and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1418 SSH_FXP_FSTAT requests.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1419
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1420 Exactly one response will be returned for each request. Each
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1421 response packet contains a request identifier which can be used to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1422 match each response with the corresponding request. Note that it is
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1423 legal to have several requests outstanding simultaneously, and the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1424 server is allowed to send responses to them in a different order from
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1425 the order in which the requests were sent (the result of their
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1426 execution, however, is guaranteed to be as if they had been processed
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1427 one at a time in the order in which the requests were sent).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1428
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1429 Response packets are of the same general format as request packets.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1430 Each response packet begins with the request identifier.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1431
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1432 The format of the data portion of the SSH_FXP_STATUS response is as
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1433 follows:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1434
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1435 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1436 uint32 error/status code
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1437 string error message (ISO-10646 UTF-8 [RFC-2279])
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1438 string language tag (as defined in [RFC-1766])
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1439
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1440 where `id' is the request identifier, and `error/status code'
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1441 indicates the result of the requested operation. The value SSH_FX_OK
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1442 indicates success, and all other values indicate failure.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1443
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1444 Currently, the following values are defined (other values may be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1445 defined by future versions of this protocol):
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1446
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1447
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1448
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1449
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1450
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1451
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1452
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1453
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1454
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1455
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1456 Galbraith, et al. Expires June 18, 2003 [Page 26]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1457
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1458 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1459
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1460
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1461 #define SSH_FX_OK 0
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1462 #define SSH_FX_EOF 1
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1463 #define SSH_FX_NO_SUCH_FILE 2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1464 #define SSH_FX_PERMISSION_DENIED 3
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1465 #define SSH_FX_FAILURE 4
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1466 #define SSH_FX_BAD_MESSAGE 5
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1467 #define SSH_FX_NO_CONNECTION 6
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1468 #define SSH_FX_CONNECTION_LOST 7
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1469 #define SSH_FX_OP_UNSUPPORTED 8
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1470 #define SSH_FX_INVALID_HANDLE 9
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1471 #define SSH_FX_NO_SUCH_PATH 10
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1472 #define SSH_FX_FILE_ALREADY_EXISTS 11
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1473 #define SSH_FX_WRITE_PROTECT 12
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1474 #define SSH_FX_NO_MEDIA 13
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1475
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1476 SSH_FX_OK
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1477 Indicates successful completion of the operation.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1478
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1479 SSH_FX_EOF
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1480 indicates end-of-file condition; for SSH_FX_READ it means that no
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1481 more data is available in the file, and for SSH_FX_READDIR it
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1482 indicates that no more files are contained in the directory.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1483
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1484 SSH_FX_NO_SUCH_FILE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1485 is returned when a reference is made to a file which does not
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1486 exist.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1487
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1488 SSH_FX_PERMISSION_DENIED
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1489 is returned when the authenticated user does not have sufficient
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1490 permissions to perform the operation.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1491
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1492 SSH_FX_FAILURE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1493 is a generic catch-all error message; it should be returned if an
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1494 error occurs for which there is no more specific error code
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1495 defined.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1496
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1497 SSH_FX_BAD_MESSAGE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1498 may be returned if a badly formatted packet or protocol
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1499 incompatibility is detected.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1500
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1501 SSH_FX_NO_CONNECTION
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1502 is a pseudo-error which indicates that the client has no
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1503 connection to the server (it can only be generated locally by the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1504 client, and MUST NOT be returned by servers).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1505
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1506 SSH_FX_CONNECTION_LOST
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1507 is a pseudo-error which indicates that the connection to the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1508 server has been lost (it can only be generated locally by the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1509
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1510
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1511
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1512 Galbraith, et al. Expires June 18, 2003 [Page 27]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1513
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1514 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1515
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1516
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1517 client, and MUST NOT be returned by servers).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1518
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1519 SSH_FX_OP_UNSUPPORTED
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1520 indicates that an attempt was made to perform an operation which
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1521 is not supported for the server (it may be generated locally by
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1522 the client if e.g. the version number exchange indicates that a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1523 required feature is not supported by the server, or it may be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1524 returned by the server if the server does not implement an
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1525 operation).
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1526
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1527 SSH_FX_INVALID_HANDLE
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1528 The handle value was invalid.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1529
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1530 SSH_FX_NO_SUCH_PATH
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1531 The file path does not exist or is invalid.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1532
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1533 SSH_FX_FILE_ALREADY_EXISTS
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1534 The file already exists.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1535
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1536 SSH_FX_WRITE_PROTECT
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1537 The file is on read only media, or the media is write protected.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1538
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1539 SSH_FX_NO_MEDIA
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1540 The requested operation can not be completed because there is no
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1541 media available in the drive.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1542
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1543 The SSH_FXP_HANDLE response has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1544
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1545 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1546 string handle
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1547
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1548 where `id' is the request identifier, and `handle' is an arbitrary
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1549 string that identifies an open file or directory on the server. The
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1550 handle is opaque to the client; the client MUST NOT attempt to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1551 interpret or modify it in any way. The length of the handle string
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1552 MUST NOT exceed 256 data bytes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1553
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1554 The SSH_FXP_DATA response has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1555
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1556 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1557 string data
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1558
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1559 where `id' is the request identifier, and `data' is an arbitrary byte
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1560 string containing the requested data. The data string may be at most
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1561 the number of bytes requested in a SSH_FXP_READ request, but may also
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1562 be shorter if end of file is reached or if the read is from something
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1563 other than a regular file.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1564
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1565
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1566
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1567
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1568 Galbraith, et al. Expires June 18, 2003 [Page 28]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1569
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1570 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1571
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1572
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1573 The SSH_FXP_NAME response has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1574
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1575 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1576 uint32 count
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1577 repeats count times:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1578 string filename [UTF-8]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1579 ATTRS attrs
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1580
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1581 where `id' is the request identifier, `count' is the number of names
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1582 returned in this response, and the remaining fields repeat `count'
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1583 times (so that all three fields are first included for the first
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1584 file, then for the second file, etc). In the repeated part,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1585 `filename' is a file name being returned (for SSH_FXP_READDIR, it
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1586 will be a relative name within the directory, without any path
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1587 components; for SSH_FXP_REALPATH it will be an absolute path name),
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1588 and `attrs' is the attributes of the file as described in Section
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1589 ``File Attributes''.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1590
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1591 The SSH_FXP_ATTRS response has the following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1592
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1593 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1594 ATTRS attrs
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1595
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1596 where `id' is the request identifier, and `attrs' is the returned
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1597 file attributes as described in Section ``File Attributes''.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1598
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1599
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1600
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1601
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1602
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1603
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1604
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1605
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1606
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1607
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1608
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1609
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1610
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1611
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1612
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1613
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1614
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1615
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1616
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1617
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1618
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1619
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1620
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1621
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1622
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1623
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1624 Galbraith, et al. Expires June 18, 2003 [Page 29]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1625
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1626 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1627
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1628
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1629 8. Vendor-Specific Extensions
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1630
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1631 The SSH_FXP_EXTENDED request provides a generic extension mechanism
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1632 for adding vendor-specific commands. The request has the following
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1633 format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1634
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1635 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1636 string extended-request
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1637 ... any request-specific data ...
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1638
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1639 where `id' is the request identifier, and `extended-request' is a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1640 string of the format "name@domain", where domain is an internet
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1641 domain name of the vendor defining the request. The rest of the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1642 request is completely vendor-specific, and servers should only
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1643 attempt to interpret it if they recognize the `extended-request'
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1644 name.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1645
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1646 The server may respond to such requests using any of the response
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1647 packets defined in Section ``Responses from the Server to the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1648 Client''. Additionally, the server may also respond with a
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1649 SSH_FXP_EXTENDED_REPLY packet, as defined below. If the server does
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1650 not recognize the `extended-request' name, then the server MUST
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1651 respond with SSH_FXP_STATUS with error/status set to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1652 SSH_FX_OP_UNSUPPORTED.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1653
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1654 The SSH_FXP_EXTENDED_REPLY packet can be used to carry arbitrary
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1655 extension-specific data from the server to the client. It is of the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1656 following format:
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1657
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1658 uint32 id
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1659 ... any request-specific data ...
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1660
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1661 There is a range of packet types reserved for use by extensions. In
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1662 order to avoid collision, extensions that turn on the use of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1663 additional packet types should determine those numbers dynamically.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1664
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1665 The suggested way of doing this is have an extension request from the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1666 client to the server that enables the extension; the extension
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1667 response from the server to the client would specify the actual type
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1668 values to use, in additional to any other data.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1669
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1670 Extension authors should be mindful of the limited range of packet
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1671 types available (there are only 45 values available) and avoid
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1672 requiring a new packet type where possible.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1673
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1674
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1675
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1676
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1677
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1678
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1679
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1680 Galbraith, et al. Expires June 18, 2003 [Page 30]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1681
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1682 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1683
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1684
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1685 9. Security Considerations
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1686
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1687 This protocol assumes that it is run over a secure channel and that
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1688 the endpoints of the channel have been authenticated. Thus, this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1689 protocol assumes that it is externally protected from network-level
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1690 attacks.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1691
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1692 This protocol provides file system access to arbitrary files on the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1693 server (only constrained by the server implementation). It is the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1694 responsibility of the server implementation to enforce any access
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1695 controls that may be required to limit the access allowed for any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1696 particular user (the user being authenticated externally to this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1697 protocol, typically using the SSH User Authentication Protocol [8].
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1698
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1699 Care must be taken in the server implementation to check the validity
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1700 of received file handle strings. The server should not rely on them
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1701 directly; it MUST check the validity of each handle before relying on
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1702 it.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1703
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1704
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1705
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1706
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1707
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1708
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1709
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1710
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1711
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1712
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1713
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1714
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1715
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1716
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1717
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1718
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1719
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1720
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1721
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1722
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1723
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1724
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1725
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1726
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1727
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1728
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1729
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1730
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1731
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1732
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1733
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1734
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1735
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1736 Galbraith, et al. Expires June 18, 2003 [Page 31]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1737
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1738 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1739
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1740
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1741 10. Changes from previous protocol versions
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1742
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1743 The SSH File Transfer Protocol has changed over time, before it's
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1744 standardization. The following is a description of the incompatible
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1745 changes between different versions.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1746
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1747 10.1 Changes between versions 4 and 3
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1748
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1749 Many of the changes between version 4 and version 3 are to the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1750 attribute structure to make it more flexible for non-unix platforms.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1751
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1752 o Clarify the use of stderr by the server.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1753
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1754 o Clarify handling of very large read requests by the server.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1755
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1756 o Make all filenames UTF-8.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1757
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1758 o Added 'newline' extension.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1759
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1760 o Made time fields 64 bit, and optionally have nanosecond resultion.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1761
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1762 o Made file attribute owner and group strings so they can actually
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1763 be used on disparate systems.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1764
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1765 o Added createtime field, and added separate flags for atime,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1766 createtime, and mtime so they can be set separately.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1767
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1768 o Split the file type out of the permissions field and into it's own
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1769 field (which is always present.)
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1770
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1771 o Added acl attribute.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1772
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1773 o Added SSH_FXF_TEXT file open flag.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1774
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1775 o Added flags field to the get stat commands so that the client can
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1776 specifically request information the server might not normally
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1777 included for performance reasons.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1778
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1779 o Removed the long filename from the names structure-- it can now be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1780 built from information available in the attrs structure.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1781
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1782 o Added reserved range of packet numbers for extensions.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1783
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1784 o Added several additional error codes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1785
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1786
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1787
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1788
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1789
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1790
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1791
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1792 Galbraith, et al. Expires June 18, 2003 [Page 32]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1793
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1794 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1795
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1796
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1797 10.2 Changes between versions 3 and 2
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1798
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1799 o The SSH_FXP_READLINK and SSH_FXP_SYMLINK messages were added.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1800
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1801 o The SSH_FXP_EXTENDED and SSH_FXP_EXTENDED_REPLY messages were
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1802 added.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1803
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1804 o The SSH_FXP_STATUS message was changed to include fields `error
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1805 message' and `language tag'.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1806
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1807
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1808 10.3 Changes between versions 2 and 1
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1809
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1810 o The SSH_FXP_RENAME message was added.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1811
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1812
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1813 10.4 Changes between versions 1 and 0
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1814
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1815 o Implementation changes, no actual protocol changes.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1816
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1817
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1818
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1819
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1820
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1821
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1822
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1823
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1824
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1825
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1826
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1827
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1828
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1829
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1830
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1831
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1832
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1833
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1834
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1835
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1836
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1837
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1838
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1839
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1840
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1841
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1842
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1843
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1844
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1845
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1846
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1847
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1848 Galbraith, et al. Expires June 18, 2003 [Page 33]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1849
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1850 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1851
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1852
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1853 11. Trademark Issues
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1854
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1855 "ssh" is a registered trademark of SSH Communications Security Corp
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1856 in the United States and/or other countries.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1857
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1858
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1859
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1860
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1861
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1862
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1863
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1864
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1865
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1866
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1867
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1868
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1869
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1870
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1871
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1872
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1873
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1874
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1875
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1876
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1877
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1878
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1879
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1880
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1881
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1882
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1883
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1884
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1885
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1886
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1887
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1888
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1889
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1890
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1891
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1892
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1893
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1894
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1895
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1896
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1897
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1898
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1899
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1900
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1901
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1902
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1903
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1904 Galbraith, et al. Expires June 18, 2003 [Page 34]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1905
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1906 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1907
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1908
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1909 References
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1910
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1911 [1] Dierks, T., Allen, C., Treese, W., Karlton, P., Freier, A. and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1912 P. Kocher, "The TLS Protocol Version 1.0", RFC 2246, January
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1913 1999.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1914
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1915 [2] Alvestrand, H., "IETF Policy on Character Sets and Languages",
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1916 BCP 18, RFC 2277, January 1998.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1917
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1918 [3] Shepler, S., Callaghan, B., Robinson, D., Thurlow, R., Beame,
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1919 C., Eisler, M. and D. Noveck, "NFS version 4 Protocol", RFC
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1920 3010, December 2000.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1921
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1922 [4] Institute of Electrical and Electronics Engineers, "Information
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1923 Technology - Portable Operating System Interface (POSIX) - Part
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1924 1: System Application Program Interface (API) [C Language]",
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1925 IEEE Standard 1003.2, 1996.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1926
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1927 [5] Rinne, T., Ylonen, T., Kivinen, T., Saarinen, M. and S.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1928 Lehtinen, "SSH Protocol Architecture",
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1929 draft-ietf-secsh-architecture-13 (work in progress), September
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1930 2002.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1931
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1932 [6] Rinne, T., Ylonen, T., Kivinen, T., Saarinen, M. and S.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1933 Lehtinen, "SSH Protocol Transport Protocol",
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1934 draft-ietf-secsh-transport-15 (work in progress), September
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1935 2002.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1936
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1937 [7] Rinne, T., Ylonen, T., Kivinen, T., Saarinen, M. and S.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1938 Lehtinen, "SSH Connection Protocol", draft-ietf-secsh-connect-16
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1939 (work in progress), September 2002.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1940
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1941 [8] Rinne, T., Ylonen, T., Kivinen, T., Saarinen, M. and S.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1942 Lehtinen, "SSH Authentication Protocol",
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1943 draft-ietf-secsh-userauth-16 (work in progress), September 2002.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1944
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1945
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1946 Authors' Addresses
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1947
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1948 Joseph Galbraith
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1949 VanDyke Software
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1950 4848 Tramway Ridge Blvd
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1951 Suite 101
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1952 Albuquerque, NM 87111
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1953 US
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1954
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1955 Phone: +1 505 332 5700
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1956 EMail: galb-list@vandyke.com
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1957
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1958
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1959
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1960 Galbraith, et al. Expires June 18, 2003 [Page 35]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1961
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1962 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1963
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1964
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1965 Tatu Ylonen
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1966 SSH Communications Security Corp
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1967 Fredrikinkatu 42
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1968 HELSINKI FIN-00100
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1969 Finland
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1970
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1971 EMail: ylo@ssh.com
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1972
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1973
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1974 Sami Lehtinen
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1975 SSH Communications Security Corp
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1976 Fredrikinkatu 42
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1977 HELSINKI FIN-00100
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1978 Finland
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1979
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1980 EMail: sjl@ssh.com
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1981
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1982
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1983
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1984
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1985
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1986
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1987
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1988
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1989
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1990
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1991
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1992
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1993
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1994
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1995
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1996
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1997
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1998
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
1999
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2000
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2001
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2003
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2004
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2005
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2006
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2007
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2008
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2009
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2010
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2011
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2012
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2013
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2014
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2015
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2016 Galbraith, et al. Expires June 18, 2003 [Page 36]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2017
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2018 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2019
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2020
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2021 Intellectual Property Statement
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2022
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2023 The IETF takes no position regarding the validity or scope of any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2024 intellectual property or other rights that might be claimed to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2025 pertain to the implementation or use of the technology described in
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2026 this document or the extent to which any license under such rights
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2027 might or might not be available; neither does it represent that it
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2028 has made any effort to identify any such rights. Information on the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2029 IETF's procedures with respect to rights in standards-track and
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2030 standards-related documentation can be found in BCP-11. Copies of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2031 claims of rights made available for publication and any assurances of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2032 licenses to be made available, or the result of an attempt made to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2033 obtain a general license or permission for the use of such
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2034 proprietary rights by implementors or users of this specification can
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2035 be obtained from the IETF Secretariat.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2036
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2037 The IETF invites any interested party to bring to its attention any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2038 copyrights, patents or patent applications, or other proprietary
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2039 rights which may cover technology that may be required to practice
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2040 this standard. Please address the information to the IETF Executive
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2041 Director.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2042
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2043
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2044 Full Copyright Statement
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2045
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2046 Copyright (C) The Internet Society (2002). All Rights Reserved.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2047
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2048 This document and translations of it may be copied and furnished to
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2049 others, and derivative works that comment on or otherwise explain it
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2050 or assist in its implementation may be prepared, copied, published
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2051 and distributed, in whole or in part, without restriction of any
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2052 kind, provided that the above copyright notice and this paragraph are
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2053 included on all such copies and derivative works. However, this
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2054 document itself may not be modified in any way, such as by removing
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2055 the copyright notice or references to the Internet Society or other
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2056 Internet organizations, except as needed for the purpose of
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2057 developing Internet standards in which case the procedures for
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2058 copyrights defined in the Internet Standards process must be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2059 followed, or as required to translate it into languages other than
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2060 English.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2061
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2062 The limited permissions granted above are perpetual and will not be
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2063 revoked by the Internet Society or its successors or assignees.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2064
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2065 This document and the information contained herein is provided on an
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2066 "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2067 TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2068 BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2069
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2070
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2071
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2072 Galbraith, et al. Expires June 18, 2003 [Page 37]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2073
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2074 Internet-Draft SSH File Transfer Protocol December 2002
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2075
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2076
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2077 HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2078 MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2079
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2080
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2081 Acknowledgement
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2082
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2083 Funding for the RFC Editor function is currently provided by the
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2084 Internet Society.
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2085
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2086
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2087
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2088
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2089
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2090
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2091
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2092
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2093
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2094
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2095
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2096
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2097
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2098
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2099
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2100
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2101
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2102
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2103
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2104
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2105
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2106
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2107
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2108
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2109
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2110
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2111
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2112
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2113
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2114
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2115
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2116
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2117
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2118
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2119
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2120
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2121
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2122
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2123
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2124
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2125
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2126
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2127
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2128 Galbraith, et al. Expires June 18, 2003 [Page 38]
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2129
e60a6ec4aa85 2004-7-12 Brian Masney <masneyb@gftp.org>
masneyb
parents:
diff changeset
2130