IETF-SSH archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

RE: solving the SFTP text mode issue



At 03:20 PM 5/10/2002, denis bider wrote:
> SSH_FXP_READ_RECORD
> uint32 start record number
> uint32 number of records to read
>
> Openning a text file in record mode would
> resulting in recieveing each line as a
> seperate record with no termination.

Doesn't sound half bad... Seeking to the middle of an LF-separated text file
would require the server to manually count the lines, but I guess this isn't
really a problem if we consider that the other possibilities don't offer
random access in the first place.

Also, we might offer a special record number, e.g. -1, for use with
SSH_FXP_WRITE_RECORD to indicate that the record is to be appended. Or
perhaps we could simply provide another packet type called
SSH_FXP_APPEND_RECORD.

How does this solution resonate with you all VMS people?

I think it's close.  There are 3 main fundamental formats we must deal
with:

- Stream LF (i.e., "UNIX" mode)
- delimited, variable-length records (usually, CR/LF pairs)
- variable-length records with a fixed-length binary record-size field
  at the beginning of each record

There are other permutations of text files in VMS, but they're basically
"variations on a theme", in that they're a derivation of one of the above
formats, and so what works for the above should work for them as well.

So, this solution would seem to apply to the 2nd format (the first format
is obviously handled today), but I'm not sure of the 3rd format.  We would
need to examine this proposal and see what the implications are.

------
+-------------------------------+---------------------------------------+
| Dan O'Reilly                  |                                       |
| Principal Engineer            |  "Why should I care about posterity?  |
| Process Software              |   What's posterity ever done for me?" |
| http://www.process.com        |                    -- Groucho Marx    |
+-------------------------------+---------------------------------------+




Home | Main Index | Thread Index | Old Index