Gentoo Archives: gentoo-user

From: Paul Hartman <paul.hartman+gentoo@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] setsockopt SO_DEBUG - ftp connection problems
Date: Tue, 05 Jul 2011 19:52:48
Message-Id: CAEH5T2MmaPx0q1=XV+ejChm5DwmuaoC18eQxRuBGu4MpBpTu_w@mail.gmail.com
In Reply to: Re: [gentoo-user] setsockopt SO_DEBUG - ftp connection problems by Mick
1 On Tue, Jul 5, 2011 at 2:34 PM, Mick <michaelkintzios@×××××.com> wrote:
2 > On Tuesday 05 Jul 2011 19:42:53 Paul Hartman wrote:
3 >> On Tue, Jul 5, 2011 at 6:58 AM, Mick <michaelkintzios@×××××.com> wrote:
4 >> > 200 Switching to ASCII mode.
5 >> > tnftp: setsockopt SO_DEBUG (ignored): Permission denied
6 >> > ---> EPSV
7 >> > 229 Entering Extended Passive Mode (|||62430|)
8 >> > 229 Entering Extended Passive Mode (|||62430|)
9 >>
10 >> Don't use EPSV, use PASV instead, hopefully that will work.
11 >
12 > I tried defining passive when in the session.  It was in passive by default,
13 > so I had to toggle it back on again:
14 >
15 > got remotecwd as `/'
16 > ---> TYPE I
17 > 200 Switching to Binary mode.
18 > ftp> passive
19 > Passive mode: off; fallback to active mode: off.
20 > ftp> passive
21 > Passive mode: on; fallback to active mode: on.
22 > ftp> ls
23 > ---> TYPE A
24 > 200 Switching to ASCII mode.
25 > tnftp: setsockopt SO_DEBUG (ignored): Permission denied
26 > ---> EPSV
27 > 229 Entering Extended Passive Mode (|||9832|)
28 > 229 Entering Extended Passive Mode (|||9832|)
29 >
30 > How can I control it to not go into extended passive?
31 >
32 > PS. The server reports EPSV in its features, so I am not sure why it would not
33 > work with EPSV.
34
35 FTP is the bastard protocol from hell. There are more ways it can go
36 wrong than right. :) Firewalls especially love to silently rewrite FTP
37 commands and port mappings. It can be a real PITA to debug. So, even
38 if your client supports EPSV and your server supports EPSV, if
39 firewall/router in-between does not then it could still break things.
40 Even if you wireshark the session on your computer, what you see may
41 not match what's being sent to the remote server, and vice-versa.
42
43 Standard PASV mode is much more widely supported than EPSV mode, so
44 that's the line of thought that brought me to suggest trying that.
45
46 I've never used tnftp but from the manpage I googled, it looks like
47 "epsv4 off " is the command to toggle EPSV off.

Replies

Subject Author
Re: [gentoo-user] setsockopt SO_DEBUG - ftp connection problems Mick <michaelkintzios@×××××.com>