cac

command module
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 14, 2023 License: MIT Imports: 2 Imported by: 0

README

CyberArk Client

cac is a simple CyberArk Central Credentials Provider REST client written in Go.

build

Authentication

Authentication to CCP is done via client certificate/key files.

Usage

Usage of ./cac:
  -appId string
    	CyberArk Application Id
  -certFile string
    	Certificate file
  -config string
    	Config name
  -host string
    	CyberArk CCP REST Web Service Host
  -json
    	JSON output
  -keyFile string
    	Key file
  -maxConns int
    	Max connections (default 4)
  -maxTries int
    	Max tries (default 3)
  -object value
    	CyberArk Object (at least one required)
  -safe string
    	CyberArk Safe
  -timeout duration
    	Timeout (default 30s)
  -version
    	Display version information
  -wait duration
    	Wait before retry (default 100ms)
  • Multiple objects can be queried in one go: --object o1 --object o2

  • Pipe mode:

    $ echo "KEY=${CYBER_ARK:OBJECT}" | cac -config MyConfig
    KEY=VALUE
    
  • Use maxConns to set max parallel HTTP connections to CCP server

  • Retries happened on error 500 (internal server error), 502 (bad gateway), 503 (service unavailable) and 504 (gateway timeout)

  • A config file can be setup in $XDG_CONFIG_HOME/cac/config.json (default to ~/.config/cac/config.json)

    • command line parameters overwrite config
  • appId, certFile, host, keyFile, safe are required, either in config or in command line parameters

  • Default output is "shell" but JSON is also supported:

    o1='value1'
    o2='value2'
    
    [
      {
        "object": "o1",
        "value": "value1"
      },
      {
        "object": "o2",
        "value": "value2"
      }
    ]
    

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL