Did you try setting the following properties in the respective databases:
derby.connection.requireAuthenticationas mentioned in the documentation at:
Hello EveryoneI have a rather annoying problem. I was wondering if anyone could provide sample code as to how I can restrict a user to a single database or basically a certain number of database. So for example user fred would only be allowed to access accounting and not sales.It seems to be that once a user gets database access he can login into any database but I want to restrict a user to a certain database. Thanks.