cyberark

package
v0.1.10 Latest Latest
Warning

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

Go to latest
Published: May 31, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Description: This file contains the Cyberark client and its methods to authenticate, get secrets and passwords from Cyberark. TODO: Remove NHN specific code and make it generic for all Cyberark users.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CyberarkAuthenticationResquest

type CyberarkAuthenticationResquest struct {
	Username          string `json:"username"`
	Password          string `json:"password"`
	ConcurrentSession bool   `json:"concurrentSession"`
	Verify            string `json:"verify"`
	Timeout           string `json:"timeout"`
}

type CyberarkClient

type CyberarkClient struct {
	Url string
	// contains filtered or unexported fields
}

func NewCyberarkClient

func NewCyberarkClient(url string, validDomains ...string) (*CyberarkClient, error)

func (*CyberarkClient) Authenticate

func (c *CyberarkClient) Authenticate(username, password string) (string, time.Time, error)

func (*CyberarkClient) GetPassword

func (c *CyberarkClient) GetPassword(id string) (string, error)

func (*CyberarkClient) GetSecret

func (c *CyberarkClient) GetSecret(id string) (*CyberarkSecret, error)

func (*CyberarkClient) GetSecrets

func (c *CyberarkClient) GetSecrets() (*[]CyberarkSecret, error)

func (*CyberarkClient) Ping

func (c *CyberarkClient) Ping() bool

func (*CyberarkClient) SetToken

func (c *CyberarkClient) SetToken(token string)

type CyberarkClientInterface

type CyberarkClientInterface interface {
	Authenticate(username, password string) error
}

type CyberarkPasswordRequest

type CyberarkPasswordRequest struct {
	Reason string `json:"reason"`
}

type CyberarkSecret

type CyberarkSecret struct {
	CategoryModificationTime  int64  `json:"categoryModificationTime"`
	PlatformID                string `json:"platformId"`
	SafeName                  string `json:"safeName"`
	ID                        string `json:"id"`
	Name                      string `json:"name"`
	Address                   string `json:"address"`
	UserName                  string `json:"userName"`
	SecretType                string `json:"secretType"`
	PlatformAccountProperties struct {
		LogonDomain string `json:"LogonDomain"`
		NHNtag      string `json:"NHNtag"`
	} `json:"platformAccountProperties"`
	SecretManagement struct {
		AutomaticManagementEnabled bool   `json:"automaticManagementEnabled"`
		Status                     string `json:"status"`
		LastModifiedTime           int64  `json:"lastModifiedTime"`
		LastReconciledTime         int64  `json:"lastReconciledTime"`
		LastVerifiedTime           int64  `json:"lastVerifiedTime"`
	} `json:"secretManagement"`
	CreatedTime int64 `json:"createdTime"`
	Displayname string
}

type CyberarkSecretsResponse

type CyberarkSecretsResponse struct {
	Value []CyberarkSecret `json:"value"`
	Count int              `json:"count"`
}

Jump to

Keyboard shortcuts

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