Password salt with a database realm

Posted on

I would like to set up a database security realm as it is described here:

I would like to store passwords that are hashed + salt.

Ideally password values in the database would look something like this "hashed password:salt".

I'm pretty sure I need to provide an implementation of either digestCallback or storeDigestCallback... I'm not clear on how to implement either one of these things or where to place the implementation such that it is on the classpath for the realm implementation.

Is there any additional documentation available? Or maybe an example configuration I could look at?