Fixes to three issues

1. Creating a new directory - should allow creating files with read and write permissions.
2. When creating a file, if a user is allowed to type in content, that should be saved too.
3. User should not be allowed to access beyond application's root directory.