Skip to content

Getting started

Installation

Homebrew

Install the CLI with Homebrew:

brew tap cyberark/tools
brew install idsec

Go

You can install the CLI via go modules. For private repositories, configure Git credentials.

macOS / Linux

# Requires Go 1.25+ and git 2.24+
export GOPRIVATE=github.com
git config --global url."https://<username>:<token>@github.com".insteadOf "https://github.com"
go install github.com/cyberark/idsec-cli-golang/cmd/idsec@latest

Make sure that the PATH environment variable points to the go binary path, for example:

export PATH=$PATH:$(go env GOPATH)/bin

Windows (PowerShell)

# Requires Go 1.25+ and Git for Windows 2.24+ on PATH
$env:GOPRIVATE = "github.com"
git config --global url."https://<username>:<token>@github.com".insteadOf "https://github.com"
go install github.com/cyberark/idsec-cli-golang/cmd/idsec@latest

The Go installer adds its own bin directory to PATH but not the one go install writes to, so add that as well:

$env:Path += ";$(go env GOPATH)\bin"

This lasts for the current session only. To keep it, add the same directory to PATH under System Properties > Environment Variables.

CLI Usage

The CLI supports profiles, which can be configured as needed and used for consecutive actions.

The CLI has the following basic commands:

  • configure: Configure profiles and their authentication methods (see Configure)
  • login: Log in using the configured profile authentication methods (see Login)
  • exec: Execute commands for supported services (see Exec). You can also skip exec and invoke services directly, e.g. idsec sia sso short-lived-password
  • profiles: Manage multiple profiles on the machine (see Profiles)
  • cache: Manage idsec cache on the machine (see Cache)
  • upgrade: Upgrade the CLI to the latest version (see Upgrade)

Basic flow

  1. Configure a profile (either silently or interactively):

    idsec configure --silent --work-with-isp --isp-username myuser
    
  2. After the profile is configured, log in:

    idsec login --silent --isp-secret mysecret
    
  3. Execute actions (such as generating a short-lived SSO password):

    idsec sia sso short-lived-password
    

    You can also use idsec exec sia sso short-lived-password — both forms are equivalent.