Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-20941

[Public API] Image uploading validation not working as expected

    Details

    • Type: Bug Bug
    • Status: Confirmed
    • Priority: High High
    • Resolution: Unresolved
    • Affects Version/s: 5.1, 5.2-dev
    • Fix Version/s: QA tracked issues
    • Labels:
    • Environment:

      Server OS: Red Hat 6.4
      PHP: 5.3.3
      Database: MySQL 5.1.61
      Browser: Firefox 20

      Description

      Uploading a file to an image field in public api, with a size bigger than what it is allowed to on the class is possible, and it shouldn't be, also, it uploads any kind of file (tested with txt file).

      Steps to reproduce:
      (with public api)
      1 - create a class:
          Name: Image Class
          Identifier: image_class
          Add 'ezstring' field:
              Name: Name
              Identifier: name
          Add 'ezimage' field:
              Name: Image
              Identifier: image
              Max File Size: 1024 * 1024 (1MB)
      2 - create "Image Class" object
          Upload a non image file >1MB
      3 - Verify no error nor exception is displayed
      

        Activity

        Hide
        Marcos Loureiro (Inactive) added a comment -

        Changing title and description since it's not only the size that it's not correctly validated but also file type.

        Show
        Marcos Loureiro (Inactive) added a comment - Changing title and description since it's not only the size that it's not correctly validated but also file type.

          People

          • Assignee:
            Unassigned
            Reporter:
            Marcos Loureiro (Inactive)
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated: