> **Experimental**
>
> `@aws-cdk/aws-elasticache-alpha` is an [**experimental**](/stability) (alpha) package: its API may change in any release, without a major version bump.
# AccessControl

Access control configuration for ElastiCache users.

- Stability: [Experimental](/cdk/api/stability.html)
- Source: [`lib/user-base.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0-alpha.0/packages/@aws-cdk/aws-elasticache-alpha/lib/user-base.ts#L10)

## Example

```ts
const user = new elasticache.IamUser(this, 'User', {
  // set user engine
  engine: elasticache.UserEngine.REDIS,

  // set user id
  userId: 'my-user',

  // set username
  userName: 'my-user',

  // set access string
  accessControl: elasticache.AccessControl.fromAccessString("on ~* +@all"),
});
```

## Initializer

```ts
new AccessControl()
```

## Properties

- `accessString`: string (required) — The access string that defines user's permissions.

## Methods

- `fromAccessString(accessString: string): AccessControl // chainable` (static) — Create access control from an access string.

  **Parameters**

  - `accessString` — The access string defining user permissions.
