2012-12-07 4 views
2

현재 내 프로젝트 (ftp 클라이언트 부분) 중 하나에서 ftp 프로토콜을 구현 중입니다. 나는 따라하고있다 RFC959FTP 프로토콜의 이스케이프 문자

이 RFC에서는, 나는 문제에 직면하고있다 : 이스케이프 문자, 실제로 그것이 이스케이프 문자로 사용되어야한다고 설명했다. 그러나 나는 그 특정한 성격이 무엇인지 전혀 모른다. 여기

는 이스케이프 문자에 대한 RFC의 일부입니다

 3.4.1. STREAM MODE 

    The data is transmitted as a stream of bytes. There is no 
    restriction on the representation type used; record structures 
    are allowed. 

    In a record structured file EOR and EOF will each be indicated 
    by a two-byte control code. The first byte of the control code 
    will be all ones, the escape character. The second byte will 
    have the low order bit on and zeros elsewhere for EOR and the 
    second low order bit on for EOF; that is, the byte will have 
    value 1 for EOR and value 2 for EOF. EOR and EOF may be 
    indicated together on the last byte transmitted by turning both 
    low order bits on (i.e., the value 3). If a byte of all ones 
    was intended to be sent as data, it should be repeated in the 
    second byte of the control code. 

    If the structure is a file structure, the EOF is indicated by 
    the sending host closing the data connection and all bytes are 
    data bytes. 

캐릭터가 무엇 사람이 알고 있나요?

일반적으로 파일 전송을 FTP 서버에 알려주는 방법에 대한 단서가 있습니까?

미리 감사드립니다.

답변

5

"제어 코드의 첫 번째 바이트는 모두 이스케이프 문자입니다." - 다른 말로하면 - 0xff

+0

그게 전부 야! 감사합니다 (10 분 안에 체크 표시). – Joze