---
title: "Manage secure properties with ACLI actions"
canonical: "https://support.appfire.com/space/ACLI/1314455553/Manage%20secure%20properties%20with%20ACLI%20actions"
format: markdown
---
> Macro (aura-html)

Use ACLI actions, which are part of the `system` client, to manage key-value pairs stored securely in the secure properties file.

To use a secure property in **acli.properties**, follow this example:

```
my-jira = jiracloud -s https://myjira.atlassian.net -u me@example.com -t ${secret:my-jira.token}
```

## Actions and examples

Below you can find examples of working with secure properties.

### setSecureProperty

This action sets or updates a secure property in the secure properties file. If the property name already exists, you must confirm overwriting the value. 

To skip this prompt, use `--replace`.

#### Example: Set secure property

```
$ acli system -a setSecureProperty --name my-jira.token --secret
Enter secure properties password: <password prompt>
Value for key 'my-jira.token' set in secure properties file.
```

### getSecureProperty

This action retrieves a secure property from the secure properties file. By default, it only confirms whether the named entry exists. 

To retrieve the property value, use `--outputFormat 2`.

#### Example: Get secure property

```
$ acli system -a getSecureProperty --name foo
Enter secure properties password: <password prompt>
Secure property 'foo' exists in the secure properties file
```

#### Example: Get a secure property with value

```
$ acli system -a getSecureProperty --name foo --outputFormat 2
Enter secure properties password: <password prompt>
Value of secure property 'foo': bar
```

### removeSecureProperty

This action deletes a secure property from the secure properties file. Confirmation is required to prevent accidental removal. 

To remove the property without confirmation, add `--force`.

If the secure properties file is empty after this, it's automatically deleted.

#### Example: Remove a secure property

```
$ acli system -a removeSecureProperty --name my-jira.token
Enter secure properties password: <password prompt>
Enter CONFIRM to permanently remove the secure property 'my-jira.token': CONFIRM
Removed value for key 'my-jira.token' from secure properties file.
```

#### Example: Force remove a secure property (with deletion of the secure properties file)

```
$ acli system -a removeSecureProperty --name my-jira.token --force
Enter secure properties password: <password prompt>
Removed value for key 'my-jira.token' from secure properties file.
Deleted empty keystore file.
```

### getSecurePropertyList

This action retrieves all secure properties from the secure properties file. 

To include property values, use `--outputFormat 2`.

#### Example: Get a secure property list

```
$ acli system -a getSecurePropertyList
Enter secure properties password: <password prompt>
2 secure properties in list
"Name"
"buz"
"foo"
```

#### Example: Get a secure property list with values

```
$ acli system -a getSecurePropertyList --outputFormat 2
Enter secure properties password: <password prompt>
2 secure properties in list
"Name","Value"
"buz","qux"
"foo","bar"
```

### clearSecureProperties

This action clears the entire secure properties file. Confirmation is required to prevent accidental removal of values. 

Add the `--``force` parameter to delete the secure property file without confirmation. To complete the action, you are prompted to enter the secure properties file password.

**Warning:** If you forget the password, you must manually rename or delete the secure properties file (named **.acli.keystore**) in your home directory. 

It's recommended to rename the file instead of deleting it if you might recall the password later and still need the file's contents.

#### Example: Clear all secure properties

```
$ acli system -a clearSecureProperties
Enter secure properties password: <password prompt>
Enter CONFIRM to permanently clear all secure properties (CANNOT be undone): CONFIRM
Secure properties cleared.
```

### importSecureProperties

This action lets you import secure properties from another secure properties file into your default secure properties file. For this purpose, you need the passwords for both the source and destination secure properties files.

Two options are available:

- use the `--replace` parameter to avoid confirmation prompts for overwriting properties during import,
- use the `--include` and `--exclude` parameters to filter the imported properties.

> 📝 The `--include` and `--exclude` parameters take regular expressions as values and are evaluated against the list of keys in the source secure properties file.

> ⚠️ While this can be useful for sharing selected secure properties, do not store or transmit the secure properties file password with the file.

The following examples assume both **.acli.keystore **and **import.keystore** contain entries for the `foo` and `bar`  keys.

#### Example: Import secure properties

```
$ acli system -a importSecureProperties -f import.keystore
Enter secure properties password: <destination password prompt>
Enter inbound secure properties password: <source password prompt>
Imported 0 secure properties.
Ignored: buz,foo. Use --replace to overwrite existing values.
```

#### Example: Import select secure properties (via inclusion) with replacement

```
$ acli system -a importSecureProperties -f import.keystore --include '(?i)^F' --replace
Enter secure properties password: <destination password prompt>
Enter inbound secure properties password: <source password prompt>
Imported 1 secure property: foo.
```

### exportSecureProperties

This action lets you export secure properties from your default secure properties file to another secure properties file. For this purpose, you need the password for both the source and destination secure properties files.

Two options are available:

- use the `--replace` parameter to avoid confirmation prompts when overwriting properties during export,
- use the` --include` and `--exclude `parameters to filter the exported properties.

> 📝 The `--include` and `--exclude` parameters take regular expressions as values and are evaluated against the list of keys in the source secure properties file.

#### Example: Export selected secure properties (using exclusion) with replacement

```
$ acli system -a exportSecureProperties -f export.keystore --exclude '(?i)^F' --replace
Enter secure properties password: <source password prompt>
Enter outbound secure properties password: <destination password prompt>
Exported 1 secure property: buz.
```

### Locating your secure properties file

Your secure properties file is typically located in your home directory and named **.acli.keystore**. ACLI displays the file path as part of the detailed `getClientInfo` output (if it exists).

#### Example: Display the secure properties file path

```
$ acli -a getClientInfo --outputFormat 2
Enter secure properties password:<password prompt>
Client information
Client name . . . . . . . . . : cli
Client version  . . . . . . . : 11.0.0
...
Secure properties . . . . . . :
  File  . . . . . . . . . . . : /Users/me/.acli.keystore
```