When using a username/password token, first configure an appropriate realm and an appropriate user database for the realm.
Configuring a user database is discussed in To Edit a Realm.
Once the facilities of the GlassFish Server are configured for use by message security providers, the providers installed with the GlassFish Server may be enabled as described in To Edit a Message Security Configuration.