Securely save your authentication token and secret so you don’t need to re-enter credentials for each import or removal. This step is optional but recommended for repeat jobs and automation.
To perform imports or removals, an authentication token and a secret are required. You can encrypt and store these credentials to prevent exposing them in plain text and to avoid re-entering them for each run. This is especially useful when running the importer in the background (for example, in batch mode), because the import command can run without passing the token and secret as visible parameters.
NOTE: For details on generating tokens, refer to System > Application Tokens for Utility Access.
You can also specify a task identifier during this process. The task identifier allows the task to appear in the iManage Threat Manager console and is used as the default identifier for future queries unless changed.
Task: Save token and secret on Windows
On Windows, you can encrypt and store your token and secret under a Windows account to enable automatic authentication on future runs from the same device and account.
NOTE: The requirements.txt file is included in the iManage Threat Manager User Metadata Importer package that you download from iManage Help Center.
Open Command Prompt as an administrator.
Set the working directory by navigating to the folder that contains user-metadata-importer.exe.
Run the installation command appropriate for your environment and SSL configuration:
iManage Threat Manager in the Cloud or on-premises with a CA-signed certificate.
No certificate path required:user-metadata-importer.exe install -s https://<TM FQDN>:<REST_API_Port>Where:
<TM FQDN>is the fully-qualified domain name of your iManage Threat Manager instance.<REST_API_Port>is the REST API port number.
(On-premises) On-premises with a self-signed certificate.
Specify the SSL certificate path:user-metadata-importer.exe install -s https://<TM FQDN>:<REST_API_Port> --certificate <filepath to .pem file>Or use the shorthand -c option:
user-metadata-importer.exe install -s https://<TM FQDN>:<REST_API_Port> -c <filepath to .pem file>Where:
<TM FQDN>is the fully-qualified domain name of your iManage Threat Manager instance.<REST_API_Port>is the REST API port number.<filepath to .pem file>specifies the location of the certificate file.
(On-premises) Disable SSL (not recommended unless necessary).
user-metadata-importer.exe install -s https://<TM FQDN>:<REST_API_Port> --disable-sslWhere:
<TM FQDN>is the fully-qualified domain name of your iManage Threat Manager instance.<REST_API_Port>is the REST API port number.
NOTE: Disabling SSL overrides any previously specified certificate path.
Select the Windows account used to encrypt the token and secret. When prompted with “Would you like to install this service to run as a different Windows Account?"
Enter n to use the current Windows account.
Enter y to specify a different account, then provide:
The account
DOMAIN\userformat.The corresponding password.
IMPORTANT: The token and secret can only be decrypted by the Windows account used during encryption.
You can still override this behavior by supplying the token and secret directly as arguments during an import. For details, refer to Task: Import the prepared data.
Enter the token and then the secret. The application encrypts and stores these credentials for future use. Only the selected Windows account can decrypt them.
(Optional) Enter a task identifier (up to 32 characters) or press Enter to skip.
A task identifier enables:Status reporting in the Threat Manager user console (Configuration > Settings > Status).
Email alerts about import activity.
Independent tracking of last import times across multiple imports.
NOTE: If no task identifier is specified, you can include one later in import commands. For more information, refer to Importing metadata and Removing metadata or accidental user imports.
After installation, the application is ready to:
Task: Save token and secret on macOS or Linux
On macOS and Linux, you can encrypt and store credentials using an auto-generated or custom key so you can run imports without re-entering your token and secret.
During this process, you enter the token and secret for encryption. iManage Threat Manager can automatically generate the encryption key and initialization vector. If you prefer to provide your own, specify them in the importer-config.ini file as shown below:
[authentication]encryption_key = <key-here>encryption_iv = <iv-here>IMPORTANT: For security, ensure this file has restricted read/write permissions.
A manual override is still possible by supplying token and secret arguments directly during import. Refer to Task: Import the prepared data.
To save the token and secret on macOS or Linux:
Open the terminal.
Install the importer:
If Python 2 is not installed:
python custom_import_properties.py installIf Python 2 is installed:
python3 custom_import_properties.py install
When prompted, enter:
Your token.
Your secret.
(Optional) A task identifier (up to 32 characters), or press Enter to skip.
The task identifier is used to:Display status in the Threat Manager user console (Configuration > Settings > Status).
Send email alerts.
Track multiple imports independently.
NOTE: You can add a task identifier to future import commands, if needed. For details, refer to Importing metadata and Removing metadata or accidental user imports.
The application is now ready to import metadata, remove metadata or users, or remove task identifiers.