Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2008 BEA Systems, Inc. All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.p13n.controls.securityProvider
Interface UserProviderControl

All Superinterfaces
  Serializable

    @ControlInterface
    public interface UserProviderControl

extends Serializable

This control:

- is used as an interface to the Portal security provider functionality that is specific to users.

Control properties:

- atnProvider The name of the authentication provider to perform these operations on. If not configured, the authentication provider named "SQLAuthenticator" will be used, since it is the default authentication provider for portal domain.
- saveAnonymous Whether to save anonymous user properties to new user's profile when the user is created. Default: `true`
- login Whether to login as the new created user. Default: `true`
- fireEvent Whether to fire a `UserRegistrationEvent` when the user is created. Default: `true`
- doPostProcess Whether to do the post-user-creation process. Post process includes bind new user's profile to session or request, optional transfer anonymous user properties into new user's profile, optional login as new created user, and optional fire `UserRegistrationEvent`. If any of the "saveAnonymous", "login", or "fireEvent" control property is set to `true`. This property will implicitly set to `true` Default: `true`

Security requirements: To invoke these methods, the caller must be in a role that has been granted appropriate permission in the WebLogic Administration Portal Authentication Security Provider Service.

Nested Class Summary
`static interface` | `UserProviderControl.UserProviderParams` Define the properties for this control.

Method Summary
`void` | `createUser(String username, String password, javax.servlet.http.HttpServletRequest request)` Creates a user with the given username and password.
`void` | `createUserSimple(String username, String password)` Creates a user with the given username and password.
`List` | `getUserNames(String searchExpression, int limit)` Get a list of all user names
`void` | `removeUser(String username)` Removes a user from the specified authentication provider.
`void` | `setPassword(String username, String password)` Sets the password for a user in the realm.
`boolean` | `userExists(String username)` Determine whether a user exists

Method Detail

### userExists

    boolean userExists(String username)
                       throws OperationNotSupportedException

  Determine whether a user exists

  Parameters
    `username` - The user (login) name of the user
  Returns
    true if the user exists, false if cannot find user of this name
  Throws
    `OperationNotSupportedException` - if authentication provider implementation does not support this operation

### getUserNames

    List getUserNames(String searchExpression,
                      int limit)
                      throws OperationNotSupportedException

  Get a list of all user names

  Parameters
    `searchExpression` - a wildcard search expression
    `limit` - a limit of results to return
  Returns
    a List of all user names matching the search expression
  Throws
    `OperationNotSupportedException` - if authentication provider implementation does not support this operation

### createUser

    void createUser(String username,
                    String password,
                    javax.servlet.http.HttpServletRequest request)
                    throws UserAlreadyExistsException,
                           InvalidUsernameException,
                           LoginException,
                           InvalidPasswordException,
                           OperationNotSupportedException

  Creates a user with the given username and password.

  Parameters
    `username` - The user's login name
    `password` - The user's password
    `request` - the http request
  Throws
    `InvalidUsernameException` - if the username is malformed or otherwise invalid
    `InvalidPasswordException` - if the password is malformed or otherwise invalid
    `UserAlreadyExistsException` - if the username is already in use
    `LoginException` - if "login" flag is on, and login failed
    `OperationNotSupportedException` - if authentication provider implementation does not support this operation

### createUserSimple

    void createUserSimple(String username,
                          String password)
                          throws UserAlreadyExistsException,
                                 InvalidUsernameException,
                                 InvalidPasswordException,
                                 OperationNotSupportedException

  Creates a user with the given username and password. Use this API if you don't care to do any post-processing on the user, nor perform any of the tasks described by the control property settings. Those properties will all be ignored and the user created with no further action.

  Parameters
    `username` - The user's login name
    `password` - The user's password
  Throws
    `InvalidPasswordException` - if the password is malformed or otherwise invalid
    `InvalidUsernameException` - if the username is malformed or otherwise invalid
    `UserAlreadyExistsException` - if the username is already in use
    `OperationNotSupportedException` - if authentication provider implementation does not support this operation

### removeUser

    void removeUser(String username)
                    throws InvalidUsernameException,
                           OperationNotSupportedException

  Removes a user from the specified authentication provider. This will not remove profile records for this user. Security constraints should restrict use of this method to administrators only.

  Parameters
    `username` - the username of the user to remove
  Throws
    `InvalidUsernameException` - if the user is protected and cannot be deleted
    `OperationNotSupportedException` - if authentication provider implementation does not support this operation

### setPassword

    void setPassword(String username,
                     String password)
                     throws InvalidPasswordException,
                            OperationNotSupportedException

  Sets the password for a user in the realm. Security constraints should restrict use of this method to administrators only.

  Parameters
    `username` - the username of the user
    `password` - the new password for the user
  Throws
    `InvalidPasswordException` - if the password is malformed or otherwise invalid
    `OperationNotSupportedException` - if authentication provider implementation does not support this operation

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008 BEA Systems, Inc. All Rights Reserved