Issue 276 in pyftpdlib: Show all available IP addresses in verbose mode

4 views
Skip to first unread message

pyft...@googlecode.com

unread,
Dec 15, 2013, 4:54:35 AM12/15/13
to pyftpdli...@googlegroups.com
Status: New
Owner: tech...@gmail.com
Labels: Type-Enhancement Priority-Medium Component-Library Usability

New issue 276 by tech...@gmail.com: Show all available IP addresses in
verbose mode
http://code.google.com/p/pyftpdlib/issues/detail?id=276

After launching pyftpdlib in default mode (0.0.0.0), it is impossible to
tell to which IP I should connect with my FTP client.

What is the expected output? What do you see instead?
expected> $ pyftpdlib --verbose
expected> >>> starting FTP server on 0.0.0.0:21
expected> ... interfaces that server currently listens on
expected> ... - 127.0.0.1
expected> ... - 192.168.1.89
expected> ... - 129.28.23.11

Please use labels and text to provide additional information.
Do you know how to get the list of IP addresses for network interfaces?
I guess there are two cases:
1. 0.0.0.0 IPs before listening (expected)
2. after listening (actual)
I wonder if a new interface is added after pyftpdlib started, will it
listen on a new interface also if started with 0.0.0.0?

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

pyft...@googlecode.com

unread,
Dec 15, 2013, 6:02:15 AM12/15/13
to pyftpdli...@googlegroups.com

Comment #1 on issue 276 by g.rodola: Show all available IP addresses in
verbose mode
http://code.google.com/p/pyftpdlib/issues/detail?id=276

AFAIK python does not provide anything to list addresses associated with
NIC interfaces, or at least not in a portable fashion.
There are third party libs which do that (pcapy comes to mind) but nothing
within the stdlib.

Displaying NIC "private" addresses is not very important though.
The IP you are usually interested in is the "public" IP address, which is
the address of your gateway, and the only way to determine that is to have
your FTP server interact with services such as whatsmyip.org. That is
something which pyftpdlib should not do by default though.

pyft...@googlecode.com

unread,
Dec 15, 2013, 6:13:06 AM12/15/13
to pyftpdli...@googlegroups.com

Comment #2 on issue 276 by tech...@gmail.com: Show all available IP
The network topology is rightfully out of scope of pyftpdlib. The thing
that it can do is to report only it's own addresses.

Actually, I thought that this info is exposed in
http://code.google.com/p/psutil/ =)

I am now looking at
http://stackoverflow.com/questions/166506/finding-local-ip-addresses-using-pythons-stdlib

pyft...@googlecode.com

unread,
Dec 15, 2013, 6:24:27 AM12/15/13
to pyftpdli...@googlegroups.com

Comment #3 on issue 276 by g.rodola: Show all available IP addresses in
verbose mode
http://code.google.com/p/pyftpdlib/issues/detail?id=276

Hehe yes, indeed this is something I'm planning to implement in psutil. =)
See: https://code.google.com/p/psutil/issues/detail?id=376

pyft...@googlecode.com

unread,
Dec 15, 2013, 8:21:01 AM12/15/13
to pyftpdli...@googlegroups.com

Comment #4 on issue 276 by tech...@gmail.com: Show all available IP
Moved to https://code.google.com/p/psutil/issues/detail?id=376 in search
for solution.

pyft...@googlecode.com

unread,
Apr 11, 2014, 12:34:48 PM4/11/14
to pyftpdli...@googlegroups.com
Updates:
Status: Rejected

Comment #5 on issue 276 by g.rodola: Show all available IP addresses in
verbose mode
http://code.google.com/p/pyftpdlib/issues/detail?id=276

Closing this out as won't fix as it's something which shouldn't be handled
by pyftpdlib.
Reply all
Reply to author
Forward
0 new messages