There are two aspects to this bug:
When sample application setup scripts that use the Derby database are run, the Derby database gets created under the current directory or under <install_root>/bin.
The sample build Ant script creates a password.txt file that stores the admin password file under current directory, which will not be writable in non-root and sparse zones scenarios.