Skip to content

Executor.executeSystemCommand has an invalid path comparison and throws exception #13

@meg23

Description

@meg23

From [email protected] on April 07, 2008 13:54:54

What steps will reproduce the problem? 1. Windows XP Professional
2. Java 1.6 update 5
3. Eclipse 3.3
4. run JUnit "ALLTests" What is the expected output? What do you see instead? ExecutorTest.java gets an assertion failure due to an incorrect exception
thrown by Executor.executeSystemCommand. This method compares the
canonical path to the path supplied to the executable. It uses an "equals"
operation when an "equalsIgnoreCase" will produce the required results.

Canonical Path: C:\WINDOWS\system32\cmd.exe
Executable Path: C:\Windows\System32\cmd.exe
The following code is then executed: throw new ExecutorException
("Execution failure", "Invalid path to executable file: " + executable);

What version of the product are you using? ESAPI v1.1.1 Complete JAR file

On what operating system? Windows XP professional
Java 1.6 update 5 Please provide any additional information below.

Original issue: http://code.google.com/p/owasp-esapi-java/issues/detail?id=3

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions