Documentation ¶
Overview ¶
package deepsecurity provides a DSM struct to interface with Deep Security's REST and SOAP APIs
Index ¶
- type DSM
- func (dsm DSM) AntiMalwareEventRetrieve(rangeFrom time.Time, rangeTo time.Time, specificTime time.Time, ...) ([]*gowsdlservice.AntiMalwareEventTransport, error)
- func (dsm DSM) ApplicationTypeRetrieveAll() ([]*gowsdlservice.ApplicationTypeTransport, error)
- func (dsm DSM) DPIRuleRetrieve(ruleID int) (*gowsdlservice.DPIRuleTransport, error)
- func (dsm DSM) DPIRuleRetrieveAll() ([]*gowsdlservice.DPIRuleTransport, error)
- func (dsm DSM) EndSession()
- func (dsm DSM) GetTrustedUpdateMode(hostID int) (TrustedUpdateModeResponse, bool)
- func (dsm DSM) HostAgentActivate(hosts []int32) (*gowsdlservice.HostAgentActivateResponse, error)
- func (dsm DSM) HostClearWarningsErrors(hosts []int32) *gowsdlservice.HostClearWarningsErrorsResponse
- func (dsm DSM) HostDetailRetrieve(hostID int, hostGroup int, securityProfileID int, hostType string, ...) *gowsdlservice.HostDetailTransport
- func (dsm DSM) HostGetStatus(host int32) (*gowsdlservice.HostStatusTransport, error)
- func (dsm DSM) HostGroupCreate(name string, external bool, externalID string, parentGroupId int32) (*gowsdlservice.HostGroupTransport, error)
- func (dsm DSM) HostGroupRetrieveAll() ([]*gowsdlservice.HostGroupRetrieveAllReturnTransport, error)
- func (dsm DSM) HostMoveToHostGroup(hostIDs []int32, hostGroupID int32) (*gowsdlservice.HostMoveToHostGroupResponse, error)
- func (dsm DSM) HostRecommendationRuleIDsRetrieve(hostID int, ruleType int, onlyUnassigned string) ([]int32, error)
- func (dsm DSM) HostRecommendationScan(hosts []int32) error
- func (dsm DSM) HostRetrieveAll() ([]*gowsdlservice.HostTransport, error)
- func (dsm DSM) HostRetrieveByHostGroup(hostGroupId int) ([]*gowsdlservice.HostTransport, error)
- func (dsm DSM) HostRetrieveByName(hostName string) (*gowsdlservice.HostTransport, error)
- func (dsm DSM) SystemEventRetrieve(rangeFrom time.Time, rangeTo time.Time, specificTime time.Time, ...) ([]*gowsdlservice.SystemEventTransport, error)
- type JsonDescribeTrustedUpdateModeResponse
- type TrustedUpdateModeResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DSM ¶
type DSM struct { SessionID string Host string Port string Tenant string RestURL string RestClient http.Client SoapClient *gowsdlservice.Manager SoapURL string }
DSM is the main object interface to Deep Security's REST & SOAP APIs
func NewDSM ¶
func NewDSM(username string, password string, host string, port string, tenant string, verifySSL bool) (DSM, error)
NewDSM is used to obtain a DSM struct. return empty DSM struct if there was a problem with communication or auth.
func (DSM) AntiMalwareEventRetrieve ¶
func (dsm DSM) AntiMalwareEventRetrieve(rangeFrom time.Time, rangeTo time.Time, specificTime time.Time, timeType string, hostID int, hostGroupID int, securityProfileID int, hostType string, eventID int, eventOperator string) ([]*gowsdlservice.AntiMalwareEventTransport, error)
AntiMalwareEventRetrieve retreives AM events by time and host filter
timeType: options are "LAST_HOUR", "LAST_24_HOURS", "LAST_7_DAYS". if set range_from, range_to, timeType and specificTime are not to be specified.
hostType: optional. options are "ALL_HOSTS", "HOSTS_IN_GROUP", "HOSTS_USING_SECURITY_PROFILE","HOSTS_IN_GROUP_AND_ALL_SUBGROUPS","SPECIFIC_HOST", "MY_HOSTS"
eventOperator: options "GREATER_THAN", "LESS_THAN", "EQUAL". if not set will default to "GREATER_THAN" Note: specific times do not work
func (DSM) ApplicationTypeRetrieveAll ¶
func (dsm DSM) ApplicationTypeRetrieveAll() ([]*gowsdlservice.ApplicationTypeTransport, error)
func (DSM) DPIRuleRetrieve ¶
func (dsm DSM) DPIRuleRetrieve(ruleID int) (*gowsdlservice.DPIRuleTransport, error)
func (DSM) DPIRuleRetrieveAll ¶
func (dsm DSM) DPIRuleRetrieveAll() ([]*gowsdlservice.DPIRuleTransport, error)
func (DSM) GetTrustedUpdateMode ¶
func (dsm DSM) GetTrustedUpdateMode(hostID int) (TrustedUpdateModeResponse, bool)
GetTrustedUpdateMode gets the settings for trusted update mode on a host. return true of false based on http response code
func (DSM) HostAgentActivate ¶
func (dsm DSM) HostAgentActivate(hosts []int32) (*gowsdlservice.HostAgentActivateResponse, error)
func (DSM) HostClearWarningsErrors ¶
func (dsm DSM) HostClearWarningsErrors(hosts []int32) *gowsdlservice.HostClearWarningsErrorsResponse
HostClearWarningsErrors clears warning and errors on a single host of list of hosts in all cases it returns an empty HostClearWarningsErrorsResponse object. note* I have yet to find error condition.
func (DSM) HostDetailRetrieve ¶
func (dsm DSM) HostDetailRetrieve(hostID int, hostGroup int, securityProfileID int, hostType string, hostDetailLevel string) *gowsdlservice.HostDetailTransport
func (DSM) HostGetStatus ¶
func (dsm DSM) HostGetStatus(host int32) (*gowsdlservice.HostStatusTransport, error)
HostGetStatus retrieves a host status transport for a host by id returns nil for HostStatusTransport if error found
func (DSM) HostGroupCreate ¶
func (dsm DSM) HostGroupCreate(name string, external bool, externalID string, parentGroupId int32) (*gowsdlservice.HostGroupTransport, error)
HostGroupCreate creates a host group. Pass -1 for parentGroupId if not associated with a parent group. If external is false externalID is ignored.
func (DSM) HostGroupRetrieveAll ¶
func (dsm DSM) HostGroupRetrieveAll() ([]*gowsdlservice.HostGroupRetrieveAllReturnTransport, error)
HostGroupRetrieveAll retrieves all hostgroups returns empty list if error or none found
func (DSM) HostMoveToHostGroup ¶
func (dsm DSM) HostMoveToHostGroup(hostIDs []int32, hostGroupID int32) (*gowsdlservice.HostMoveToHostGroupResponse, error)
HostMoveToHostGroup moves list of hosts or single host to host group returns nil if error
func (DSM) HostRecommendationRuleIDsRetrieve ¶
func (dsm DSM) HostRecommendationRuleIDsRetrieve(hostID int, ruleType int, onlyUnassigned string) ([]int32, error)
onlyUnassigned is really bool which is not working so pass string true or false
func (DSM) HostRecommendationScan ¶
HostRecommendationScan initiates a host recommendation scan for an individual or list of hosts returns nil if no error found
func (DSM) HostRetrieveAll ¶
func (dsm DSM) HostRetrieveAll() ([]*gowsdlservice.HostTransport, error)
HostRetrieveAll retrieves all hosts from the DSM returns empty slice if none found or error occurs
func (DSM) HostRetrieveByHostGroup ¶
func (dsm DSM) HostRetrieveByHostGroup(hostGroupId int) ([]*gowsdlservice.HostTransport, error)
HostRetrieveByHostGroup retrieves all hosts in a dsm group by id. returns empty slice if none found or error occurs
func (DSM) HostRetrieveByName ¶
func (dsm DSM) HostRetrieveByName(hostName string) (*gowsdlservice.HostTransport, error)
HostRetrieveByName retrieves a host by name returns nil if error or host not found
func (DSM) SystemEventRetrieve ¶
func (dsm DSM) SystemEventRetrieve(rangeFrom time.Time, rangeTo time.Time, specificTime time.Time, timeType string, hostID int, hostGroupID int, securityProfileID int, hostType string, eventID int, eventOperator string, includeNonHostEvents bool) ([]*gowsdlservice.SystemEventTransport, error)
SystemEventRetrieve retreives system events by time and host filter
timeType: options are "LAST_HOUR", "LAST_24_HOURS", "LAST_7_DAYS". if set range_from, range_to, timeType and specificTime are not to be specified.
hostType: optional. options are "ALL_HOSTS", "HOSTS_IN_GROUP", "HOSTS_USING_SECURITY_PROFILE","HOSTS_IN_GROUP_AND_ALL_SUBGROUPS","SPECIFIC_HOST", "MY_HOSTS"
eventOperator: options "GREATER_THAN", "LESS_THAN", "EQUAL". if not set will default to "GREATER_THAN" Note: specific times do not work
type JsonDescribeTrustedUpdateModeResponse ¶
type JsonDescribeTrustedUpdateModeResponse struct {
DescribeTrustedUpdateModeResponse TrustedUpdateModeResponse `json: "DescribeTrustedUpdateModeResponse"`
}
type TrustedUpdateModeResponse ¶
type TrustedUpdateModeResponse struct {
State string `json: "state"`
}
Directories ¶
Path | Synopsis |
---|---|
conflicts seem to occur around date/times conversion and transport object XMLnamspacing
|
conflicts seem to occur around date/times conversion and transport object XMLnamspacing |