Wire mkdir and rmdir to go through MediaProvider

rmdir and mkdir now consult MediaProvider first to check if the app is
allowed to create/delete the given directory. This alone does not
guarantee we don't leak app info, because there are some edge cases in
which mkdir, rmdir would return ENOENT or EEXIST without going through
our implementation of mkdir/rmdir. More info in go/fuse-dir-filtering.

Add 1 test case to check that the basic restrictions on creating and
deleting directories are enforced. Also add another test case which
still needs to be implemented, where we delete a directory that has
files contributed by other apps and assert that only our files were
deleted from the directory.

Test: atest FuseDaemonTest
Test: atest --test-maping # in MediaProvider and without FUSE, to make sure PATTERN_OWNED_PATH change does't break anything
Test: manual test for rmdir that contains files contributed by other
apps
Bug: 144279561

Change-Id: I10384ace4d5555c70551fe439d9ed161457acc90
5 files changed