Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PASV Intermitent Error on WinScp #110

Open
albertoVieiraNeto opened this issue Sep 17, 2020 · 2 comments
Open

PASV Intermitent Error on WinScp #110

albertoVieiraNeto opened this issue Sep 17, 2020 · 2 comments

Comments

@albertoVieiraNeto
Copy link

Hi, i'm using this library to build a application with a FTP server, its great but i'm facing a strange issue where sometimes, one specific client (winscp) will throw "Syntax Error in parameters or arguments", after adding serilog to the pipeline, one commandhandler is throwing the following error:


[12:50:28 ERR] Failed to process message (PASV )
System.Net.Sockets.SocketException (0x80004005): Foi feita uma tentativa de acesso a um soquete de uma maneira que é proibida pelas permissões de acesso
   em System.Net.Sockets.Socket.DoBind(EndPoint endPointSnapshot, SocketAddress socketAddress)
   em System.Net.Sockets.Socket.Bind(EndPoint localEP)
   em System.Net.Sockets.TcpListener.Start(Int32 backlog)
   em FubarDev.FtpServer.PasvListener..ctor(IPAddress listenAddress, Int32 port, IPAddress externalAddress)
   em FubarDev.FtpServer.PasvListenerFactory.CreateListenerInRange(IFtpConnection connection, PasvListenerOptions pasvOptions)
   em FubarDev.FtpServer.PasvListenerFactory.<CreateTcpListenerAsync>d__5.MoveNext()
--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---
   em System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   em FubarDev.FtpServer.DataConnection.PassiveDataConnectionFeatureFactory.<CreateFeatureAsync>d__5.MoveNext()
--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---
   em System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   em System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   em FubarDev.FtpServer.CommandHandlers.PasvCommandHandler.<Process>d__2.MoveNext()
--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---
   em System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   em FubarDev.FtpServer.ConnectionExtensions.<ExecuteCommand>d__0.MoveNext()

the funny thing is, if i just "update" the folder, it works, can anyone helpme with this?

@fubar-coder
Copy link
Contributor

You may need to start the application as root/Administrator. If it works, then the problem is the selected passive port. You should use a port range with a number >1024 (IIRC).

@albertoVieiraNeto
Copy link
Author

@fubar-coder thanks, i had configured only the FtpServerOptions.ServerAddress, but forgot to configure the SimplePasvOptions.PublicAddress, that was aparently generating the error, strangely enough just on WinScp.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants