You can configure a SAM in one of these ways:
In the Administration Console, open the Security component under the relevant configuration and go to the Message Security page. Set the following options:
Authentication Layer — HttpServlet
Provider Type — server or client-server
Provider ID — Specify a unique name for the SAM, for example MySAM
Class Name — Specify the fully qualified class name, for example tip.sam.MySam
Additional Property — Name: group-name Value: user
Additional Property — Name: realm-name Value: Sam
For details, click the Help button in the Administration Console.
Use the asadmin create-message-security-provider command to configure a SAM. Set the following options:
----layer HttpServlet
----providertype server or ----providertype client-server
----classname tip.sam.MySam
----property group-name=user:realm-name=Sam
Provider name operand — Specify a unique name for the SAM, for example MySAM
For details, see the Oracle GlassFish Server 3.0.1 Reference Manual.