Skip to main content

setting authentication for embedded derby

1 reply [Last post]
aaronanderson
Offline
Joined: 2004-01-23

I am trying to enable authentication for the embedded derby framework and change the default app user password. I have tried to create a derby.properties in the glassfish/derby, the logical location of derby.system.home, containing the following entries:

derby.connection.requireAuthentication=true
derby.authentication.provider=BUILTIN
derby.user.testuser=test

However, running the frameworks/NetworkServer/bin/ij.ksh command and then running
connect 'jdbc:derby://localhost:1527//tmp/TestDB;create=true;user=testuser;password=test;';

works and I do not get an authentication error. Where should I place the derby.properties so it gets read? Also, to change the APP password can I simply set
derby.user.APP=newpassword ?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
aaronanderson
Offline
Joined: 2004-01-23

had to run glassfish/bin/asadmin start-database --dbhome=/opt/glassfish/derby and it picked up. Perhaps this option could be listed in the usage-text in the CLIDescriptor.xml for the start-database command. Also changed the APP password using method in my original post.