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

Missing strlen() on $table_prefix in db tools index name length check

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • 3.0.9
    • 3.0.10-RC1
    • None
    • None

    Description

      		$table_prefix = substr(CONFIG_TABLE, 0, -6); // strlen(config)
      		if (strlen($table_name . $index_name) - strlen($table_prefix) > 24)
      		{
      			$max_length = $table_prefix + 24;
      			trigger_error("Index name '{$table_name}_$index_name' on table '$table_name' is too long. The maximum is $max_length characters.", E_USER_ERROR);
      		}

      $max_length = $table_prefix + 24;

      Should be strlen($table_prefix) here.

      Attachments

        Issue Links

          Activity

            People

              bantu Andreas Fischer [X] (Inactive)
              bantu Andreas Fischer [X] (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: