Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In addition to these specific issues, there are is a wide variety of operating system-specific and file system-specific naming conventions that make validation difficult.

...

Unfortunately the canonicalization is performed before after the validation, which renders the validation ineffective.

...

A comprehensive way of handling this issue is to grant the application the permissions to operate only on files present within the intended directory—the /img directory in this example. This compliant solution specifies the absolute path of the program in its security policy file and grants java.io.FilePermission with target /img/java and the read action.
This solution requires that the /img driectory directory is a secure directory, as described in FIO00-J. Do not operate on files in shared directories.

...

Related Guidelines

...

 

...

      Image RemovedRule 00: Input Validation and Data Sanitization (IDS)