TP-LINK O modem Archer d50 está bloqueando o acesso FTP a um site específico

0

Eu tentei compartilhar internet do meu smartphone e funcionou no meu PC. Quando mudei para conexão de modem, posso fazer login no servidor FTP, mas ele não me mostra diretórios.

Eu também tentei encaminhar as portas 20 e 21 no meu roteador, mas não tenho certeza se está certo. Alguém pode me dizer o que colocar nesses campos? insira a descrição da imagem aqui

Eu também tentei o modo ativo e passivo, mas nada mudou. O site é www.binini.it, eu tentei um monte de clientes como o FileZilla, CoreFtp e Cyberduck. Percebi que com o net2ftp funciona.

Aqui está o traceback do FileZilla.

Status: Connecting to 209.227.193.130:21...
Status: Connection established, waiting for welcome message...
Status: Insecure server, it does not support FTP over TLS.
Status: Logged in
Status: Retrieving directory listing...
Command:    PWD
Response:   257 "/**hidden**" is current directory.
Command:    TYPE I
Response:   200 Type set to I.
Command:    PASV
Error:  Disconnected from server: ECONNABORTED - Connection aborted
Error:  Failed to retrieve directory listing
Status: Disconnected from server
Status: Connecting to 209.227.193.130:21...
Status: Connection established, waiting for welcome message...
Status: Insecure server, it does not support FTP over TLS.
Status: Logged in
Status: Retrieving directory listing...
Command:    PWD
Response:   257 "/**hidden**" is current directory.
Command:    TYPE I
Response:   200 Type set to I.
Command:    PASV
Error:  Disconnected from server: ECONNABORTED - Connection aborted
Error:  Failed to retrieve directory listing

Com o ftp.exe eu consigo logar, mas fiquei empilhado após "quote pasv". Terminal me responder com "conexão fechada do host remoto".

Este é o log de depuração completo:

Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 0
Status: Connecting to 209.227.193.130:21...
Status: Connection established, waiting for welcome message...
Trace:  CFtpControlSocket::OnReceive()
Response:   220 Microsoft FTP Service
Trace:  CFtpLogonOpData::ParseResponse() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 2
Command:    AUTH TLS
Trace:  CFtpControlSocket::OnReceive()
Response:   534 Local policy on server does not allow TLS secure connections.
Trace:  CFtpLogonOpData::ParseResponse() in state 2
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 3
Command:    AUTH SSL
Trace:  CFtpControlSocket::OnReceive()
Response:   534 Local policy on server does not allow TLS secure connections.
Trace:  CFtpLogonOpData::ParseResponse() in state 3
Status: Insecure server, it does not support FTP over TLS.
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 5
Command:    USER w8km01a130
Trace:  CFtpControlSocket::OnReceive()
Response:   331 Password required for w8km01a130.
Trace:  CFtpLogonOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 5
Command:    PASS **********
Trace:  CFtpControlSocket::OnReceive()
Response:   230 User logged in.
Trace:  CFtpLogonOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 6
Command:    SYST
Trace:  CFtpControlSocket::OnReceive()
Response:   215 Windows_NT
Trace:  CFtpLogonOpData::ParseResponse() in state 6
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 7
Command:    FEAT
Trace:  CFtpControlSocket::OnReceive()
Response:   211-Extended features supported:
Response:    LANG EN*
Response:    UTF8
Trace:  CFtpControlSocket::OnReceive()
Response:    AUTH TLS;TLS-C;SSL;TLS-P;
Response:    PBSZ
Response:    PROT C;P;
Response:    CCC
Response:    HOST
Trace:  CFtpControlSocket::OnReceive()
Response:    SIZE
Response:    MDTM
Response:    REST STREAM
Response:   211 END
Trace:  CFtpLogonOpData::ParseResponse() in state 7
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 9
Command:    OPTS UTF8 ON
Trace:  CFtpControlSocket::OnReceive()
Response:   200 OPTS UTF8 command successful - UTF8 encoding now ON.
Trace:  CFtpLogonOpData::ParseResponse() in state 9
Status: Logged in
Trace:  Measured latency of 62 ms
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CFileZillaEnginePrivate::ResetOperation(0)
Status: Retrieving directory listing...
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 0
Trace:  CFtpChangeDirOpData::Send() in state 0
Trace:  CFtpChangeDirOpData::Send() in state 1
Command:    PWD
Trace:  CFtpControlSocket::OnReceive()
Response:   257 "/w8km01a130" is current directory.
Trace:  CFtpChangeDirOpData::ParseResponse() in state 1
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CControlSocket::ParseSubcommandResult(0)
Trace:  CFtpListOpData::SubcommandResult() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 2
Trace:  CFtpRawTransferOpData::Send() in state 1
Command:    TYPE I
Trace:  CFtpControlSocket::OnReceive()
Response:   200 Type set to I.
Trace:  CFtpRawTransferOpData::ParseResponse() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpRawTransferOpData::Send() in state 2
Command:    PASV
Trace:  CRealControlSocket::OnClose(106)
Error:  Disconnected from server: ECONNABORTED - Connection aborted
Trace:  CControlSocket::DoClose(66)
Trace:  CFtpControlSocket::ResetOperation(66)
Trace:  CControlSocket::ResetOperation(66)
Trace:  CFtpControlSocket::ResetOperation(66)
Trace:  CControlSocket::ResetOperation(66)
Error:  Failed to retrieve directory listing
Trace:  CFileZillaEnginePrivate::ResetOperation(66)
Status: Disconnected from server
Trace:  CControlSocket::DoClose(66)
Trace:  CControlSocket::DoClose(66)
Trace:  CControlSocket::DoClose(66)
Trace:  CFileZillaEnginePrivate::ResetOperation(0)
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 0
Status: Connecting to 209.227.193.130:21...
Status: Connection established, waiting for welcome message...
Trace:  CFtpControlSocket::OnReceive()
Response:   220 Microsoft FTP Service
Trace:  CFtpLogonOpData::ParseResponse() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 2
Command:    AUTH TLS
Trace:  CFtpControlSocket::OnReceive()
Response:   534 Local policy on server does not allow TLS secure connections.
Trace:  CFtpLogonOpData::ParseResponse() in state 2
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 3
Command:    AUTH SSL
Trace:  CFtpControlSocket::OnReceive()
Response:   534 Local policy on server does not allow TLS secure connections.
Trace:  CFtpLogonOpData::ParseResponse() in state 3
Status: Insecure server, it does not support FTP over TLS.
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 5
Command:    USER w8km01a130
Trace:  CFtpControlSocket::OnReceive()
Response:   331 Password required for w8km01a130.
Trace:  CFtpLogonOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 5
Command:    PASS **********
Trace:  CFtpControlSocket::OnReceive()
Response:   230 User logged in.
Trace:  CFtpLogonOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 9
Command:    OPTS UTF8 ON
Trace:  CFtpControlSocket::OnReceive()
Response:   200 OPTS UTF8 command successful - UTF8 encoding now ON.
Trace:  CFtpLogonOpData::ParseResponse() in state 9
Status: Logged in
Trace:  Measured latency of 81 ms
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CFileZillaEnginePrivate::ResetOperation(0)
Status: Retrieving directory listing...
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 0
Trace:  CFtpChangeDirOpData::Send() in state 0
Trace:  CFtpChangeDirOpData::Send() in state 1
Command:    PWD
Trace:  CFtpControlSocket::OnReceive()
Response:   257 "/w8km01a130" is current directory.
Trace:  CFtpChangeDirOpData::ParseResponse() in state 1
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CControlSocket::ParseSubcommandResult(0)
Trace:  CFtpListOpData::SubcommandResult() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 2
Trace:  CFtpRawTransferOpData::Send() in state 1
Command:    TYPE I
Trace:  CFtpControlSocket::OnReceive()
Response:   200 Type set to I.
Trace:  CFtpRawTransferOpData::ParseResponse() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpRawTransferOpData::Send() in state 2
Command:    PASV
Trace:  CRealControlSocket::OnClose(106)
Error:  Disconnected from server: ECONNABORTED - Connection aborted
Trace:  CControlSocket::DoClose(66)
Trace:  CFtpControlSocket::ResetOperation(66)
Trace:  CControlSocket::ResetOperation(66)
Trace:  CFtpControlSocket::ResetOperation(66)
Trace:  CControlSocket::ResetOperation(66)
Error:  Failed to retrieve directory listing
Trace:  CFileZillaEnginePrivate::ResetOperation(66)

Este é o rastreio com a minha ligação partilhada ao telemóvel:

    Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 0
Status: Connecting to 209.227.193.130:21...
Status: Connection established, waiting for welcome message...
Trace:  CFtpControlSocket::OnReceive()
Response:   220 Microsoft FTP Service
Trace:  CFtpLogonOpData::ParseResponse() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 2
Command:    AUTH TLS
Trace:  CFtpControlSocket::OnReceive()
Response:   534 Local policy on server does not allow TLS secure connections.
Trace:  CFtpLogonOpData::ParseResponse() in state 2
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 3
Command:    AUTH SSL
Trace:  CFtpControlSocket::OnReceive()
Response:   534 Local policy on server does not allow TLS secure connections.
Trace:  CFtpLogonOpData::ParseResponse() in state 3
Status: Insecure server, it does not support FTP over TLS.
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 5
Command:    USER w8km01a130
Trace:  CFtpControlSocket::OnReceive()
Response:   331 Password required for w8km01a130.
Trace:  CFtpLogonOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 5
Command:    PASS **********
Trace:  CFtpControlSocket::OnReceive()
Response:   230 User logged in.
Trace:  CFtpLogonOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 6
Command:    SYST
Trace:  CFtpControlSocket::OnReceive()
Response:   215 Windows_NT
Trace:  CFtpLogonOpData::ParseResponse() in state 6
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 7
Command:    FEAT
Trace:  CFtpControlSocket::OnReceive()
Response:   211-Extended features supported:
Trace:  CFtpControlSocket::OnReceive()
Response:    LANG EN*
Response:    UTF8
Trace:  CFtpControlSocket::OnReceive()
Response:    AUTH TLS;TLS-C;SSL;TLS-P;
Response:    PBSZ
Response:    PROT C;P;
Response:    CCC
Trace:  CFtpControlSocket::OnReceive()
Response:    HOST
Trace:  CFtpControlSocket::OnReceive()
Response:    SIZE
Response:    MDTM
Response:    REST STREAM
Response:   211 END
Trace:  CFtpLogonOpData::ParseResponse() in state 7
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpLogonOpData::Send() in state 9
Command:    OPTS UTF8 ON
Trace:  CFtpControlSocket::OnReceive()
Response:   200 OPTS UTF8 command successful - UTF8 encoding now ON.
Trace:  CFtpLogonOpData::ParseResponse() in state 9
Status: Logged in
Trace:  Measured latency of 276 ms
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CFileZillaEnginePrivate::ResetOperation(0)
Status: Retrieving directory listing...
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 0
Trace:  CFtpChangeDirOpData::Send() in state 0
Trace:  CFtpChangeDirOpData::Send() in state 1
Command:    PWD
Trace:  CFtpControlSocket::OnReceive()
Response:   257 "/w8km01a130" is current directory.
Trace:  CFtpChangeDirOpData::ParseResponse() in state 1
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CControlSocket::ParseSubcommandResult(0)
Trace:  CFtpListOpData::SubcommandResult() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 2
Trace:  CFtpRawTransferOpData::Send() in state 1
Command:    TYPE I
Trace:  CFtpControlSocket::OnReceive()
Response:   200 Type set to I.
Trace:  CFtpRawTransferOpData::ParseResponse() in state 1
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpRawTransferOpData::Send() in state 2
Command:    PASV
Trace:  CFtpControlSocket::OnReceive()
Response:   227 Entering Passive Mode (66,71,190,20,195,87).
Trace:  CFtpRawTransferOpData::ParseResponse() in state 2
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpRawTransferOpData::Send() in state 4
Trace:  Destination IP of data connection does not match peer IP of control connection. Not binding source address of data connection.
Command:    LIST
Trace:  CTransferSocket::OnConnect
Trace:  CFtpControlSocket::OnReceive()
Response:   150 Opening BINARY mode data connection.
Trace:  CFtpRawTransferOpData::ParseResponse() in state 4
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpRawTransferOpData::Send() in state 5
Trace:  CFtpControlSocket::OnReceive()
Response:   226 Transfer complete.
Trace:  CFtpRawTransferOpData::ParseResponse() in state 5
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpRawTransferOpData::Send() in state 8
Trace:  CTransferSocket::OnReceive(), m_transferMode=0
Trace:  CTransferSocket::OnClose(0)
Trace:  CTransferSocket::TransferEnd(1)
Trace:  CFtpControlSocket::TransferEnd()
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Trace:  CControlSocket::ParseSubcommandResult(0)
Trace:  CFtpListOpData::SubcommandResult() in state 3
Trace:  CControlSocket::SendNextCommand()
Trace:  CFtpListOpData::ListSend() in state 4
Status: Calculating timezone offset of server...
Command:    MDTM Main.Master
Trace:  CFtpControlSocket::OnReceive()
Response:   213 20170703210504
Trace:  CFtpListOpData::ParseResponse() in state 4
Status: Timezone offset of server is 7200 seconds.
Trace:  CFtpControlSocket::ResetOperation(0)
Trace:  CControlSocket::ResetOperation(0)
Status: Directory listing of "/w8km01a130" successful
Trace:  CFileZillaEnginePrivate::ResetOperation(0)
    
por Filippo Scaramuzza 13.07.2017 / 13:25

2 respostas

0

A partir do traço de sucesso:

Status: Connecting to 209.227.193.130:21...
...
Command: PASV
Response: 227 Entering Passive Mode (66,71,190,20,195,87).
...
Trace: Destination IP of data connection does not match peer IP of control connection....

A resposta ao comando passivo está dizendo que o servidor deve estar conectado em 66.71.190.20, porta 50007 (195 * 256 + 87) para a conexão de dados. Observe que esse endereço IP é diferente do endereço do servidor ao qual você está conectado. Embora, em teoria, o protocolo FTP original suporte esse modo de operação, em que o servidor para a conexão de controle é diferente do servidor para a conexão de dados, é muito incomum e é mais provavelmente causado por um erro de configuração no servidor. Com base no tracepath, eu diria que na verdade é um endereço diferente no mesmo servidor.

E esta é provavelmente a razão pela qual a transferência falha. No log do seu roteador TP-Link, você encontra a seguinte reação ao comando PASV:

Command: PASV
Error: Disconnected from server: ECONNABORTED - Connection aborted

Eu interpretaria isso como o auxiliar FTP no roteador abortou a conexão FTP porque o comando PASV resultou em uma resposta inesperada, em que o IP dentro do PASV que deveria ser usado para a conexão de dados não correspondia ao IP do controle conexão.

Isso também explica por que os problemas só acontecem com esse servidor específico, porque todos os outros servidores não mostram esse comportamento incomum.

Mas, caso isso seja apenas um endereço diferente no mesmo servidor, você pode tentar conectar o FTP a 66.71.190.20 em vez de 209.227.193.130. Espero que o primeiro tenha sucesso, já que o IP na conexão de controle e a resposta PASV são os mesmos.

    
por 14.07.2017 / 14:22
0

O FTP é apenas um protocolo de pesadelo porque usa portas dinâmicas e a troca dos números de porta relevantes é feita na camada de aplicativo. Isso significa que frequentemente os auxiliares estão envolvidos em firewalls ou roteadores NAT ou no ISP e no provedor de serviços móveis (para NAT de nível de operadora), o que pode funcionar ou não funcionar.

Os problemas são especialmente o uso de FTPS (ou seja, FTP criptografado) em que o aplicativo auxiliar não pode obter os números de porta porque o tráfego é criptografado. O problema também está nos novos comandos que foram adicionados para suportar o IPv6, mas que também são usados sem o IPv6 (por exemplo, EPRT, EPSV em vez de PORT e PASV).

Em suma: tente usar SFTP em vez de FTP / FTPS. O SFTP é a transferência de arquivos no topo do SSH, é mais seguro e não tem nenhum dos problemas do FTP (S) em relação às portas dinâmicas. Claro, o servidor precisa suportá-lo.

    
por 13.07.2017 / 14:37