This is a static archive of our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

Trace SFTP handling CRLF to LF EOL

0

Hi, We are using Jcraft java library and it is using SFTP to transfer the our own shell script file name "A" from windows to Linux OS. Sometimes it was showing up as DOS format at Linux machine since copied at Linux, due to this reason we are not able to execute this shell script. So, do we have any option/flags/something in wire shark? Does this wire shark indicate us "it changes from CRLF to LF" ?

asked 08 Jun '17, 08:10

kalyanasundaram's gravatar image

kalyanasundaram
6112
accept rate: 0%


One Answer:

0

FTP services work with so called modes for transport of files. These modes are 'text' and 'binary'. In the former any transcoding may take place to create a file conforming to local formatting. In the latter no transcoding is applied at all. I can assume that you'll have to make sure the transport mode is text so that local EOL encoding is applied.

In Wireshark you may be able to find the mode setting in packets exchanged across the command channel, but it could also be that the default is used, and that this may not always be the state you require.

And then you're talking about SFTP, so you'll have to decrypt first.

answered 08 Jun '17, 14:18

Jaap's gravatar image

Jaap ♦
11.7k16101
accept rate: 14%