Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-9297

Add support for Extended Passive Mode (EPSV) in class ftp_fsock to better support IPv6 connections.

    Details

    • Type: Improvement
    • Status: Unverified Fix
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.x
    • Fix Version/s: 3.0.10-RC1
    • Component/s: Other
    • Labels:
      None

      Description

      		// open the connection to start sending the file
      		if (!preg_match('#[0-9]{1,3},[0-9]{1,3},[0-9]{1,3},[0-9]{1,3},[0-9]+,[0-9]+#', $ip_port, $temp))

      From line 738 of functions_transfer.php

      This regex will only match an IPv4 address. The other portions of phpBB support IPv6 addresses.

      This looks like a complicated fix due to the way the port number is tacked onto the IP address. Maybe the port could be prepended instead of appended to keep it relatively simple.

        Activity

        Hide
        naderman Nils Adermann added a comment - - edited

        Unfortunately PASV is only designed for IPv4, as defined in older versions of the FTP. If we wanted to add IPv6 support (I think we should) we would need to use EPRT/EPSV. Information on this can be found in RFC 2428.

        Show
        naderman Nils Adermann added a comment - - edited Unfortunately PASV is only designed for IPv4, as defined in older versions of the FTP. If we wanted to add IPv6 support (I think we should) we would need to use EPRT/EPSV. Information on this can be found in RFC 2428 .

          People

          • Assignee:
            bantu Andreas Fischer
            Reporter:
            A_Jelly_Doughnut A_Jelly_Doughnut
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development