en.help.ref-editjdbcrealm.html Maven / Gradle / Ivy
Properties Specific to the JDBCRealm Class
To protect your web pages or web applications, you can set the
security so that only registered users can access them. This is known as
the authentication facility. This type of realm involves storing the credentials of your
users inside a database. The GlassFish Server uses the database information and the enabled
JDBC realm option inside the configuration file.
The following properties are required for a JDBC realm.
- JAAS Context
The JAAS (Java Authentication and Authorization Service) context (the identifier for the login module to use for this realm). The only valid value is jdbcRealm.
- JNDI
The JNDI name for this realm. The default value is jdbc/security.
- User Table
The table that contains a list of authorized users for this realm. The default value is usertable.
- User Name Column
The name of the column that contains the list of users inside the user table. The default value is userid.
- Password Column
The name of the column that contains the respective user's password in the user table. The default value is password.
- Group Table
The name of the group table in the database. The default value is grouptable.
- Group Name Column
The name of the group name column in the database's group table. The default value is groupid.
The following optional properties are available for a JDBC realm.
- Assign Groups
A comma-separated list of group names. All clients who present valid certificates are assigned to these groups, for example, employee,manager, where these are the names of user groups.
- Database User
Allows you to specify the database user name in the realm instead of the jdbc-connection-pool. This prevents other applications from looking up the database, getting a connection, and browsing the user table. By default, the jdbc-connection-pool configuration is used.
- Database Password
Allows you to specify the database password in the realm instead of the jdbc-connection-pool. This prevents other applications from looking up the database, getting a connection, and browsing the user table. By default, the jdbc-connection-pool configuration is used.
- Digest Algorithm
The digest algorithm. The default is MD5. You can use any algorithm supported in the JDK, or none.
- Encoding
The encoding. Allowed values are Hex and Base64. If digest-algorithm is specified, the default is Hex. If digest-algorithm is not specified, by default no encoding is specified.
- Charset
The charset for the digest algorithm.
Copyright © 2010, Oracle and/or its affiliates. All rights reserved. Legal Notices