# Deploy the browser extension

## Overview

Administrators can push the WALLIX Vault Password Manager extension to every managed browser and pre-configure its vault URL, so users only have to sign in. Two browser policies do this:

- an **install policy** that force-installs the extension;
- an **extension policy** (managed storage) that gives the extension the address of your vault.

Without the second policy, a user configures the extension by hand: from the web vault (**Browser extension setup** &gt; **Install and configure**) or by picking the vault in the extension's login page.

**Before you start, you need:**

- your vault URL, as shown in the address bar of your web vault, without any path: for example `https://vault-acme.trustelem.com`;
- an endpoint management tool: Group Policy (Windows), an MDM that deploys configuration profiles (macOS), or a tool that copies files to `/etc` (Linux);
- the policy templates of each browser you deploy: [Chrome Enterprise bundle](https://chromeenterprise.google/browser/download/), [Microsoft Edge policy files](https://www.microsoft.com/edge/business/download), [Firefox policy templates](https://github.com/mozilla/policy-templates/releases).

## Pre-configure the vault URL

The extension reads one setting from its managed storage: `environment` &gt; `base`, set to your vault URL. This setting is optional. Only `base` is needed, because the extension derives every other address from it.

```json
{
  "environment": {
    "base": "https://vault-acme.trustelem.com"
  }
}

```

Each browser delivers this setting through its own channel, called *3rdparty* extension policies. The sections below give the exact location per browser and platform.

**Limits to know before deploying:**

- The setting is applied **once, when the extension is first installed**. It must be in place before the extension installs, so deploy the vault URL policy together with, or before, the install policy.
- An extension that is already installed ignores a setting deployed later. To apply it, remove the extension and let the policy install it again, or have the user run **Install and configure** from the web vault.
- Changing the setting later does not move existing installations to the new URL. Use the same reinstall procedure.
- The value has no trailing slash and no path: `https://vault-acme.trustelem.com`, not `https://vault-acme.trustelem.com/#/vault`.

## Windows (Group Policy)

On Windows, one GPO per browser installs the extension through the browser's ADMX template, and a registry preference in the same GPO sets the vault URL. Replace `https://vault-acme.trustelem.com` with your vault URL in every step.

### Google Chrome

1. Copy `chrome.admx` to `C:\Windows\PolicyDefinitions` and `chrome.adml` to `C:\Windows\PolicyDefinitions\en-US` (from the `Configuration\admx` folder of the Chrome Enterprise bundle). In a domain, copy them to the Central Store instead.
2. In Group Policy Management, create a GPO and edit it.
3. Go to **Computer Configuration** &gt; **Policies** &gt; **Administrative Templates** &gt; **Google Chrome** &gt; **Extensions**.
4. Enable **Configure the list of force-installed apps and extensions**, click **Show** and add: `dofghbjbdjaclaeofhnnlognkapkpifl;https://clients2.google.com/service/update2/crx`
5. Go to **Computer Configuration** &gt; **Preferences** &gt; **Windows Settings** &gt; **Registry** and add a **New** &gt; **Registry Item**: 
    - Action: **Update**, Hive: **HKEY\_LOCAL\_MACHINE**
    - Key Path: `SOFTWARE\Policies\Google\Chrome\3rdparty\extensions\dofghbjbdjaclaeofhnnlognkapkpifl\policy\environment`
    - Value name: `base`, Value type: **REG\_SZ**, Value data: `https://vault-acme.trustelem.com`
6. Recommended: under **Google Chrome** &gt; **Password manager**, set **Enable saving passwords to the password manager** to **Disabled**.
7. Link the GPO to the target organizational units.

### Microsoft Edge

1. Copy `msedge.admx` to `C:\Windows\PolicyDefinitions` and `msedge.adml` to `C:\Windows\PolicyDefinitions\en-US` (from the `windows\admx` folder of the Edge policy files).
2. Create a GPO and edit it.
3. Go to **Computer Configuration** &gt; **Policies** &gt; **Administrative Templates** &gt; **Microsoft Edge** &gt; **Extensions**.
4. Enable **Control which extensions are installed silently**, click **Show** and add: `cecilbafjkhkhncmipkcmadckcpfnkeb;https://edge.microsoft.com/extensionwebstorebase/v1/crx`
5. Add a registry preference as for Chrome, with: 
    - Key Path: `SOFTWARE\Policies\Microsoft\Edge\3rdparty\extensions\cecilbafjkhkhncmipkcmadckcpfnkeb\policy\environment`
    - Value name: `base`, Value type: **REG\_SZ**, Value data: `https://vault-acme.trustelem.com`
6. Recommended: under **Microsoft Edge** &gt; **Password manager and protection**, set **Enable saving passwords to the password manager** to **Disabled**.
7. Link the GPO.

### Mozilla Firefox

1. Copy `firefox.admx` to `C:\Windows\PolicyDefinitions` and `firefox.adml` to `C:\Windows\PolicyDefinitions\en-US` (from the `windows` folder of the Firefox policy templates).
2. Create a GPO and edit it.
3. Go to **Computer Configuration** &gt; **Policies** &gt; **Administrative Templates** &gt; **Firefox** &gt; **Extensions**.
4. Enable **Extension Management** and enter, on one line: `{"{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}": {"installation_mode": "force_installed", "install_url": "https://dl.trustelem.com/wallix-vault/plugins/firefox/wallix_enterprisevault-latest.xpi"}}`
5. Add a registry preference with: 
    - Key Path: `SOFTWARE\Policies\Mozilla\Firefox\3rdparty\Extensions\{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}\environment`
    - Value name: `base`, Value type: **REG\_SZ**, Value data: `https://vault-acme.trustelem.com`
6. Recommended: under **Firefox**, disable **Offer to save logins** and **Offer to save logins (default)**.
7. Link the GPO.

### Registry file for tests

To try the vault URL setting on a single machine before writing the GPO, import this file as an administrator, then install the extension:

```
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Google\Chrome\3rdparty\extensions\dofghbjbdjaclaeofhnnlognkapkpifl\policy\environment]
"base"="https://vault-acme.trustelem.com"

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\3rdparty\extensions\cecilbafjkhkhncmipkcmadckcpfnkeb\policy\environment]
"base"="https://vault-acme.trustelem.com"

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Mozilla\Firefox\3rdparty\Extensions\{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}\environment]
"base"="https://vault-acme.trustelem.com"

```

## macOS (configuration profiles)

On macOS, deploy one configuration profile per browser through your MDM. Each profile holds two custom-settings payloads: one in the browser's domain for the install, one in the extension's domain for the vault URL.

<table id="bkmrk-browser-install-payl"><thead><tr><th>Browser</th><th>Install payload domain</th><th>Vault URL payload domain</th></tr></thead><tbody><tr><td>Google Chrome</td><td>`com.google.Chrome`</td><td>`com.google.Chrome.extensions.dofghbjbdjaclaeofhnnlognkapkpifl`</td></tr><tr><td>Microsoft Edge</td><td>`com.microsoft.Edge`</td><td>`com.microsoft.Edge.extensions.cecilbafjkhkhncmipkcmadckcpfnkeb`</td></tr><tr><td>Mozilla Firefox</td><td>`org.mozilla.firefox`</td><td>Same domain, under `3rdparty`</td></tr></tbody></table>

**Install payload, Chrome** (Edge: same with the Edge ID and update URL):

```xml
<key>ExtensionSettings</key>
<dict>
  <key>dofghbjbdjaclaeofhnnlognkapkpifl</key>
  <dict>
    <key>installation_mode</key>
    <string>force_installed</string>
    <key>update_url</key>
    <string>https://clients2.google.com/service/update2/crx</string>
  </dict>
</dict>
<key>PasswordManagerEnabled</key>
<false/>

```

**Vault URL payload, Chrome and Edge:**

```xml
<key>environment</key>
<dict>
  <key>base</key>
  <string>https://vault-acme.trustelem.com</string>
</dict>

```

**Firefox payload** (`org.mozilla.firefox`, install and vault URL together):

```xml
<key>EnterprisePoliciesEnabled</key>
<true/>
<key>ExtensionSettings</key>
<dict>
  <key>{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}</key>
  <dict>
    <key>installation_mode</key>
    <string>force_installed</string>
    <key>install_url</key>
    <string>https://dl.trustelem.com/wallix-vault/plugins/firefox/wallix_enterprisevault-latest.xpi</string>
  </dict>
</dict>
<key>3rdparty</key>
<dict>
  <key>Extensions</key>
  <dict>
    <key>{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}</key>
    <dict>
      <key>environment</key>
      <dict>
        <key>base</key>
        <string>https://vault-acme.trustelem.com</string>
      </dict>
    </dict>
  </dict>
</dict>
<key>PasswordManagerEnabled</key>
<false/>

```

## Linux (policy files)

On Linux, copy one JSON policy file per browser to the machines. The directory must be writable by root only (`chmod 755` on the directories, `644` on the file).

<table id="bkmrk-browser-policy-file-"><thead><tr><th>Browser</th><th>Policy file</th></tr></thead><tbody><tr><td>Google Chrome</td><td>`/etc/opt/chrome/policies/managed/wallix-vault.json`</td></tr><tr><td>Microsoft Edge</td><td>`/etc/opt/edge/policies/managed/wallix-vault.json`</td></tr><tr><td>Mozilla Firefox</td><td>`/etc/firefox/policies/policies.json`</td></tr></tbody></table>

**Chrome** (Edge: same with the Edge ID and update URL):

```json
{
  "ExtensionSettings": {
    "dofghbjbdjaclaeofhnnlognkapkpifl": {
      "installation_mode": "force_installed",
      "update_url": "https://clients2.google.com/service/update2/crx"
    }
  },
  "PasswordManagerEnabled": false,
  "3rdparty": {
    "extensions": {
      "dofghbjbdjaclaeofhnnlognkapkpifl": {
        "environment": {
          "base": "https://vault-acme.trustelem.com"
        }
      }
    }
  }
}

```

**Firefox** (`Extensions` takes a capital E here; Chrome and Edge use `extensions`):

```json
{
  "policies": {
    "ExtensionSettings": {
      "{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}": {
        "installation_mode": "force_installed",
        "install_url": "https://dl.trustelem.com/wallix-vault/plugins/firefox/wallix_enterprisevault-latest.xpi"
      }
    },
    "PasswordManagerEnabled": false,
    "3rdparty": {
      "Extensions": {
        "{73ad1dc7-ed8a-4610-a0af-957cfcb676a3}": {
          "environment": {
            "base": "https://vault-acme.trustelem.com"
          }
        }
      }
    }
  }
}

```

## Verify the deployment

On a target machine, after the policy refresh (`gpupdate /force` on Windows) and a browser restart:

1. Open the browser's policy page: `chrome://policy`, `edge://policy` or `about:policies`. The install policy is listed. For Chrome and Edge, the vault URL appears under the WALLIX Vault Password Manager extension with no error; for Firefox, under `3rdparty`.
2. The extension icon is in the toolbar and the extension cannot be removed by the user.
3. Open the extension: its login page shows the single sign-on button enabled, and signing in opens your Trustelem login page.

<table id="bkmrk-symptom-cause-and-fi"><thead><tr><th>Symptom</th><th>Cause and fix</th></tr></thead><tbody><tr><td>The sign-on button stays disabled</td><td>The extension was installed before the vault URL policy. Remove the extension (or the user profile's copy) and let the policy reinstall it.</td></tr><tr><td>The policy page shows a validation error on `environment`</td><td>`base` is not a string, or it was created as a value instead of under the `environment` key. Check the key path.</td></tr><tr><td>The extension points to an old vault URL</td><td>The setting applies at first install only. Reinstall the extension.</td></tr><tr><td>Firefox does not install the extension</td><td>Check that `about:policies` lists `ExtensionSettings` with no error and that the machine can reach `dl.trustelem.com`.</td></tr></tbody></table>