----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/49131/#review139222 -----------------------------------------------------------
Patch looks great! Reviews applied: [49131] Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; ./support/docker_build.sh - Mesos ReviewBot On June 23, 2016, 4:38 a.m., Greg Mann wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/49131/ > ----------------------------------------------------------- > > (Updated June 23, 2016, 4:38 a.m.) > > > Review request for mesos, Adam B and Vinod Kone. > > > Bugs: MESOS-5685 > https://issues.apache.org/jira/browse/MESOS-5685 > > > Repository: mesos > > > Description > ------- > > The `FilesProcess` stores an authorization callback > for every virtual path. If no callback is found when > authorizing a request, then it is assumed that path > is not authorizable, so the request is approved. > This led to a bug in which the callbacks for paths > with trailing slashes were not correctly identified, > leading to requests being incorrectly authorized. > > This patch modifies the '/files/read' and > '/files/download' endpoints to refuse requests for > paths which contain trailing slashes, since these > endpoints don't accept paths of directories. > > > Diffs > ----- > > src/files/files.cpp 20bc6fa0c22ab017c4e23a745c313a3caf0aec36 > src/tests/files_tests.cpp b8f4f3c25cdde2322f16b4699b3362db29aee989 > > Diff: https://reviews.apache.org/r/49131/diff/ > > > Testing > ------- > > `make check` on OSX > > Additional checks were added to the FilesTests to ensure that trailing > slashes are handled properly - i.e., either invalidated when appropriate, or > accepted and then authorized correctly otherwise. > > > Thanks, > > Greg Mann > >
