Zend Framework

Zend_Validate_Ip - IPv6 regex may allow newlines

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 1.10.0
  • Component/s: Zend_Validate
  • Labels:
    None

Description

In some circumstances, the IPv6 regexes may allow a newline after the IP:

require_once 'Zend/Validate/Ip.php';
$v = new Zend_Validate_Ip;
var_dump($v->isValid("::C0A8:2\n")); // TRUE

Activity

Hide
Pádraic Brady added a comment -

This won't work on any IPv6 IP which can parsed back to IPv4.

Show
Pádraic Brady added a comment - This won't work on any IPv6 IP which can parsed back to IPv4.
Hide
Thomas Weidner added a comment -

Fixed with r19949

Show
Thomas Weidner added a comment - Fixed with r19949

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: