SoftHSM is the software implementation of an HSM. It can be installed from the EPEL repository. The configuration of SoftHSM can be found at /etc/softhsm2.conf (CentOS 7), or /etc/softhsm.conf (CentOS 6).
The following describes how to configure SoftHSM.
|
NOTE:
Depending on the exact SoftHSM solution that you are using, the steps described here may slightly differ. |
|
NOTE:
The following steps assume that:
|
The indexer user/group has the rights to read the data directory of SoftHSM and its contents, which defaults to /var/lib/softhsm.
To configure SoftHSM
Initialize directories for SoftHSM.
mkdir -p /var/lib/softhsm chgrp -R indexer /var/lib/softhsm
Configure slots for softhsm1 (CentOS 6). For softhsm2 (CentOS 7), you can skip this step.
cat /etc/softhsm.conf 0:/var/lib/softhsm/slot0.db 1:/var/lib/softhsm/slot1.db
Initialize slot 0 (softhsm1).
softhsm --init-token --slot 0 --label "<your-slot-label>" –-<so-pin> topsecret --pin <your-SoftHSM-PIN>
Initialize a new slot (softhsm2) and get the slot ID:
softhsm2-util --init-token --free --label "<your-slot-label>" --<so-pin> topsecret --pin <your-SoftHSM-PIN> SLOT_ID=$(softhsm2-util --show-slots | grep -B 15 "<your-slot-label>" | grep "Slot [0-9]" | head -n 1 | cut -d ' ' -f 2)
Import your keys. Your keys must be in the .der format.
For softhsm1, use:
pkcs11-tool --module /usr/lib/softhsm/libsofthsm.so -l -y privkey --slot 0 -w key.der -d 001 -a <your-key-label> --pin <your-SoftHSM-PIN>
For softhsm2, use:
pkcs11-tool --module /usr/lib/softhsm/libsofthsm2.so -l -y privkey --slot 0 -w key.der -d 001 -a <your-key-label> --pin <your-SoftHSM-PIN>
Make sure that the indexer user/group has execute right to the token directory and read right to the token files below the /var/lib/softhsm/tokens/ directory.
Test your SoftHSM configuration with the indexer.
source /etc/indexer/external-indexer.env indexerworker -l -v 7 --pkcs11-lib "<your-SoftHSM-library>" --pkcs11-slot-id 0 --pkcs11-pin "<your-SoftHSM-PIN>"
Encrypt the PKCS#11 PIN(s). For detailed instructions, see Encrypting a PKCS#11 PIN.
Update the "pkcs11" object in the /etc/indexer/indexerworker.cfg file.
... "pkcs11": { "slots": [ { "library": "/usr/lib/softhsm/libsofthsm.so", "slot_id": 0, "pin": "<your-encrypted-PIN>" } ] } ...
Amazon Web Services (AWS) CloudHSM provides hardware security modules in the AWS Cloud.
The following describes how to configure CloudHSM.
|
NOTE:
The following steps assume that:
|
To configure CloudHSM
Test your environment as described in Setting up and testing the environment.
Note that you will need to provide your CloudHSM PIN in the following format:
"<your-CloudHSM-username:your-CloudHSM-PIN>"
Encrypt the PKCS#11 PIN(s). For detailed instructions, see Encrypting a PKCS#11 PIN.
Update the "pkcs11" object in the /etc/indexer/indexerworker.cfg file.
... "pkcs11": { "custom_password": true "slots": [ { "library": "/opt/cloudhsm/lib/libcloudhsm_pkcs11.so", "slot_id": 1, "pin": "<your-encrypted-PIN>" } ] } ...
|
NOTE:
Using the external indexer with a smart card is currently an experimental feature only. |
To configure a smart card
Install OpenSC, for example, from the EPEL repository of CentOS.
Ensure that the PC/SC Smart Card Daemon (pcscd) service is running:
On CentOS 6:
service pcscd start
On CentOS 7:
systemctl enable pcscd systemctl start pcscd
Alternatively, you can use:
systemctl enable pcscd.socket systemctl start pcscd.socket
This ensures that the pcscd service will not start at system startup, it will only start when there is an attempt (for example, by the indexerworker) to connect to it.
Test your environment as described in Setting up and testing the environment.
Encrypt the PKCS#11 PIN(s). For detailed instructions, see the Encrypting a PKCS#11 PIN.
Update the "pkcs11" object in the /etc/indexer/indexerworker.cfg file, for example:
... "pkcs11": { "slots": [ { "library": "/usr/lib64/pkcs11/opensc-pkcs11.so", "slot_id": 1, "pin": "encrypted_pin" } ] } ...
Use this section to customize how One Identity Safeguard for Privileged Sessions (SPS) indexes HTTP traffic.
You can customize only the configuration of external indexers. The indexer running on the SPS host always uses the default HTTP configuration, which is the following:
{ "General": { "Whitelist": ["text/.*", ".*json.*", "application/x-www-form-urlencoded", "multipart/.*"], "Blacklist": ["text/css", "application/javascript", "text/xslt", ".*xml.*"] }, "Form": { "Blacklist": ["password", "pass"] }, "Html": { "Attributes": ["href", "name", "value", "title", "id", "src"], "StrippedTags": ["script", "object", "style", "noscript", "embed", "video", "audio", "canvas", "svg"] } }
To customize how SPS indexes HTTP traffic
Create a configuration file for the HTTP indexer using a text editor. The configuration file uses the JSON format. For details on the configuration format, see HTTP indexer configuration format.
Copy the configuration file to the external hosts, to the /opt/external-indexer/usr/share/adp/httpconfig.json file.
Reload the indexer service: systemctl restart external-indexer.service
Repeat the above steps for your other external indexer hosts. Otherwise, it is possible that certain audit trails will be indexed using different indexer configuration.
Disable the indexer that is running on the SPS host. Otherwise, it is possible that certain audit trails will be indexed using different indexer configuration.
Navigate to Basic Settings > Local Services > Indexer service, and set the Maximum parallel audit trails to index on box option to 0.
© ALL RIGHTS RESERVED. Terms of Use Privacy Cookie Preference Center