How does FXP (server to server) work ?
FXP, or server to server transfer is defined in RFC959 : User C Server A User C Server B —————— —————— C->A : Connect C->B : Connect C->A : PASV A->C : 227 Entering Passive Mode. A1,A2,A3,A4,a1,a2 C->B : PORT A1,A2,A3,A4,a1,a2 B->C : 200 Okay C->A : STOR C->B : RETR B->A : Connect to HOST-A, PORT-a 1) User C connects to Server A, it also connects to Server B, then it sends a PASV command to A (so that C can pass the ip & port as a PORT parameter to B). 2) B receives PORT command indicating that it has to connect to A for data connection (PORT command with A’s PASV parameters). 3) B sends “ok” to C (no connection at this time). 4) C asks A to upload the file (STOR) & to download the file from B (RETR). 5) B connect to A with ip & port received via PORT command in 2) 6) Data connection is opened & transfer begins.