added validation of IP segments to make sure they aren't empty, e.g. 127.0..1
-Derek
diff --git a/system/libraries/Input.php b/system/libraries/Input.php
index f558e91..fae188e 100644
--- a/system/libraries/Input.php
+++ b/system/libraries/Input.php
@@ -413,7 +413,7 @@
{
// IP segments must be digits and can not be
// longer than 3 digits or greater then 255
- if (preg_match("/[^0-9]/", $segment) OR $segment > 255 OR strlen($segment) > 3)
+ if ($segment == '' OR preg_match("/[^0-9]/", $segment) OR $segment > 255 OR strlen($segment) > 3)
{
return FALSE;
}
diff --git a/user_guide/changelog.html b/user_guide/changelog.html
index 1d36191..4f05cf2 100644
--- a/user_guide/changelog.html
+++ b/user_guide/changelog.html
@@ -141,6 +141,7 @@
<li>Fixed DB_driver bug (4900), in which a database error was not being logged correctly.</li>
<li>Fixed DB backup bug in which field names were not being escaped.</li>
<li>Fixed a spelling error in a Loader error message.</li>
+ <li>Fixed a bug (5050) with IP validation with empty segments.</li>
</ul>
<h2>Version 1.6.3</h2>