[jira] Updated: (MAPREDUCE-1418) LinuxTaskController binary misses validation of arguments passed for relative components in some cases.

2010-04-06 Thread Hemanth Yamijala (JIRA)

 [ 
https://issues.apache.org/jira/browse/MAPREDUCE-1418?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Hemanth Yamijala updated MAPREDUCE-1418:


Attachment: MAPREDUCE-1418-y20s.patch

The attached patch [MAPREDUCE-1418-y20s.patch] is a similar patch to the one 
against trunk for earlier versions of Hadoop. In this patch, I've addressed the 
problem related to validating relative paths in job log directory 
initialization, as well as Amareshwari's comment about return code in 
prepare_task_logs. The trunk patch will have similar changes. All 
LinuxTaskController tests pass with this patch. I would appreciate a review.

This patch is not for commit to Apache SVN.

 LinuxTaskController binary misses validation of arguments passed for relative 
 components in some cases.
 ---

 Key: MAPREDUCE-1418
 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1418
 Project: Hadoop Map/Reduce
  Issue Type: Bug
  Components: security, tasktracker
Reporter: Vinod K V
Assignee: Hemanth Yamijala
 Attachments: MAPREDUCE-1418-y20s.patch, MAPREDUCE-1418.patch


 The function {{int check_path_for_relative_components(char * path)}} should 
 be used to validate the absence of relative components before any operation 
 is done on those paths. This is missed in all the {{initialize*()}} 
 functions, as Hemanth pointed out offline.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Updated: (MAPREDUCE-1418) LinuxTaskController binary misses validation of arguments passed for relative components in some cases.

2010-03-15 Thread Hemanth Yamijala (JIRA)

 [ 
https://issues.apache.org/jira/browse/MAPREDUCE-1418?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Hemanth Yamijala updated MAPREDUCE-1418:


Attachment: MAPREDUCE-1418.patch

Attaching a patch implementing the changes.

Details:

- Fixed all the initialization calls (for user, job, task, log and distributed 
cache files) to call check_path_for_relative_components.
- Modified the way in which error code was tracked and handled in the methods 
so I could return a relevant error code when relative components are found.
- Added tests for all the conditions. For testing initialization of job, task 
and distributed cache, the approach followed is that we create the original 
directories and some dummy directories. Then we launch the task controller exe 
with some of the arguments tweaked to have relative components. We verify the 
call fails with an ExitCodeException with the right error code. For user and 
log initialization, I write a taskcontroller.cfg with relative paths in mapred 
local directories and hadoop.log.dir and verify the same failures. The latter 
approach is needed because passing relative paths in the command line arguments 
will not trigger the code path we want to exercise in these two cases.

All task-controller tests are passing with this patch, as also test-patch.

 LinuxTaskController binary misses validation of arguments passed for relative 
 components in some cases.
 ---

 Key: MAPREDUCE-1418
 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1418
 Project: Hadoop Map/Reduce
  Issue Type: Bug
  Components: security, tasktracker
Reporter: Vinod K V
Assignee: Hemanth Yamijala
 Attachments: MAPREDUCE-1418.patch


 The function {{int check_path_for_relative_components(char * path)}} should 
 be used to validate the absence of relative components before any operation 
 is done on those paths. This is missed in all the {{initialize*()}} 
 functions, as Hemanth pointed out offline.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.