Documentation ¶
Index ¶
- Constants
- Variables
- func RESTTimeString(t time.Time) string
- func UpgradeLogLevel(level string) string
- type AdmCtlTimeStamps
- type Audit
- type Event
- type IBMSAFinding
- type Incident
- type LogCommon
- type RESTAWSAccountKey
- type RESTAWSAccountKeyConfig
- type RESTAdmCatOptions
- type RESTAdmCtrlPromoteRequest
- type RESTAdmCtrlPromoteRequestData
- type RESTAdmCtrlRulesExport
- type RESTAdmCtrlRulesTestResult
- type RESTAdmCtrlRulesTestResults
- type RESTAdmRuleCriterion
- type RESTAdmRuleOptions
- type RESTAdmRuleTypeOptions
- type RESTAdmissionConfigData
- type RESTAdmissionRule
- type RESTAdmissionRuleConfig
- type RESTAdmissionRuleConfigData
- type RESTAdmissionRuleData
- type RESTAdmissionRuleOption
- type RESTAdmissionRulesData
- type RESTAdmissionState
- type RESTAdmissionStats
- type RESTAdmissionStatsData
- type RESTAgent
- type RESTAgentConfig
- type RESTAgentConfigData
- type RESTAgentCounter
- type RESTAgentCounterData
- type RESTAgentData
- type RESTAgentStatsData
- type RESTAgentsData
- type RESTAllUserPermitOptions
- type RESTAuditsData
- type RESTAuthData
- type RESTAuthPassword
- type RESTAuthToken
- type RESTAwsCloudRes
- type RESTAwsFuncPermission
- type RESTAwsFuncSummary
- type RESTAwsFunction
- type RESTAwsLambdaRes
- type RESTAwsLambdaResDetail
- type RESTAwsResDetail
- type RESTAwsResource
- type RESTAwsResourceConfig
- type RESTAwsResourceCreate
- type RESTBenchCheck
- type RESTBenchItem
- type RESTBenchMeta
- type RESTBenchReport
- type RESTCloudResList
- type RESTComplianceAsset
- type RESTComplianceAssetData
- type RESTComplianceData
- type RESTComplianceProfile
- type RESTComplianceProfileConfig
- type RESTComplianceProfileConfigData
- type RESTComplianceProfileData
- type RESTComplianceProfileEntry
- type RESTComplianceProfileEntryConfigData
- type RESTComplianceProfilesData
- type RESTController
- type RESTControllerConfig
- type RESTControllerConfigData
- type RESTControllerCounter
- type RESTControllerCounterData
- type RESTControllerData
- type RESTControllersData
- type RESTConversation
- type RESTConversationCompact
- type RESTConversationDetail
- type RESTConversationEndpoint
- type RESTConversationEndpointConfig
- type RESTConversationEndpointConfigData
- type RESTConversationEndpointData
- type RESTConversationEntry
- type RESTConversationQuery
- type RESTConversationQueryData
- type RESTConversationReport
- type RESTConversationsData
- type RESTConversationsDetailData
- type RESTConversationsVerboseData
- type RESTCrdGroupConfig
- type RESTCrdWafGroupConfig
- type RESTCrdWafGroupSetting
- type RESTCriteriaEntry
- type RESTCustomCheck
- type RESTCustomCheckConfig
- type RESTCustomCheckConfigData
- type RESTCustomCheckData
- type RESTCustomCheckListData
- type RESTCustomChecks
- type RESTDebugIP2Workload
- type RESTDebugIP2WorkloadData
- type RESTDebugSyncInfo
- type RESTDebugSyncInfoData
- type RESTDeployFedRulesReq
- type RESTDeployFedRulesResp
- type RESTDerivedDlpRule
- type RESTDerivedDlpRuleData
- type RESTDerivedDlpRuleMac
- type RESTDerivedDlpRuleMacData
- type RESTDerivedPolicyRule
- type RESTDerivedPolicyRuleData
- type RESTDerivedWorkloadDlpRule
- type RESTDerivedWorkloadDlpRuleData
- type RESTDerivedWorkloadPolicyRule
- type RESTDlpCriteriaEntry
- type RESTDlpGroup
- type RESTDlpGroupConfig
- type RESTDlpGroupConfigData
- type RESTDlpGroupData
- type RESTDlpGroupsData
- type RESTDlpRule
- type RESTDlpRuleConfig
- type RESTDlpRuleConfigData
- type RESTDlpRuleData
- type RESTDlpRuleDetail
- type RESTDlpRulesData
- type RESTDlpSensor
- type RESTDlpSensorConfig
- type RESTDlpSensorConfigData
- type RESTDlpSensorData
- type RESTDlpSensorsData
- type RESTDlpSetting
- type RESTDomain
- type RESTDomainConfig
- type RESTDomainConfigData
- type RESTDomainEntryConfig
- type RESTDomainEntryConfigData
- type RESTDomainsData
- type RESTEULA
- type RESTEULAData
- type RESTError
- type RESTErrorReadOnlyRules
- type RESTEventsData
- type RESTExposedEndpoint
- type RESTFedAuthData
- type RESTFedConfigData
- type RESTFedInternalCommandReq
- type RESTFedInternalCommandResp
- type RESTFedJoinReq
- type RESTFedJoinReqInternal
- type RESTFedJoinRespInternal
- type RESTFedJoinToken
- type RESTFedJointClusterInfo
- type RESTFedLeaveReq
- type RESTFedLeaveReqInternal
- type RESTFedMasterClusterInfo
- type RESTFedMembereshipData
- type RESTFedPingReq
- type RESTFedPingResp
- type RESTFedPromoteReqData
- type RESTFedPromoteRespData
- type RESTFedRemovedReqInternal
- type RESTFedRulesSettings
- type RESTFedSystemConfig
- type RESTFedTokenResp
- type RESTFileMonitorConfig
- type RESTFileMonitorConfigData
- type RESTFileMonitorFile
- type RESTFileMonitorFileData
- type RESTFileMonitorFilter
- type RESTFileMonitorFilterConfig
- type RESTFileMonitorProfile
- type RESTFileMonitorProfileData
- type RESTFileMonitorProfilesData
- type RESTGCRKey
- type RESTGCRKeyConfig
- type RESTGroup
- type RESTGroupBatchDelete
- type RESTGroupBrief
- type RESTGroupCaps
- type RESTGroupConfig
- type RESTGroupConfigData
- type RESTGroupData
- type RESTGroupDetail
- type RESTGroupExport
- type RESTGroupsBriefData
- type RESTGroupsData
- type RESTHost
- type RESTHostData
- type RESTHostsData
- type RESTIBMSAConfig
- type RESTIBMSASetupToken
- type RESTIBMSASetupUrl
- type RESTIDName
- type RESTIPAddr
- type RESTIPPort
- type RESTImportTask
- type RESTImportTaskData
- type RESTIncidentsData
- type RESTInternalSubnets
- type RESTInternalSubnetsData
- type RESTInternalSystemData
- type RESTLicenseCode
- type RESTLicenseInfo
- type RESTLicenseKey
- type RESTLicenseKeyCfgMap
- type RESTLicenseRequest
- type RESTLicenseRequestData
- type RESTLicenseShow
- type RESTLicenseShowData
- type RESTList
- type RESTListData
- type RESTMappableRoles
- type RESTMeter
- type RESTMeterList
- type RESTMetry
- type RESTModuleCve
- type RESTPolicyMismatch
- type RESTPolicyPromoteRequest
- type RESTPolicyPromoteRequestData
- type RESTPolicyRule
- type RESTPolicyRuleActionData
- type RESTPolicyRuleConfig
- type RESTPolicyRuleConfigData
- type RESTPolicyRuleData
- type RESTPolicyRuleInsert
- type RESTPolicyRuleMove
- type RESTPolicyRulesData
- type RESTPolicyViolationsData
- type RESTPolicyViolationsWLData
- type RESTPollFedRulesReq
- type RESTPollFedRulesResp
- type RESTProbeContainer
- type RESTProbeContainersData
- type RESTProbeProcess
- type RESTProbeProcessesData
- type RESTProbeSummary
- type RESTProbeSummaryData
- type RESTProcessInfo
- type RESTProcessList
- type RESTProcessProfile
- type RESTProcessProfileConfig
- type RESTProcessProfileConfigData
- type RESTProcessProfileData
- type RESTProcessProfileEntry
- type RESTProcessProfileEntryConfig
- type RESTProcessProfilesData
- type RESTProcessRuleResp
- type RESTProcessRulesResp
- type RESTProcessUuidEntry
- type RESTProfiling
- type RESTProfilingData
- type RESTProtoPort
- type RESTProxy
- type RESTPwdProfile
- type RESTPwdProfileBasic
- type RESTPwdProfileConditional
- type RESTPwdProfileConfig
- type RESTPwdProfileConfigData
- type RESTPwdProfileData
- type RESTPwdProfileDataConditional
- type RESTPwdProfilesData
- type RESTPwdProfilesDataCfgMap
- type RESTRegistry
- type RESTRegistryConfig
- type RESTRegistryConfigData
- type RESTRegistryDebugImage
- type RESTRegistryDebugImageData
- type RESTRegistryDebugImageTag
- type RESTRegistryImageSummary
- type RESTRegistryImageSummaryData
- type RESTRegistrySummary
- type RESTRegistrySummaryData
- type RESTRegistrySummaryListData
- type RESTRegistryTestData
- type RESTRegistryTestStep
- type RESTRegistryTestStepData
- type RESTResponseRule
- type RESTResponseRuleActionData
- type RESTResponseRuleConfig
- type RESTResponseRuleConfigData
- type RESTResponseRuleData
- type RESTResponseRuleInsert
- type RESTResponseRuleOptionData
- type RESTResponseRuleOptions
- type RESTResponseRulesData
- type RESTRiskScoreMetrics
- type RESTRolePermission
- type RESTRolePermitOptionInternal
- type RESTScanAppPackage
- type RESTScanAwsFuncDetail
- type RESTScanAwsFuncReport
- type RESTScanBrief
- type RESTScanConfig
- type RESTScanConfigData
- type RESTScanImageSummary
- type RESTScanImageSummaryData
- type RESTScanLayer
- type RESTScanLayersReport
- type RESTScanLayersReportData
- type RESTScanMeta
- type RESTScanModule
- type RESTScanPackageReqData
- type RESTScanPkgReport
- type RESTScanPkgReportData
- type RESTScanPlatformSummary
- type RESTScanPlatformSummaryData
- type RESTScanRepoReport
- type RESTScanRepoReportData
- type RESTScanRepoReq
- type RESTScanRepoReqData
- type RESTScanRepoSubmitData
- type RESTScanReport
- type RESTScanReportData
- type RESTScanSchedule
- type RESTScanSecret
- type RESTScanSetIdPerm
- type RESTScanStatus
- type RESTScanStatusData
- type RESTScanner
- type RESTScannerData
- type RESTSecurityData
- type RESTSelfUserData
- type RESTServer
- type RESTServerConfig
- type RESTServerConfigData
- type RESTServerData
- type RESTServerGroupRoleConfigData
- type RESTServerGroupRoleDomainsConfig
- type RESTServerGroupRoleDomainsConfigData
- type RESTServerGroupsOrderConfig
- type RESTServerGroupsOrderConfigData
- type RESTServerLDAP
- type RESTServerLDAPConfig
- type RESTServerLDAPConfigCfgMap
- type RESTServerLDAPTest
- type RESTServerOIDC
- type RESTServerOIDCConfig
- type RESTServerOIDCConfigCfgMap
- type RESTServerRoleGroupsConfig
- type RESTServerRoleGroupsConfigData
- type RESTServerSAML
- type RESTServerSAMLConfig
- type RESTServerSAMLConfigCfgMap
- type RESTServerTest
- type RESTServerTestData
- type RESTServerTestResult
- type RESTServerTestResultData
- type RESTServersData
- type RESTService
- type RESTServiceBatchConfig
- type RESTServiceBatchConfigData
- type RESTServiceConfig
- type RESTServiceConfigData
- type RESTServiceData
- type RESTServicesData
- type RESTSession
- type RESTSessionList
- type RESTSessionSummary
- type RESTSessionSummaryData
- type RESTSnifferArgs
- type RESTSnifferArgsData
- type RESTSnifferData
- type RESTSnifferInfo
- type RESTSnifferResult
- type RESTSnifferResultData
- type RESTSniffersData
- type RESTStats
- type RESTSystemConfig
- type RESTSystemConfigConfig
- type RESTSystemConfigConfigCfgMap
- type RESTSystemConfigConfigData
- type RESTSystemConfigData
- type RESTSystemRequest
- type RESTSystemRequestData
- type RESTSystemStats
- type RESTSystemStatsData
- type RESTSystemSummary
- type RESTSystemSummaryData
- type RESTSystemUsageReport
- type RESTSystemUsageReportData
- type RESTSystemWebhookConfigData
- type RESTThreatData
- type RESTThreatsData
- type RESTToken
- type RESTTokenAuthServer
- type RESTTokenAuthServerRedirect
- type RESTTokenAuthServersData
- type RESTTokenAuthServersRedirectData
- type RESTTokenData
- type RESTTokenRedirect
- type RESTUnquarReq
- type RESTUser
- type RESTUserConfig
- type RESTUserConfigData
- type RESTUserData
- type RESTUserPermitOption
- type RESTUserPermitOptions
- type RESTUserPwdConfig
- type RESTUserPwdConfigData
- type RESTUserRole
- type RESTUserRoleConfig
- type RESTUserRoleConfigData
- type RESTUserRoleData
- type RESTUserRoleDomainsConfig
- type RESTUserRoleDomainsConfigData
- type RESTUserRolesData
- type RESTUserRolesDataCfgMap
- type RESTUsersData
- type RESTUsersDataCfgMap
- type RESTViolationWorkload
- type RESTVulnPackageVersion
- type RESTVulnerability
- type RESTVulnerabilityAsset
- type RESTVulnerabilityAssetData
- type RESTVulnerabilityProfile
- type RESTVulnerabilityProfileConfig
- type RESTVulnerabilityProfileConfigData
- type RESTVulnerabilityProfileData
- type RESTVulnerabilityProfileEntry
- type RESTVulnerabilityProfileEntryConfigData
- type RESTVulnerabilityProfilesData
- type RESTWafConfig
- type RESTWafCriteriaEntry
- type RESTWafGroup
- type RESTWafGroupConfig
- type RESTWafGroupConfigData
- type RESTWafGroupData
- type RESTWafGroupsData
- type RESTWafRule
- type RESTWafRuleData
- type RESTWafRuleDetail
- type RESTWafRulesData
- type RESTWafSensor
- type RESTWafSensorConfig
- type RESTWafSensorConfigData
- type RESTWafSensorData
- type RESTWafSensorExport
- type RESTWafSensorsData
- type RESTWafSetting
- type RESTWebhook
- type RESTWorkload
- type RESTWorkloadBrief
- type RESTWorkloadConfig
- type RESTWorkloadConfigCfg
- type RESTWorkloadConfigCfgData
- type RESTWorkloadConfigData
- type RESTWorkloadDetail
- type RESTWorkloadDetailData
- type RESTWorkloadIntercept
- type RESTWorkloadInterceptData
- type RESTWorkloadInterceptPort
- type RESTWorkloadPorts
- type RESTWorkloadRequest
- type RESTWorkloadRequestData
- type RESTWorkloadStatsData
- type RESTWorkloadsBriefData
- type RESTWorkloadsData
- type Threat
- type Violation
Constants ¶
const ( ServerCatAuth string = "auth" ServerCatNotify string = "notify" ServerCatLog string = "log" ServerTypeLDAP string = "ldap" ServerTypeSAML string = "saml" ServerTypeOIDC string = "oidc" ServerLDAPTypeOpenLDAP string = "OpenLDAP" ServerLDAPTypeMSAD string = "MicrosoftAD" LDAPGroupMemberAttrOpenLDAP string = "memberUid" LDAPGroupMemberAttrMSAD string = "member" LDAPUserNameAttrOpenLDAP string = "uid" LDAPUserNameAttrMSAD string = "sAMAccountName" )
const ( BenchCatalogDocker = "docker" BenchCatalogKube = "kubernetes" BenchCatalogCustom = "custom" BenchTypeMaster = "master" BenchTypeWorker = "worker" BenchTypeHost = "host" BenchTypeContainer = "container" )
const ( SnifferStRunning string = "running" SnifferStStopped string = "stopped" SnifferStFailed string = "failed" )
const ( ScanVulStatusUnpatched string = "unpatched" ScanVulStatusFixExists string = "fix exists" ScanVulStatusWillNotFix string = "will not fix" ScanVulStatusUnaffected string = "unaffected" )
const ( CfgTypeLearned = "learned" CfgTypeUserCreated = "user_created" CfgTypeGround = "ground" CfgTypeFederal = "federal" CfgSystemDefined = "system_defined" )
const ( WireInline string = share.WireInline WireDefault string = share.WireDefault )
const ( WebhookDefaultName = "default" WebhookTypeSlack = "Slack" WebhookTypeJSON = "JSON" )
const ( ScanSourceJenkins string = "jenkins" ScanSourceServerless string = "serverless" )
const ( ComplianceTemplateAll = "all" ComplianceTemplatePCI = "PCI" ComplianceTemplateGDPR = "GDPR" ComplianceTemplateHIPAA = "HIPAA" ComplianceTemplateNIST = "NIST" // NIST SP 800-190 )
const ( VulnerabilityNameRecent = "_RecentVuln" VulnerabilityNameRecentWithoutFix = "_RecentVulnWithoutFix" )
const ( RegistryStatusIdle = "idle" RegistryStatusScanning = "scanning" RegistryImageSourceOpenShift = "openshift" )
const ( ScanSchManual = "manual" ScanSchAuto = "auto" ScanSchPeriodical = "periodical" ScanIntervalMin = 5 * 60 ScanIntervalMax = 7 * 24 * 60 * 60 ScanPersistImageMax = 8192 )
const ( MatchSrcYaml = "yaml" MatchSrcImage = "image" MatchSrcBoth = "both" )
const ( ValidatingDenyRuleType = "deny" ValidatingExceptRuleType = "exception" ValidatingAllowRuleType = "allow" // same meaning as ValidatingExceptRuleType )
const ( FedRoleNone = "" FedRoleMaster = "master" FedRoleJoint = "joint" )
const ( FedClusterStatusNone = "active" FedClusterStatusCmdUnknown = "unknown_cmd" FedClusterStatusCmdReceived = "notified" FedClusterStatusCmdReqError = "req_error" FedStatusMasterUpgradeRequired = "master_upgrade_required" // for describing master cluster only FedStatusJointUpgradeRequired = "joint_upgrade_required" // for describing joint cluster only FedStatusClusterUpgradeOngoing = "cluster_upgrade_ongoing" // could get this status only when rolling upgrade & polling fed rules on joint cluster are happenging FedStatusJointVersionTooNew = "joint_version_too_new" // for describing joint cluster only FedStatusClusterConnected = "connected" // for describing master cluster only FedStatusClusterDisconnected = "disconnected" // for describing master cluster only FedStatusClusterJoined = "joined" // for describing joint cluster only. short-lived (between joining and the first polling) FedStatusClusterOutOfSync = "out_of_sync" // for describing joint cluster only FedStatusClusterSynced = "synced" // for describing joint cluster only FedStatusClusterKicked = "kicked" // for describing self on joint cluster only FedStatusClusterLeft = "left" // for describing joint cluster only FedStatusLicenseDisallowed = "license_disallow" // for describing clusters in fed FedStatusClusterPinging = "pinging" // for describing joint cluster only. short-lived (between license update and the immediate ping) FedStatusClusterSyncing = "syncing" // for describing joint cluster only. short-lived (when joint cluster is applying fed rules) )
const ( ProfilingCPU string = "cpu" ProfilingMemory string = "memory" ProfilingDurationMax uint32 = 60 )
const ( HTTPTestStepStage = "stage" HTTPTestStepImage = "images" HTTPTestStepURL = "url" HTTPTestStepResponse = "response" HTTPTestStepError = "error" )
const ( CategoryEvent = "event" CategoryViolation = "violation" // merged into CategoryRuntime in config, stil used in log category CategoryThreat = "threat" // merged into CategoryRuntime in config, stil used in log category CategoryIncident = "incident" // merged into CategoryRuntime in config, stil used in log category CategoryRuntime = "security-event" CategoryAudit = "audit" )
const ( LogLevelEMERG = "Emergency" LogLevelALERT = "Alert" LogLevelCRIT = "Critical" LogLevelERR = "Error" LogLevelWARNING = "Warning" LogLevelNOTICE = "Notice" LogLevelINFO = "Info" LogLevelDEBUG = "Debug" )
const ( SeverityCritical = "Critical" SeverityHigh = "High" SeverityMedium = "Medium" SeverityLow = "Low" SeverityInfo = "Info" )
const ( EventNameContainerStart = "Container.Start" EventNameContainerStop = "Container.Stop" EventNameContainerRemove = "Container.Remove" EventNameContainerSecured = "Container.Secured" EventNameContainerUnsecured = "Container.Unsecured" EventNameAgentStart = "Enforcer.Start" EventNameAgentJoin = "Enforcer.Join" EventNameAgentStop = "Enforcer.Stop" EventNameAgentDisconnect = "Enforcer.Disconnect" EventNameAgentConnect = "Enforcer.Connect" EventNameAgentKicked = "Enforcer.Kicked" EventNameControllerStart = "Controller.Start" EventNameControllerJoin = "Controller.Join" EventNameControllerLeave = "Controller.Leave" EventNameControllerStop = "Controller.Stop" EventNameControllerDisconnect = "Controller.Disconnect" EventNameControllerConnect = "Controller.Connect" EventNameControllerLeadLost = "Controller.Lead.Lost" EventNameControllerLeadElect = "Controller.Lead.Elected" EventNameAuthLogin = "User.Login" EventNameAuthLogout = "User.Logout" EventNameAuthTimeout = "User.Timeout" EventNameAuthLoginFailed = "User.Login.Failed" EventNameAuthLoginBlocked = "User.Login.Blocked" EventNameAuthLoginUnblocked = "User.Login.Unblocked" EventNameAuthUserPwdRestByAdmin = "User.Password.Reset" EventNameAuthAccessDenied = "User.Resource.Access.Denied" EventNameRESTWrite = "RESTful.Write" EventNameRESTRead = "RESTful.Read" EventNameScannerJoin = "Scanner.Join" EventNameScannerUpdate = "Scanner.Update" EventNameScannerLeave = "Scanner.Leave" EventNameScanFail = "Scan.Failed" EventNameScanSucceed = "Scan.Succeeded" EventNameBenchDockerFail = "Docker.CIS.Benchmark.Failed" EventNameBenchKubeFail = "Kubenetes.CIS.Benchmark.Failed" EventNameLicenseUpdate = "License.Update" EventNameLicenseExpire = "License.Expire" EventNameLicenseRemove = "License.Remove" EventNameLicenseEnforcerLimitReached = "License.EnforcerLimitReached" EventNameAdmCtrlK8sConfigured = "Admission.Control.Configured" // for admission control EventNameAdmCtrlK8sConfigFailed = "Admission.Control.ConfigFailed" // for admission control EventNameInitCfgMapDone = "ConfigMap.Load" // for initial Config EventNameInitCfgMapError = "ConfigMap.Failed" // for initial Config failure EventNameCrdImported = "Crd.Import" // for crd Config import EventNameCrdRemoved = "Crd.Remove" // for crd Config remove due to k8s miss EventNameCrdErrDetected = "Crd.Error" // for remove error crd EventNameFedPromote = "Federation.Promote" // for multi-clusters EventNameFedDemote = "Federation.Demote" // for multi-clusters EventNameFedJoin = "Federation.Join" // for joint cluster in multi-clusters EventNameFedLeave = "Federation.Leave" // for multi-clusters EventNameFedKick = "Federation.Kick" // for multi-clusters EventNameFedPolicySync = "Federation.Policy.Sync" // for multi-clusters EventNameImport = "Configuration.Import" EventNameExport = "Configuration.Export" EventNameImportFail = "Configuration.Import.Failed" EventNameExportFail = "Configuration.Export.Failed" EventNameCloudScanNormal = "Cloud.Scan.Normal" // for cloud scan nomal ret EventNameCloudScanAlert = "Cloud.Scan.Alert" // for cloud scan ret with alert EventNameCloudScanFail = "Cloud.Scan.Fail" // for cloud scan fail EventNameGroupAutoRemove = "Group.Auto.Remove" EventNameMemoryPressureAgent = "Agent.Memory.Pressure" EventNameMemoryPressureController = "Controller.Memory.Pressure" )
const ( EventNameHostPrivilEscalate = "Host.Privilege.Escalation" EventNameContainerPrivilEscalate = "Container.Privilege.Escalation" EventNameHostSuspiciousProcess = "Host.Suspicious.Process" EventNameContainerSuspiciousProcess = "Container.Suspicious.Process" EventNameContainerQuarantined = "Container.Quarantined" EventNameContainerUnquarantined = "Container.Unquarantined" EventNameHostFileAccessViolation = "Host.FileAccess.Violation" EventNameContainerFileAccessViolation = "Container.FileAccess.Violation" EventNameHostPackageUpdated = "Host.Package.Updated" EventNameContainerPackageUpdated = "Container.Package.Updated" EventNameHostTunnelDetected = "Host.Tunnel.Detected" EventNameContainerTunnelDetected = "Container.Tunnel.Detected" EventNameProcessProfileViolation = "Process.Profile.Violation" // container EventNameHostProcessProfileViolation = "Host.Process.Violation" // host )
TODO: these are not events but incidents
const ( EventNameComplianceContainerBenchViolation = "Compliance.Container.Violation" EventNameComplianceContainerFileBenchViolation = "Compliance.ContainerFile.Violation" EventNameComplianceHostBenchViolation = "Compliance.Host.Violation" EventNameComplianceImageBenchViolation = "Compliance.Image.Violation" EventNameContainerScanReport = "Container.Scan.Report" EventNameHostScanReport = "Host.Scan.Report" EventNameRegistryScanReport = "Registry.Scan.Report" EventNamePlatformScanReport = "Platform.Scan.Report" EventNameAdmCtrlK8sReqAllowed = "Admission.Control.Allowed" // for admission control EventNameAdmCtrlK8sReqViolation = "Admission.Control.Violation" // for admission control EventNameAdmCtrlK8sReqDenied = "Admission.Control.Denied" // for admission control EventNameComplianceContainerCustomCheckViolation = "Compliance.ContainerCustomCheck.Violation" EventNameComplianceHostCustomCheckViolation = "Compliance.HostCustomCheck.Violation" EventNameAwsLambdaScan = "AwsLambda.Scan" )
TODO: these are audit related
const ( EventCatREST = "RESTFUL" EventCatAuth = "AUTH" EventCatWorkload = "WORKLOAD" EventCatAgent = "ENFORCER" EventCatController = "CONTROLLER" EventCatScan = "SCANNER" EventCatBench = "CIS.BENCHMARK" EventCatLicense = "LICENSE" EventCatConfigMap = "CONFIGMAP" EventCatCrd = "CRD" EventCatAdmCtrl = "ADMISSION.CONTROL" EventCatFed = "FEDERATION" EventCatConfig = "CONFIGURATION" EventCatCloud = "CLOUD" EventCatGroup = "GROUP" )
const ( ThreatActionMonitor = "alert" ThreatActionAllow = "allow" ThreatActionBlock = "deny" ThreatActionReset = "reset" )
const ( TargetServer = "server" TargetClient = "client" )
const ( IncidentActionAlert = "Alert" IncidentActionDenied = "Denied" )
const AdmCtrlCrdRuleIDBase = 110000
const AdmCtrlCrdRuleIDMax = 120000
const AllContainerGroup string = "containers"
const AllHostGroup string = "nodes"
const AuthServerLocal string = "local"
const AuthServerPlatform string = "_platform_"
const BriefFlag string = "brief"
const ConfSectionAll string = "all"
const ConfSectionConfig string = "config"
const ConfSectionPolicy string = "policy"
const ConfSectionUser string = "user"
const DefaultControllerRESTAPIPort = 10443
const DlpRuleCommentMaxLen int = 256
const DlpRuleNameMaxLen int = 256
const DlpRulePatternMaxLen int = 512
const DlpRulePatternMaxNum int = 16
const DlpRulePatternTotalMaxLen int = 1024
const DomainContainers string = "_containers"
const DomainImages string = "_images"
const DomainNodes string = "_nodes"
const EndpointIngress string = "ingress"
const EndpointKindAddrGroup string = "address"
const EndpointKindContainer string = "container"
const EndpointKindExternal string = "external"
const EndpointKindHostIP string = "node_ip"
const EndpointKindIPSvcGroup string = "ip_service"
const EndpointKindService string = "nv_service" // Used in collapse view
const EndpointKindWorkloadIP string = "workload_ip"
const FederalGroupPrefix string = "fed."
const FilterByAgent string = "enforcer"
const FilterByDomain string = "domain"
const FilterByGroup string = "group"
const FilterByHost string = "node"
const FilterByID string = "id"
const FilterByPredefined string = "predefined"
const FilterByWorkload string = "workload"
const FilterPrefix string = "f_"
const FilterServerCategory string = "category"
const FilterServerType string = "type"
const LearnedExternal string = "external"
const LearnedGroupPrefix string = "nv."
const LearnedHostPrefix string = "Host:"
const LearnedSvcGroupPrefix string = "nv.ip."
const LearnedWorkloadPrefix string = "Workload:"
const LicenseIDTypeHost string = "host"
const MaxDlpPredefinedRuleID = 40000
const MaxFedAdmRespRuleID = 110000
const MaxWafRuleID = 50000
const MeterTypeICMPFlood string = "icmp_flood"
const MeterTypeIPSrcSessionLimit string = "ip_src_session_limit"
const MeterTypeSYNFlood string = "syn_flood"
const MeterTypeTCPNoData string = "tcp_nodata"
const MinDlpPredefinedRuleID = 30000
const MinDlpRuleID = 20000
const MinWafRuleID = 40000
waf
const OPeq string = "eq"
const OPgt string = "gt"
const OPgte string = "gte"
const OPin string = "in"
const OPlt string = "lt"
const OPlte string = "lte"
const OPneq string = "neq"
const OPprefix string = "prefix"
const PageLimit string = "limit"
const PageStart string = "start"
const PlatformContainerAddon string = "addon"
const PlatformContainerCore string = "core"
const PolicyAppAny string = "any"
const PolicyAutoID uint32 = 0
const PolicyDomainNameMaxLen int = 256
const PolicyFedRuleIDBase uint32 = share.PolicyFedRuleIDBase
const PolicyFedRuleIDMax uint32 = share.PolicyFedRuleIDMax
const PolicyGroundRuleIDBase uint32 = share.PolicyGroundRuleIDBase
const PolicyGroundRuleIDMax uint32 = share.PolicyGroundRuleIDMax
const PolicyLearnedIDBase uint32 = share.PolicyLearnedIDBase
const PolicyPortAny string = "any"
const QueryDuration string = "token_duration"
const QueryKeySection string = "section"
const QueryKeyShow string = "show"
const QueryKeyView string = "view"
const QueryScope string = "scope"
const QueryValueShowAccepted string = "accepted"
const QueryValueViewPod string = "pod"
const QueryValueViewPodOnly string = "pod_only"
const RESTErrAdmCtrlUnSupported int = 30
const RESTErrAgentError int = 21
const RESTErrCISBenchError int = 23
const RESTErrClusterRPCError int = 24
const RESTErrClusterRoleForAdmCtrl int = 31
const RESTErrClusterTimeout int = 11
const RESTErrClusterWrongData int = 10
const RESTErrDuplicateName int = 13
const RESTErrFailExport int = 17
const RESTErrFailImport int = 18
const RESTErrFailKubernetesApi int = 28
const RESTErrFailLockCluster int = 19
const RESTErrFailReadCluster int = 9
const RESTErrFailRegistryScan int = 27
const RESTErrFailRepoScan int = 26
const RESTErrFailWriteCluster int = 8
const RESTErrFedDuplicateName int = 41
const RESTErrFedJointUnreachable int = 40
const RESTErrFedOperationFailed int = 39
const RESTErrIBMSABadDashboardURL int = 45
const RESTErrIBMSATestFailed int = 44
const RESTErrInvalidName int = 15
const RESTErrInvalidRequest int = 6
const RESTErrJointUpgradeRequired int = 43
const RESTErrK8sApiSrvToWebhook int = 34
const RESTErrLicenseFail int = 20
const RESTErrMasterUpgradeRequired int = 42
const RESTErrMethodNotAllowed int = 2
const RESTErrNoUpdatePermission int = 33
const RESTErrNotEnoughFilter int = 12
const RESTErrNotFound int = 1
Don't modify value or reorder
const RESTErrNvPermission int = 35
const RESTErrObjectAccessDenied int = 25
const RESTErrObjectInuse int = 16
const RESTErrObjectNotFound int = 7
const RESTErrOpNotAllowed int = 4
const RESTErrPasswordExpired int = 48
const RESTErrPromoteFail int = 49
const RESTErrProxyError int = 29 // Not used
const RESTErrReadOnlyRules int = 46
const RESTErrRemoterRequestFail int = 38
const RESTErrTooManyLoginUser int = 5
const RESTErrUserLoginBlocked int = 47
const RESTErrWeakPassword int = 14
const RESTErrWebhookIsDisabled int = 36
const RESTErrWebhookSvcForAdmCtrl int = 32
const RESTErrWorkloadNotRunning int = 22
const RESTMaskedValue string = "The value is masked"
const RESTNvPageDashboard string = "dashboard"
const RESTNvPageHeader string = "X-Nv-Page"
const RESTTokenHeader string = "X-Auth-Token"
const RawFlag string = "raw"
const ReservedUserNameIBMSA string = "nv.reserved.ibmsa"
const ScanStatusFailed string = "failed"
const ScanStatusFinished string = "finished"
const ScanStatusIdle string = ""
const ScanStatusScanning string = "scanning"
const ScanStatusScheduled string = "scheduled"
const ScanStatusUnsupported string = "unsupported"
const SortAsc string = "asc"
const SortDesc string = "desc"
const SortPrefix string = "s_"
const StartingFedAdmRespRuleID = 100000
const StartingLocalAdmCtrlRuleID = 1000
Admission control
const StartingLocalVulProfRuleID = 1000
const StateLeft string = "stopped"
const StateOffline string = "disconnected"
const StateOnline string = "connected"
const StateUnmanaged string = "unmanaged"
const SupportFlag string = "support"
const SyslogDefaultUDPPort uint16 = 514
syslog related
const UserIdleTimeoutMax uint32 = 3600
const UserIdleTimeoutMin uint32 = 30
const UserRoleAdmin string = "admin"
const UserRoleCIOps string = "ciops"
const UserRoleFedAdmin string = "fedAdmin"
the following role can only be interactively assigned on master cluster in a federation
const UserRoleFedReader string = "fedReader"
const UserRoleIBMSA string = "ibmsa" // it's a hidden role. (no user has this role in kv)
const UserRoleImportStatus string = "_hidden_import_status_#" // it's a hidden role. (no user has this role in kv)
const UserRoleNone string = ""
const UserRoleReader string = "reader"
const VerboseFlag string = "verbose"
const WithCapFlag string = "with_cap"
const WorkloadStateDiscover string = "discover"
const WorkloadStateExit string = "exit"
const WorkloadStateMonitor string = "monitor"
const WorkloadStateProtect string = "protect"
const WorkloadStateQuarantine string = "quarantined"
const WorkloadStateUnmanaged string = "unmanaged"
const WorkloadTunnelIF string = "Workload:ingress"
Variables ¶
var LogLevelList []string = []string{ LogLevelEMERG, LogLevelALERT, LogLevelCRIT, LogLevelERR, LogLevelWARNING, LogLevelNOTICE, LogLevelINFO, LogLevelDEBUG, }
var RESTTimeFomat string = time.RFC3339
var ThreatLevelList []string = []string{ LogLevelCRIT, LogLevelERR, LogLevelWARNING, LogLevelNOTICE, LogLevelINFO, }
Functions ¶
func RESTTimeString ¶
func UpgradeLogLevel ¶
Types ¶
type AdmCtlTimeStamps ¶
type Audit ¶
type Audit struct { LogCommon WorkloadID string `json:"workload_id,omitempty"` WorkloadName string `json:"workload_name,omitempty"` WorkloadDomain string `json:"workload_domain,omitempty"` WorkloadImage string `json:"workload_image,omitempty"` WorkloadService string `json:"workload_service,omitempty"` ImageID string `json:"image_id,omitempty"` Registry string `json:"registry,omitempty"` RegistryName string `json:"registry_name,omitempty"` Repository string `json:"repository,omitempty"` Tag string `json:"tag,omitempty"` BaseOS string `json:"base_os,omitempty"` HighCnt int `json:"high_vul_cnt"` MediumCnt int `json:"medium_vul_cnt"` HighVuls []string `json:"high_vuls,omitempty"` MediumVuls []string `json:"medium_vuls,omitempty"` CVEDBVersion string `json:"cvedb_version,omitempty"` Message string `json:"message"` User string `json:"user,omitempty"` Error string `json:"error,omitempty"` AggregationFrom int64 `json:"aggregation_from,omitempty"` Count uint32 `json:"count,omitempty"` Items []string `json:"items,omitempty"` Group string `json:"group,omitempty"` Platform string `json:"platform,omitempty"` PlatformVersion string `json:"platform_version,omitempty"` Region string `json:"region,omitempty"` ProjectName string `json:"project_name,omitempty"` }
type Event ¶
type Event struct { LogCommon ControllerID string `json:"controller_id"` ControllerName string `json:"controller_name"` WorkloadID string `json:"workload_id"` WorkloadName string `json:"workload_name"` WorkloadDomain string `json:"workload_domain"` WorkloadImage string `json:"workload_image"` WorkloadService string `json:"workload_service"` Category string `json:"category"` User string `json:"user"` UserRoles map[string]string `json:"user_roles"` // domain -> role UserAddr string `json:"user_addr"` UserSession string `json:"user_session"` RESTMethod string `json:"rest_method,omitempty"` RESTRequest string `json:"rest_request,omitempty"` RESTBody string `json:"rest_body,omitempty"` EnforcerLimit int `json:"enforcer_limit,omitempty"` LicenseExpire string `json:"license_expire,omitempty"` Msg string `json:"message"` }
type IBMSAFinding ¶
type Incident ¶
type Incident struct { LogCommon ID string `json:"id"` WorkloadID string `json:"workload_id,omitempty"` WorkloadName string `json:"workload_name,omitempty"` WorkloadDomain string `json:"workload_domain,omitempty"` WorkloadImage string `json:"workload_image,omitempty"` WorkloadService string `json:"workload_service,omitempty"` RemoteWL string `json:"remote_workload_id,omitempty"` RemoteWLName string `json:"remote_workload_name,omitempty"` RemoteWLDomain string `json:"remote_workload_domain,omitempty"` RemoteWLImage string `json:"remote_workload_image,omitempty"` RemoteWLService string `json:"remote_workload_service,omitempty"` ProcName string `json:"proc_name,omitempty"` ProcPath string `json:"proc_path,omitempty"` ProcCmd string `json:"proc_cmd,omitempty"` ProcRealUID int `json:"proc_real_uid,omitempty"` ProcEffUID int `json:"proc_effective_uid,omitempty"` ProcRealUser string `json:"proc_real_user,omitempty"` ProcEffUser string `json:"proc_effective_user,omitempty"` FilePath string `json:"file_path,omitempty"` Files []string `json:"file_name,omitempty"` ClientIP string `json:"client_ip,omitempty"` ServerIP string `json:"server_ip,omitempty"` ClientPort uint16 `json:"client_port,omitempty"` ServerPort uint16 `json:"server_port,omitempty"` ServerConnPort uint16 `json:"server_conn_port,omitempty"` EtherType uint16 `json:"ether_type,omitempty"` IPProto uint8 `json:"ip_proto,omitempty"` ConnIngress bool `json:"conn_ingress,omitempty"` ProcPName string `json:"proc_parent_name,omitempty"` ProcPPath string `json:"proc_parent_path,omitempty"` Action string `json:"action"` Group string `json:"group,omitempty"` RuleID string `json:"rule_id"` AggregationFrom int64 `json:"aggregation_from,omitempty"` Count int `json:"count,omitempty"` Msg string `json:"message"` }
type LogCommon ¶
type LogCommon struct { Name string `json:"name,omitempty"` Level string `json:"level"` ReportedTimeStamp int64 `json:"reported_timestamp"` ReportedAt string `json:"reported_at"` ClusterName string `json:"cluster_name"` ResponseRuleID int `json:"response_rule_id,omitempty"` HostID string `json:"host_id"` HostName string `json:"host_name"` AgentID string `json:"enforcer_id"` AgentName string `json:"enforcer_name"` }
type RESTAWSAccountKey ¶
type RESTAWSAccountKeyConfig ¶
type RESTAdmCatOptions ¶
type RESTAdmCatOptions struct {
K8sOptions *RESTAdmRuleOptions `json:"k8s_options,omitempty"`
}
type RESTAdmCtrlPromoteRequest ¶
type RESTAdmCtrlPromoteRequest struct {
IDs []uint32 `json:"ids"`
}
type RESTAdmCtrlPromoteRequestData ¶
type RESTAdmCtrlPromoteRequestData struct {
Request *RESTAdmCtrlPromoteRequest `json:"request"`
}
type RESTAdmCtrlRulesExport ¶
type RESTAdmCtrlRulesTestResults ¶
type RESTAdmCtrlRulesTestResults struct { Results []*RESTAdmCtrlRulesTestResult `json:"results,omitempty"` }
type RESTAdmRuleCriterion ¶
type RESTAdmRuleCriterion struct { Name string `json:"name"` Op string `json:"op"` Value string `json:"value"` SubCriteria []*RESTAdmRuleCriterion `json:"sub_criteria,omitempty"` }
type RESTAdmRuleOptions ¶
type RESTAdmRuleOptions struct {
RuleOptions map[string]*RESTAdmissionRuleOption `json:"rule_options"` // key is criterion name
}
type RESTAdmRuleTypeOptions ¶
type RESTAdmRuleTypeOptions struct { DenyOptions *RESTAdmCatOptions `json:"deny_options"` ExceptionOptions *RESTAdmCatOptions `json:"exception_options"` PspCollection []*RESTAdmRuleCriterion `json:"psp_collection,omitempty"` }
type RESTAdmissionConfigData ¶
type RESTAdmissionConfigData struct { State *RESTAdmissionState `json:"state,omitempty"` Options *RESTAdmRuleTypeOptions `json:"admission_options,omitempty"` K8sEnv bool `json:"k8s_env"` }
type RESTAdmissionRule ¶
type RESTAdmissionRule struct { ID uint32 `json:"id"` Category string `json:"category"` Comment string `json:"comment"` Criteria []*RESTAdmRuleCriterion `json:"criteria"` Disable bool `json:"disable"` Critical bool `json:"critical"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) RuleType string `json:"rule_type"` // ValidatingExceptRuleType / ValidatingDenyRuleType (see above) }
type RESTAdmissionRuleConfig ¶
type RESTAdmissionRuleConfig struct { ID uint32 `json:"id"` Category *string `json:"category"` Comment *string `json:"comment,omitempty"` Criteria []*RESTAdmRuleCriterion `json:"criteria,omitempty"` Disable *bool `json:"disable,omitempty"` Actions *[]string `json:"actions,omitempty"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) RuleType string `json:"rule_type"` // ValidatingExceptRuleType / ValidatingDenyRuleType (see above) }
Passed from manager to controller. Omit fields indicate that it's not modified.
type RESTAdmissionRuleConfigData ¶
type RESTAdmissionRuleConfigData struct {
Config *RESTAdmissionRuleConfig `json:"config"`
}
type RESTAdmissionRuleData ¶
type RESTAdmissionRuleData struct {
Rule *RESTAdmissionRule `json:"rule"`
}
type RESTAdmissionRuleOption ¶
type RESTAdmissionRulesData ¶
type RESTAdmissionRulesData struct {
Rules []*RESTAdmissionRule `json:"rules"`
}
type RESTAdmissionState ¶
type RESTAdmissionState struct { Enable *bool `json:"enable,omitempty"` Mode *string `json:"mode,omitempty"` DefaultAction *string `json:"default_action,omitempty"` AdmClientMode *string `json:"adm_client_mode,omitempty"` AdmSvcType *string `json:"adm_svc_type,omitempty"` FailurePolicy *string `json:"failure_policy,omitempty"` // "ignore" / "fail" AdmClientModeOptions map[string]string `json:"adm_client_mode_options,omitempty"` // key is AdmClientModeSvc or AdmClientModeUrl CtrlStates map[string]bool `json:"ctrl_states,omitempty"` // key is NvAdmValidateType CfgType string `json:"cfg_type"` // CfgTypeUserCreated / CfgTypeGround (see above) }
type RESTAdmissionStats ¶
type RESTAdmissionStats struct { K8sAllowedRequests uint64 `json:"k8s_allowed_requests"` K8sDeniedRequests uint64 `json:"k8s_denied_requests"` K8sErroneousRequests uint64 `json:"k8s_erroneous_requests"` K8sIgnoredRequests uint64 `json:"k8s_ignored_requests"` K8sProcessingRequests int64 `json:"k8s_processing_requests"` JenkinsAllowedRequests uint64 `json:"jenkins_allowed_requests"` // obsolete JenkinsDeniedRequests uint64 `json:"jenkins_denied_requests"` // obsolete JenkinsErroneousRequests uint64 `json:"jenkins_erroneous_requests"` // obsolete }
type RESTAdmissionStatsData ¶
type RESTAdmissionStatsData struct {
Stats *RESTAdmissionStats `json:"stats"`
}
type RESTAgent ¶
type RESTAgent struct { ID string `json:"id"` Name string `json:"name"` DisplayName string `json:"display_name"` HostName string `json:"host_name"` HostID string `json:"host_id"` Ver string `json:"version"` Labels map[string]string `json:"labels"` Domain string `json:"domain"` PidMode string `json:"pid_mode"` NetworkMode string `json:"network_mode"` CreatedAt string `json:"created_at"` StartedAt string `json:"started_at"` JoinedAt string `json:"joined_at"` MemoryLimit int64 `json:"memory_limit"` CPUs string `json:"cpus"` ClusterIP string `json:"cluster_ip"` State string `json:"connection_state"` DisconnAt string `json:"disconnected_at"` NvProtect bool `json:"nv_protect"` }
Although we can define shared fields in RESTAgent and RESTController in a common struct, it would make filter not working
type RESTAgentConfig ¶
type RESTAgentConfigData ¶
type RESTAgentConfigData struct {
Config *RESTAgentConfig `json:"config"`
}
type RESTAgentCounter ¶
type RESTAgentCounter struct { RXPackets uint64 `json:"rx_packets"` RXDropPackets uint64 `json:"rx_drop_packets"` TXPackets uint64 `json:"tx_packets"` TXDropPackets uint64 `json:"tx_drop_packets"` ErrorPackets uint64 `json:"error_packets"` NoWorkloadPackets uint64 `json:"no_workload_packets"` IPv4Packets uint64 `json:"ipv4_packets"` IPv6Packets uint64 `json:"ipv6_packets"` TCPPackets uint64 `json:"tcp_packets"` TCPNoSessionPackets uint64 `json:"tcp_no_session_packets"` UDPPackets uint64 `json:"udp_packets"` ICMPPackets uint64 `json:"icmp_packets"` OtherPackets uint64 `json:"other_packets"` Assemblys uint64 `json:"total_assemblys"` FreedAssemblys uint64 `json:"freed_assemblys"` Fragments uint64 `json:"total_fragments"` FreedFragments uint64 `json:"freed_fragments"` TimeoutFragments uint64 `json:"timeout_fragments"` TotalSessions uint64 `json:"total_sessions"` TCPSessions uint64 `json:"tcp_sessions"` UDPSessions uint64 `json:"udp_sessions"` ICMPSessions uint64 `json:"icmp_sessions"` IPSessions uint64 `json:"ip_sessions"` ParserSessions []uint64 `json:"parser_sessions"` ParserPackets []uint64 `json:"parser_packets"` DropMeters uint64 `json:"drop_meters"` ProxyMeters uint64 `json:"proxy_meters"` CurMeters uint64 `json:"cur_meters"` CurLogCaches uint64 `json:"cur_log_caches"` LimitDropConns uint64 `json:"limit_drop_conns"` LimitPassConns uint64 `json:"limit_pass_conns"` PolicyType1Rules uint32 `json:"policy_type1_rules"` PolicyType2Rules uint32 `json:"policy_type2_rules"` PolicyDomains uint32 `json:"policy_domains"` PolicyDomainIPs uint32 `json:"policy_domain_ips"` GoRoutines uint32 `json:"goroutines"` LsofOutput []string `json:"lsof"` PSOutput []string `json:"ps"` }
type RESTAgentCounterData ¶
type RESTAgentCounterData struct {
Counter *RESTAgentCounter `json:"counter"`
}
type RESTAgentData ¶
type RESTAgentData struct {
Agent *RESTAgent `json:"enforcer"`
}
type RESTAgentStatsData ¶
type RESTAgentsData ¶
type RESTAgentsData struct {
Agents []*RESTAgent `json:"enforcers"`
}
type RESTAllUserPermitOptions ¶
type RESTAllUserPermitOptions struct {
Options RESTUserPermitOptions `json:"options"`
}
type RESTAuditsData ¶
type RESTAuditsData struct {
Audits []*Audit `json:"audits"`
}
type RESTAuthData ¶
type RESTAuthData struct { ClientIP string `json:"client_ip"` Password *RESTAuthPassword `json:"password,omitempty"` Token *RESTAuthToken `json:"Token,omitempty"` }
type RESTAuthPassword ¶
type RESTAuthToken ¶
type RESTAwsCloudRes ¶
type RESTAwsCloudRes struct { CloudType string `json:"cloud_type"` ProjectName string `json:"project_name"` RegionList []string `json:"region_list"` // any new resource add name need start with aws_xxx, other parameter can't use it as UI use aws_xxx to filter ResLambda *RESTAwsLambdaRes `json:"aws_lambda_resource"` }
type RESTAwsFuncPermission ¶
type RESTAwsFuncPermission struct { AttachedPolicy bool `json:"aws_attached_policy"` PolicyLevel string `json:"policy_permission_level"` PermitState []string `json:"permission_state"` AllowedDetail map[string][]RESTAwsResDetail `json:"allowed_detail"` }
type RESTAwsFuncSummary ¶
type RESTAwsFuncSummary struct { FuncID string `json:"function_id"` Version string `json:"version"` FuncName string `json:"function_name"` ScanResult string `json:"scan_result"` HighVuls int `json:"high"` MedVuls int `json:"medium"` PermissionLevel string `json:"permission_level"` Status string `json:"status"` }
type RESTAwsFunction ¶
type RESTAwsFunction struct { FuncName string `json:"function_name"` Region string `json:"region"` Report []RESTScanAwsFuncReport `json:"report"` }
type RESTAwsLambdaRes ¶
type RESTAwsLambdaRes struct { Status string `json:"status"` RegionResMap map[string]*RESTAwsLambdaResDetail `json:"aws_region_resource"` }
type RESTAwsLambdaResDetail ¶
type RESTAwsLambdaResDetail struct { Status string `json:"status"` LambdaFunc []RESTAwsFuncSummary `json:"func_list"` }
type RESTAwsResDetail ¶
type RESTAwsResource ¶
type RESTAwsResource struct { AccID string `json:"acc_id,cloak"` AccKey string `json:"acc_key,cloak"` ProjectName string `json:"project_name"` RegionList []string `json:"region_list"` ResLambda *RESTAwsLambdaRes `json:"aws_lambda_resource"` }
type RESTAwsResourceConfig ¶
type RESTAwsResourceCreate ¶
type RESTBenchCheck ¶
type RESTBenchCheck struct { TestNum string `json:"test_number"` Catalog string `json:"catalog"` Type string `json:"type"` Profile string `json:"profile"` Scored bool `json:"scored"` Automated bool `json:"automated"` Description string `json:"description"` Remediation string `json:"remediation"` Tags []string `json:"tags"` }
type RESTBenchItem ¶
type RESTBenchMeta ¶
type RESTBenchMeta struct {
RESTBenchCheck
}
type RESTBenchReport ¶
type RESTBenchReport struct { RunAtTimeStamp int64 `json:"run_timestamp"` RunAt string `json:"run_at"` Version string `json:"cis_version"` Items []*RESTBenchItem `json:"items"` }
type RESTCloudResList ¶
type RESTCloudResList struct {
AwsCloudRes []RESTAwsCloudRes `json:"cloud_resources"`
}
type RESTComplianceAsset ¶
type RESTComplianceAsset struct { Name string `json:"name"` Catalog string `json:"catalog"` Type string `json:"type"` Level string `json:"level"` Profile string `json:"profile"` Scored bool `json:"scored"` Description string `json:"description"` Message []string `json:"message"` Remediation string `json:"remediation"` Group string `json:"group"` Tags []string `json:"tags"` Workloads []RESTIDName `json:"workloads"` Nodes []RESTIDName `json:"nodes"` Images []RESTIDName `json:"images"` Platforms []RESTIDName `json:"platforms"` }
type RESTComplianceAssetData ¶
type RESTComplianceAssetData struct { Compliances []*RESTComplianceAsset `json:"compliances"` KubeCategory string `json:"kubernetes_cis_category"` KubeVersion string `json:"kubernetes_cis_version"` DockerVersion string `json:"docker_cis_version"` }
type RESTComplianceData ¶
type RESTComplianceProfile ¶
type RESTComplianceProfile struct { Name string `json:"name"` DisableSystem bool `json:"disable_system"` Entries []RESTComplianceProfileEntry `json:"entries"` }
type RESTComplianceProfileConfig ¶
type RESTComplianceProfileConfig struct { Name string `json:"name"` DisableSystem *bool `json:"disable_system,omitempty"` Entries *[]*RESTComplianceProfileEntry `json:"entries,omitempty"` }
type RESTComplianceProfileConfigData ¶
type RESTComplianceProfileConfigData struct {
Config *RESTComplianceProfileConfig `json:"config"`
}
type RESTComplianceProfileData ¶
type RESTComplianceProfileData struct {
Profile *RESTComplianceProfile `json:"profile"`
}
type RESTComplianceProfileEntryConfigData ¶
type RESTComplianceProfileEntryConfigData struct {
Config *RESTComplianceProfileEntry `json:"config"`
}
type RESTComplianceProfilesData ¶
type RESTComplianceProfilesData struct {
Profiles []*RESTComplianceProfile `json:"profiles"`
}
type RESTController ¶
type RESTController struct { ID string `json:"id"` Name string `json:"name"` DisplayName string `json:"display_name"` HostName string `json:"host_name"` HostID string `json:"host_id"` Ver string `json:"version"` Labels map[string]string `json:"labels"` Domain string `json:"domain"` CreatedAt string `json:"created_at"` StartedAt string `json:"started_at"` JoinedAt string `json:"joined_at"` MemoryLimit int64 `json:"memory_limit"` CPUs string `json:"cpus"` ClusterIP string `json:"cluster_ip"` Leader bool `json:"leader"` State string `json:"connection_state"` DisconnAt string `json:"disconnected_at"` OrchConnStatus string `json:"orch_conn_status"` OrchConnLastError string `json:"orch_conn_last_error"` }
type RESTControllerConfig ¶
type RESTControllerConfig struct {
Debug *[]string `json:"debug,omitempty"`
}
type RESTControllerConfigData ¶
type RESTControllerConfigData struct {
Config *RESTControllerConfig `json:"config"`
}
type RESTControllerCounter ¶
type RESTControllerCounterData ¶
type RESTControllerCounterData struct {
Counter *RESTControllerCounter `json:"counter"`
}
type RESTControllerData ¶
type RESTControllerData struct {
Controller *RESTController `json:"controller"`
}
type RESTControllersData ¶
type RESTControllersData struct {
Controllers []*RESTController `json:"controllers"`
}
type RESTConversation ¶
type RESTConversation struct { From *RESTConversationEndpoint `json:"from"` To *RESTConversationEndpoint `json:"to"` *RESTConversationReport }
func (*RESTConversation) GetDomain ¶
func (o *RESTConversation) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
type RESTConversationCompact ¶
type RESTConversationCompact struct { From string `json:"from"` To string `json:"to"` *RESTConversationReport }
type RESTConversationDetail ¶
type RESTConversationDetail struct { *RESTConversation Entries []*RESTConversationEntry `json:"entries"` }
type RESTConversationEndpoint ¶
type RESTConversationEndpoint struct { Kind string `json:"kind"` RESTWorkloadBrief }
The difference between Endpoint list and Workload Brief list is, endpoint list container nv.host, nv.workload and nv.external.
func (*RESTConversationEndpoint) GetDomain ¶
func (o *RESTConversationEndpoint) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
type RESTConversationEndpointConfigData ¶
type RESTConversationEndpointConfigData struct {
Config *RESTConversationEndpointConfig `json:"config"`
}
type RESTConversationEndpointData ¶
type RESTConversationEndpointData struct {
Endpoints []*RESTConversationEndpoint `json:"endpoints"`
}
type RESTConversationEntry ¶
type RESTConversationEntry struct { Bytes uint64 `json:"bytes"` Sessions uint32 `json:"sessions"` Port string `json:"port"` MappedPort string `json:"mapped_port"` Application string `json:"application"` Server string `json:"Server"` ThreatName string `json:"threat_name"` Severity string `json:"severity"` PolicyAction string `json:"policy_action"` PolicyID uint32 `json:"policy_id"` LastSeenAt string `json:"last_seen_at"` CIP string `json:"client_ip"` SIP string `json:"server_ip"` Xff bool `json:"xff"` ToSidecar bool `json:"to_sidecar"` }
type RESTConversationQuery ¶
type RESTConversationQueryData ¶
type RESTConversationQueryData struct {
Query *RESTConversationQuery `json:"query"`
}
type RESTConversationReport ¶
type RESTConversationReport struct { Bytes uint64 `json:"bytes"` Sessions uint32 `json:"sessions"` Severity string `json:"severity"` PolicyAction string `json:"policy_action"` Protos []string `json:"protocols,omitempty"` Apps []string `json:"applications,omitempty"` Ports []string `json:"ports,omitempty"` SidecarProxy bool `json:"sidecar_proxy,omitempty"` EventType []string `json:"event_type,omitempty"` XffEntry bool `json:"xff_entry,omitempty"` //has xff entry }
type RESTConversationsData ¶
type RESTConversationsData struct { Endpoints []*RESTConversationEndpoint `json:"endpoints"` Convers []*RESTConversationCompact `json:"conversations"` }
type RESTConversationsDetailData ¶
type RESTConversationsDetailData struct {
Conver *RESTConversationDetail `json:"conversation"`
}
type RESTConversationsVerboseData ¶
type RESTConversationsVerboseData struct { Endpoints []*RESTConversationEndpoint `json:"endpoints"` Convers []*RESTConversation `json:"conversations"` }
type RESTCrdGroupConfig ¶
type RESTCrdGroupConfig struct { OriginalName string `json:"original_name"` Name string `json:"name"` Comment string `json:"comment"` Criteria *[]RESTCriteriaEntry `json:"criteria,omitempty"` }
type RESTCrdWafGroupConfig ¶
type RESTCrdWafGroupConfig struct { Name string `json:"name"` Status *bool `json:"status,omitempty"` RepSensors *[]RESTCrdWafGroupSetting `json:"replace,omitempty"` //replace list used by GUI }
type RESTCrdWafGroupSetting ¶
type RESTCriteriaEntry ¶
type RESTCustomCheck ¶
Custom check
type RESTCustomCheckConfig ¶
type RESTCustomCheckConfig struct { Add *RESTCustomChecks `json:"add"` Del *RESTCustomChecks `json:"delete"` Update *RESTCustomChecks `json:"update"` }
type RESTCustomCheckConfigData ¶
type RESTCustomCheckConfigData struct {
Config *RESTCustomCheckConfig `json:"config"`
}
type RESTCustomCheckData ¶
type RESTCustomCheckData struct {
Config *RESTCustomChecks `json:"config"`
}
type RESTCustomCheckListData ¶
type RESTCustomCheckListData struct {
Configs []*RESTCustomChecks `json:"configs"`
}
type RESTCustomChecks ¶
type RESTCustomChecks struct { Group string `json:"group"` Scripts []*RESTCustomCheck `json:"scripts"` }
type RESTDebugIP2Workload ¶
type RESTDebugIP2Workload struct { IP string `json:"ip"` Workload *RESTWorkloadBrief `json:"workload"` }
type RESTDebugIP2WorkloadData ¶
type RESTDebugIP2WorkloadData struct {
IP2Workloads []*RESTDebugIP2Workload `json:"ip_2_workloads"`
}
type RESTDebugSyncInfo ¶
type RESTDebugSyncInfo struct { ClusterIP string `json:"cluster_ip"` Leader bool `json:"leader"` SyncErrorFound bool `json:"sync_error_found"` LearnedRuleMax uint32 `json:"learned_rule_max"` GraphNodeCount uint32 `json:"graph_node_count"` PolicyError []*RESTPolicyMismatch `json:"policy_error,omitempty"` }
type RESTDebugSyncInfoData ¶
type RESTDebugSyncInfoData struct {
Sync []*RESTDebugSyncInfo `json:"sync"`
}
type RESTDeployFedRulesReq ¶
type RESTDeployFedRulesReq struct { Force bool `json:"force"` // true means deploying all federal rules. false means only deploying the newly changed federal rules. IDs []string `json:"ids"` // empty means deploy to all clusters }
for deploying fed settings to joint clusters
type RESTDeployFedRulesResp ¶
type RESTDerivedDlpRule ¶
type RESTDerivedDlpRuleData ¶
type RESTDerivedDlpRuleData struct {
Rules []*RESTDerivedDlpRule `json:"rules"`
}
type RESTDerivedDlpRuleMac ¶
type RESTDerivedDlpRuleMac struct {
Mac string `json:"mac"`
}
type RESTDerivedDlpRuleMacData ¶
type RESTDerivedDlpRuleMacData struct {
Macs []*RESTDerivedDlpRuleMac `json:"macs"`
}
type RESTDerivedPolicyRule ¶
type RESTDerivedPolicyRuleData ¶
type RESTDerivedPolicyRuleData struct {
WorkloadRules []*RESTDerivedWorkloadPolicyRule `json:"workload_rules"`
}
type RESTDerivedWorkloadDlpRule ¶
type RESTDerivedWorkloadDlpRule struct { DlpWorkload *RESTWorkloadBrief `json:"dlp_workload"` Mode string `json:"mode,omitempty"` DefAct uint32 `json:"defact,omitempty"` ApplyDir int32 `json:"applydir,omitempty"` DlpMacs []string `json:"dlp_macs"` DlpRules []*RESTDlpSetting `json:"dlp_rules"` WafRules []*RESTDlpSetting `json:"waf_rules"` Rids []uint32 `json:"rids"` Wafrids []uint32 `json:"wafrids"` RuleType string `json:"ruletype"` }
type RESTDerivedWorkloadDlpRuleData ¶
type RESTDerivedWorkloadDlpRuleData struct {
Rules []*RESTDerivedWorkloadDlpRule `json:"rules"`
}
type RESTDerivedWorkloadPolicyRule ¶
type RESTDerivedWorkloadPolicyRule struct { Workload *RESTWorkloadBrief `json:"workload"` Rules []*RESTDerivedPolicyRule `json:"rules"` }
type RESTDlpCriteriaEntry ¶
type RESTDlpGroup ¶
type RESTDlpGroup struct { Name string `json:"name"` Status bool `json:"status"` Sensors []*RESTDlpSetting `json:"sensors"` }
type RESTDlpGroupConfig ¶
type RESTDlpGroupConfig struct { Name string `json:"name"` Status *bool `json:"status,omitempty"` DelSensors *[]string `json:"delete,omitempty"` //delete list used by CLI Sensors *[]RESTDlpSetting `json:"sensors,omitempty"` //change list used by CLI RepSensors *[]RESTDlpSetting `json:"replace,omitempty"` //replace list used by GUI }
type RESTDlpGroupConfigData ¶
type RESTDlpGroupConfigData struct {
Config *RESTDlpGroupConfig `json:"config"`
}
type RESTDlpGroupData ¶
type RESTDlpGroupData struct {
DlpGroup *RESTDlpGroup `json:"dlp_group"`
}
type RESTDlpGroupsData ¶
type RESTDlpGroupsData struct {
DlpGroups []*RESTDlpGroup `json:"dlp_groups"`
}
type RESTDlpRule ¶
type RESTDlpRule struct { Name string `json:"name"` ID uint32 `json:"id"` Patterns []RESTDlpCriteriaEntry `json:"patterns"` }
type RESTDlpRuleConfig ¶
type RESTDlpRuleConfig struct { Name string `json:"name"` Patterns []RESTDlpCriteriaEntry `json:"patterns"` }
type RESTDlpRuleConfigData ¶
type RESTDlpRuleConfigData struct {
Config *RESTDlpRuleConfig `json:"config"`
}
type RESTDlpRuleData ¶
type RESTDlpRuleData struct {
Rule *RESTDlpRuleDetail `json:"rule"`
}
type RESTDlpRuleDetail ¶
type RESTDlpRuleDetail struct { Sensors []string `json:"sensors"` Rules []*RESTDlpRule `json:"rules"` }
type RESTDlpRulesData ¶
type RESTDlpRulesData struct {
Rules []*RESTDlpRule `json:"rules"`
}
type RESTDlpSensor ¶
type RESTDlpSensor struct { Name string `json:"name"` GroupList []string `json:"groups"` RuleList []*RESTDlpRule `json:"rules"` Comment string `json:"comment"` Predefine bool `json:"predefine"` }
type RESTDlpSensorConfig ¶
type RESTDlpSensorConfig struct { Name string `json:"name"` RuleChgList *[]RESTDlpRule `json:"change,omitempty"` //change list used by CLI RuleDelList *[]RESTDlpRule `json:"delete,omitempty"` //delete list used by CLI Rules *[]RESTDlpRule `json:"rules,omitempty"` //replace list used by GUI Comment *string `json:"comment,omitempty"` }
type RESTDlpSensorConfigData ¶
type RESTDlpSensorConfigData struct {
Config *RESTDlpSensorConfig `json:"config"`
}
type RESTDlpSensorData ¶
type RESTDlpSensorData struct {
Sensor *RESTDlpSensor `json:"sensor"`
}
type RESTDlpSensorsData ¶
type RESTDlpSensorsData struct {
Sensors []*RESTDlpSensor `json:"sensors"`
}
type RESTDlpSetting ¶
type RESTDomain ¶
type RESTDomainConfig ¶
type RESTDomainConfig struct {
TagPerDomain *bool `json:"tag_per_domain,omitempty"`
}
type RESTDomainConfigData ¶
type RESTDomainConfigData struct {
Config *RESTDomainConfig `json:"config"`
}
type RESTDomainEntryConfig ¶
type RESTDomainEntryConfigData ¶
type RESTDomainEntryConfigData struct {
Config *RESTDomainEntryConfig `json:"config"`
}
type RESTDomainsData ¶
type RESTDomainsData struct { Domains []*RESTDomain `json:"domains"` TagPerDomain bool `json:"tag_per_domain"` }
type RESTEULAData ¶
type RESTEULAData struct {
EULA *RESTEULA `json:"eula"`
}
type RESTError ¶
type RESTError struct { Code int `json:"code"` Error string `json:"error"` Message string `json:"message"` PwdProfileBasic *RESTPwdProfileBasic `json:"password_profile_basic,omitempty"` ImportTaskData *RESTImportTaskData `json:"import_task_data,omitempty"` }
type RESTErrorReadOnlyRules ¶
type RESTEventsData ¶
type RESTEventsData struct {
Events []*Event `json:"events"`
}
type RESTExposedEndpoint ¶
type RESTExposedEndpoint struct { ID string `json:"id"` Name string `json:"name"` DisplayName string `json:"display_name"` PodName string `json:"pod_name"` Service string `json:"service"` Severity string `json:"severity"` PolicyMode string `json:"policy_mode"` PolicyAction string `json:"policy_action"` Protos []string `json:"protocols,omitempty"` Apps []string `json:"applications,omitempty"` Ports []string `json:"ports,omitempty"` }
type RESTFedAuthData ¶
type RESTFedConfigData ¶
type RESTFedConfigData struct { PingInterval *uint32 `json:"ping_interval,omitempty"` // in minute PollInterval *uint32 `json:"poll_interval,omitempty"` // in minute Name *string `json:"name,omitempty"` // cluster name RestInfo *share.CLUSRestServerInfo `json:"rest_info,omitempty"` UseProxy *string `json:"use_proxy,omitempty"` // http / https }
type RESTFedInternalCommandReq ¶
type RESTFedInternalCommandReq struct { FedKvVersion string `json:"fed_kv_version"` // kv version in the code of master cluster Command string `json:"command"` // currently supported commands: _cmdPollFedRules / _cmdForcePullFedRules User string `json:"user"` // current operating user Revisions map[string]uint64 `json:"revisions"` // key is fed rules type, value is the revision of current fed rules }
type RESTFedInternalCommandResp ¶
type RESTFedInternalCommandResp struct {
Result int `json:"result"` // value: _fedCmdReceived/....
}
type RESTFedJoinReq ¶
type RESTFedJoinReq struct { Name string `json:"name"` // cluster name Server string `json:"server"` // server of master cluster Port uint `json:"port"` // port of master cluster JoinToken string `json:"join_token"` // generated by the master cluster, i.e. RESTFedJoinToken.JoinToken JointRestInfo *share.CLUSRestServerInfo `json:"joint_rest_info,omitempty"` // rest info about this joint cluster UseProxy *string `json:"use_proxy,omitempty"` }
type RESTFedJoinReqInternal ¶
type RESTFedJoinReqInternal struct { User string `json:"user"` // current operating user Remote string `json:"remote"` // current operating user's remote info UserRoles map[string]string `json:"user_roles"` // current operating user's roles FedKvVersion string `json:"fed_kv_version"` // kv version in the code of the joining cluster JoinTicket string `json:"join_ticket"` // generated by the master cluster, not containing master's server/port JointCluster RESTFedJointClusterInfo `json:"joint_cluster"` // info about joint cluster }
type RESTFedJoinRespInternal ¶
type RESTFedJoinRespInternal struct { PollInterval uint32 `json:"poll_interval"` // in minute CACert string `json:"ca_cert"` // ca cert for the federated rest server in master cluster ClientKey string `json:"client_key"` // client key for the joint cluster ClientCert string `json:"client_cert"` // client cert for the joint cluster MasterCluster *RESTFedMasterClusterInfo `json:"master_cluster"` // info about the master cluster }
type RESTFedJoinToken ¶
type RESTFedJoinToken struct {
JoinToken string `json:"join_token"`
}
type RESTFedJointClusterInfo ¶
type RESTFedJointClusterInfo struct { Disabled bool `json:"disabled"` Name string `json:"name"` // cluster name ID string `json:"id"` Secret string `json:"secret"` User string `json:"user"` // the user who joins this cluster to federation Status string `json:"status"` // ex: FedStatusClusterSynced/FedStatusClusterOutOfSync (see above) RestInfo share.CLUSRestServerInfo `json:"rest_info"` ProxyRequired bool `json:"proxy_required"` // a joint cluster may be reachable without proxy even master cluster is configured to use proxy. decided when it joins fed. }
type RESTFedLeaveReq ¶
type RESTFedLeaveReq struct {
Force bool `json:"force"` // true means leave federation no matter master cluster succeeds or not
}
type RESTFedLeaveReqInternal ¶
type RESTFedLeaveReqInternal struct { ID string `json:"id"` // id of the joint cluster to leave federation JointTicket string `json:"joint_ticket"` // generated using joint cluster's secret User string `json:"user"` // current operating user Remote string `json:"remote"` // current operating user's remote info UserRoles map[string]string `json:"user_roles"` // current operating user's roles }
for leaving federation request from joint clusters to master cluster
type RESTFedMasterClusterInfo ¶
type RESTFedMasterClusterInfo struct { Disabled bool `json:"disabled"` Name string `json:"name"` // cluster name ID string `json:"id"` Secret string `json:"secret"` // used for encryoting/decrypting join_ticket issued by the master cluster. never export User string `json:"user"` // the user who promoets this cluster to master cluster in federation Status string `json:"status"` // ex: FedStatusClusterSynced/FedStatusClusterOutOfSync (see above) RestInfo share.CLUSRestServerInfo `json:"rest_info"` }
master cluster: a promoted cluster. One per-federation joint cluster: the other non-master clusters that join the federation 1. A cluster becomes master cluster after it's promoted (providing the ip/port for other clusters to join) 2. A cluster can join one federation at most 3. A master cluster with joint cluster(s) cannot join other federation 4. A master cluster without any joint cluster can join another federation. At the same time it becomes joint cluster of another federation.
type RESTFedMembereshipData ¶
type RESTFedMembereshipData struct { FedRole string `json:"fed_role"` // FedRoleMaster / FedRoleJoint / FedRoleNone (see above) LocalRestInfo share.CLUSRestServerInfo `json:"local_rest_info"` // MasterCluster *RESTFedMasterClusterInfo `json:"master_cluster,omitempty"` // master cluster JointClusters []*RESTFedJointClusterInfo `json:"joint_clusters"` // all non-master clusters in the federation UseProxy string `json:"use_proxy"` // http / https }
type RESTFedPingReq ¶
type RESTFedPingResp ¶
type RESTFedPingResp struct {
Result int `json:"result"` // value: _fedSuccess/....
}
type RESTFedPromoteReqData ¶
type RESTFedPromoteReqData struct { Name string `json:"name,omitempty"` // cluster name PingInterval uint32 `json:"ping_interval"` // in minute PollInterval uint32 `json:"poll_interval"` // in minute MasterRestInfo *share.CLUSRestServerInfo `json:"master_rest_info,omitempty"` // rest info about this master cluster UseProxy *string `json:"use_proxy,omitempty"` // http / https }
type RESTFedPromoteRespData ¶
type RESTFedPromoteRespData struct { FedRole string `json:"fed_role"` MasterCluster RESTFedMasterClusterInfo `json:"master_cluster"` // info about this master cluster UseProxy string `json:"use_proxy,omitempty"` // http / https }
type RESTFedRemovedReqInternal ¶
type RESTFedRemovedReqInternal struct {
User string `json:"user"` // current operating user
}
type RESTFedRulesSettings ¶
type RESTFedRulesSettings struct { AdmCtrlRulesData *share.CLUSFedAdmCtrlRulesData `json:"admctrl_rules_data,omitempty"` NetworkRulesData *share.CLUSFedNetworkRulesData `json:"network_rules_data,omitempty"` ResponseRulesData *share.CLUSFedResponseRulesData `json:"response_rules_data,omitempty"` GroupsData *share.CLUSFedGroupsData `json:"groups_data,omitempty"` FileMonitorData *share.CLUSFedFileMonitorData `json:"file_monitor_data,omitempty"` ProcessProfilesData *share.CLUSFedProcessProfileData `json:"process_profiles_data,omitempty"` SystemConfigData *share.CLUSFedSystemConfigData `json:"system_config_data,omitempty"` }
type RESTFedSystemConfig ¶
type RESTFedSystemConfig struct {
Webhooks []RESTWebhook `json:"webhooks"`
}
fed system config
type RESTFedTokenResp ¶
type RESTFedTokenResp struct {
Token string `json:"token"` // for issued by remote joint cluster
}
type RESTFileMonitorConfig ¶
type RESTFileMonitorConfig struct { AddFilters []*RESTFileMonitorFilterConfig `json:"add_filters,omitempty"` DelFilters []*RESTFileMonitorFilterConfig `json:"delete_filters,omitempty"` UpdateFilters []*RESTFileMonitorFilterConfig `json:"update_filters,omitempty"` }
type RESTFileMonitorConfigData ¶
type RESTFileMonitorConfigData struct {
Config *RESTFileMonitorConfig `json:"config"`
}
type RESTFileMonitorFile ¶
type RESTFileMonitorFileData ¶
type RESTFileMonitorFileData struct {
Files []*RESTFileMonitorFile `json:"files"`
}
type RESTFileMonitorFilter ¶
type RESTFileMonitorFilter struct { Filter string `json:"filter"` Recursive bool `json:"recursive"` Behavior string `json:"behavior"` Apps []string `json:"applications"` CfgType string `json:"cfg_type"` Group string `json:"group,omitempty"` CreatedTimeStamp int64 `json:"created_timestamp"` UpdatedTimeStamp int64 `json:"last_modified_timestamp"` }
type RESTFileMonitorProfile ¶
type RESTFileMonitorProfile struct { Group string `json:"group"` Filters []*RESTFileMonitorFilter `json:"filters"` }
type RESTFileMonitorProfileData ¶
type RESTFileMonitorProfileData struct {
Profile *RESTFileMonitorProfile `json:"profile"`
}
type RESTFileMonitorProfilesData ¶
type RESTFileMonitorProfilesData struct {
Profiles []*RESTFileMonitorProfile `json:"profiles"`
}
type RESTGCRKey ¶
type RESTGCRKey struct {
JsonKey string `json:"json_key,cloak"`
}
type RESTGCRKeyConfig ¶
type RESTGCRKeyConfig struct {
JsonKey *string `json:"json_key,omitempty,cloak"`
}
type RESTGroup ¶
type RESTGroup struct { RESTGroupBrief Criteria []RESTCriteriaEntry `json:"criteria"` Members []*RESTWorkloadBrief `json:"members"` PolicyRules []uint32 `json:"policy_rules"` ResponseRules []uint32 `json:"response_rules"` }
type RESTGroupBatchDelete ¶
type RESTGroupBatchDelete struct {
Groups []string `json:"groups"`
}
type RESTGroupBrief ¶
type RESTGroupBrief struct { Name string `json:"name"` Comment string `json:"comment"` Learned bool `json:"learned"` Reserved bool `json:"reserved"` PolicyMode string `json:"policy_mode,omitempty"` ProfileMode string `json:"profile_mode,omitempty"` NotScored bool `json:"not_scored"` Domain string `json:"domain"` CreaterDomains []string `json:"creater_domains"` Kind string `json:"kind"` PlatformRole string `json:"platform_role"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) RESTGroupCaps }
type RESTGroupCaps ¶
type RESTGroupConfig ¶
type RESTGroupConfig struct { Name string `json:"name"` Comment *string `json:"comment"` Criteria *[]RESTCriteriaEntry `json:"criteria,omitempty"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) }
type RESTGroupConfigData ¶
type RESTGroupConfigData struct {
Config *RESTGroupConfig `json:"config"`
}
type RESTGroupData ¶
type RESTGroupData struct {
Group *RESTGroupDetail `json:"group"`
}
type RESTGroupDetail ¶
type RESTGroupDetail struct { RESTGroupBrief Criteria []RESTCriteriaEntry `json:"criteria"` Members []*RESTWorkloadBrief `json:"members"` PolicyRules []*RESTPolicyRule `json:"policy_rules"` ResponseRules []*RESTResponseRule `json:"response_rules"` }
type RESTGroupExport ¶
type RESTGroupsBriefData ¶
type RESTGroupsBriefData struct {
Groups []*RESTGroupBrief `json:"groups"`
}
type RESTGroupsData ¶
type RESTGroupsData struct {
Groups []*RESTGroup `json:"groups"`
}
type RESTHost ¶
type RESTHost struct { Name string `json:"name"` ID string `json:"id"` Runtime string `json:"runtime"` RuntimeVer string `json:"runtime_version"` RuntimeAPIVer string `json:"runtime_api_version"` Platform string `json:"platform"` OS string `json:"os"` Kernel string `json:"kernel"` CPUs int64 `json:"cpus"` Memory int64 `json:"memory"` CGroupVersion int `json:"cgroup_version"` Containers int `json:"containers"` Ifaces map[string][]*RESTIPAddr `json:"interfaces"` State string `json:"state"` CapDockerBench bool `json:"cap_docker_bench"` CapKubeBench bool `json:"cap_kube_bench"` DockerBenchStatus string `json:"docker_bench_status,omitempty"` KubeBenchStatus string `json:"kube_bench_status,omitempty"` PolicyMode string `json:"policy_mode"` ProfileMode string `json:"profile_mode"` ScanSummary *RESTScanBrief `json:"scan_summary"` StorageDriver string `json:"storage_driver"` Labels map[string]string `json:"labels"` Annotations map[string]string `json:"annotations"` }
type RESTHostData ¶
type RESTHostData struct {
Host *RESTHost `json:"host"`
}
type RESTHostsData ¶
type RESTHostsData struct {
Hosts []*RESTHost `json:"hosts"`
}
type RESTIBMSAConfig ¶
type RESTIBMSAConfig struct { AccountID string `json:"account_id"` APIKey string `json:"apikey"` ProviderID string `json:"provider_id"` // service-id FindingsURL string `json:"findings_url"` TokenURL string `json:"token_url"` OnboardNoteName string `json:"onboard_note_name"` OnboardID string `json:"onboard_id"` OnboardProviderID string `json:"onboard_provider_id"` }
type RESTIBMSASetupToken ¶
type RESTIBMSASetupToken struct {
AccessToken string `json:"access_token"`
}
type RESTIBMSASetupUrl ¶
type RESTIBMSASetupUrl struct {
URL string `json:"url"`
}
type RESTIDName ¶
type RESTIPAddr ¶
type RESTIPPort ¶
type RESTImportTask ¶
type RESTImportTask struct { TID string `json:"tid"` CtrlerID string `json:"ctrler_id"` LastUpdateTime time.Time `json:"last_update_time,omitempty"` Percentage int `json:"percentage"` TriggeredBy string `json:"triggered_by,omitempty"` // fullname of the user who triggers import Status string `json:"status,omitempty"` TempToken string `json:"temp_token,omitempty"` }
Import task
type RESTImportTaskData ¶
type RESTImportTaskData struct {
Data *RESTImportTask `json:"data"`
}
type RESTIncidentsData ¶
type RESTIncidentsData struct {
Incidents []*Incident `json:"incidents"`
}
type RESTInternalSubnets ¶
type RESTInternalSubnetsData ¶
type RESTInternalSubnetsData struct {
InternalSubnets *RESTInternalSubnets `json:"internal_subnets"`
}
type RESTInternalSystemData ¶
type RESTInternalSystemData struct { Metrics *RESTRiskScoreMetrics `json:"metrics"` Ingress []*RESTExposedEndpoint `json:"ingress"` Egress []*RESTExposedEndpoint `json:"egress"` }
type RESTLicenseCode ¶
type RESTLicenseCode struct {
LicenseCode string `json:"license_code"`
}
type RESTLicenseInfo ¶
type RESTLicenseInfo struct { Name string `json:"name"` Email string `json:"email"` Phone string `json:"phone"` ID string `json:"id,omitempty"` IDType string `json:"id_type,omitempty"` InstallationID string `json:"installation_id"` // nv installation id }
func (*RESTLicenseInfo) GetDomain ¶
func (o *RESTLicenseInfo) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
type RESTLicenseKey ¶
type RESTLicenseKey struct {
LicenseKey string `json:"license_key,cloak"`
}
type RESTLicenseKeyCfgMap ¶
type RESTLicenseKeyCfgMap struct { RESTLicenseKey AlwaysReload bool `json:"always_reload"` }
type RESTLicenseRequest ¶
type RESTLicenseRequestData ¶
type RESTLicenseRequestData struct {
Request *RESTLicenseRequest `json:"license_request"`
}
type RESTLicenseShow ¶
type RESTLicenseShow struct {
Info *RESTLicenseInfo `json:"info"`
}
type RESTLicenseShowData ¶
type RESTLicenseShowData struct {
License *RESTLicenseShow `json:"license"`
}
type RESTList ¶
type RESTList struct { Application []string `json:"application,omitempty"` RegistryType []string `json:"registry_type,omitempty"` Compliance []RESTBenchMeta `json:"compliance,omitempty"` }
type RESTListData ¶
type RESTListData struct {
List *RESTList `json:"list"`
}
type RESTMappableRoles ¶
type RESTMeter ¶
type RESTMeter struct { Type string `json:"type"` Workload string `json:"workload_id"` PeerIP string `json:"peer_ip"` Count uint32 `json:"cur_count"` SpanCount uint32 `json:"span_count"` Span uint8 `json:"span"` Tap bool `json:"tap"` Idle uint16 `json:"idle"` UpperLimit uint32 `json:"upper_limit"` LowerLimit uint32 `json:"lower_limit"` }
type RESTMeterList ¶
type RESTMeterList struct {
Meters []*RESTMeter `json:"meters"`
}
type RESTMetry ¶
type RESTMetry struct { CPU float64 `json:"cpu"` Memory uint64 `json:"memory"` SessionIn uint32 `json:"session_in"` SessionOut uint32 `json:"session_out"` SessionCurIn uint32 `json:"cur_session_in,omitempty"` SessionCurOut uint32 `json:"cur_session_out,omitempty"` PacketIn uint64 `json:"packet_in"` PacketOut uint64 `json:"packet_out"` ByteIn uint64 `json:"byte_in"` ByteOut uint64 `json:"byte_out"` }
type RESTModuleCve ¶
type RESTPolicyMismatch ¶
type RESTPolicyMismatch struct { ClusterRule *RESTPolicyRule `json:"cluster_rule"` LearnedRule *RESTPolicyRule `json:"learned_rule"` }
type RESTPolicyPromoteRequest ¶
type RESTPolicyPromoteRequest struct {
IDs []uint32 `json:"ids"`
}
type RESTPolicyPromoteRequestData ¶
type RESTPolicyPromoteRequestData struct {
Request *RESTPolicyPromoteRequest `json:"request"`
}
type RESTPolicyRule ¶
type RESTPolicyRule struct { ID uint32 `json:"id"` Comment string `json:"comment"` From string `json:"from"` // group name To string `json:"to"` // group name Ports string `json:"ports"` // free-style port list Action string `json:"action"` Applications []string `json:"applications"` Learned bool `json:"learned"` Disable bool `json:"disable"` CreatedTS int64 `json:"created_timestamp"` LastModTS int64 `json:"last_modified_timestamp"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) Priority uint32 `json:"priority"` }
type RESTPolicyRuleActionData ¶
type RESTPolicyRuleActionData struct { Move *RESTPolicyRuleMove `json:"move,omitempty"` Insert *RESTPolicyRuleInsert `json:"insert,omitempty"` Rules *[]*RESTPolicyRule `json:"rules,omitempty"` Delete *[]uint32 `json:"delete,omitempty"` }
type RESTPolicyRuleConfig ¶
type RESTPolicyRuleConfig struct { ID uint32 `json:"id"` Comment *string `json:"comment,omitempty"` From *string `json:"from,omitempty"` // group name To *string `json:"to,omitempty"` // group name Ports *string `json:"ports,omitempty"` // free-style port list Action *string `json:"action,omitempty"` Applications *[]string `json:"applications,omitempty"` Disable *bool `json:"disable,omitempty"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) Priority uint32 `json:"priority,omitempty"` }
Omit fields indicate that it's not modified.
type RESTPolicyRuleConfigData ¶
type RESTPolicyRuleConfigData struct { Config *RESTPolicyRuleConfig `json:"config"` Replicate bool `json:"replicate,omitempty"` }
type RESTPolicyRuleData ¶
type RESTPolicyRuleData struct {
Rule *RESTPolicyRule `json:"rule"`
}
type RESTPolicyRuleInsert ¶
type RESTPolicyRuleInsert struct { // nil: last; 0: first; +id: after rule 'id'; -id: before rule 'id' After *int `json:"after,omitempty"` Rules []*RESTPolicyRule `json:"rules"` }
type RESTPolicyRuleMove ¶
type RESTPolicyRulesData ¶
type RESTPolicyRulesData struct {
Rules []*RESTPolicyRule `json:"rules"`
}
type RESTPolicyViolationsData ¶
type RESTPolicyViolationsData struct {
Violations []*Violation `json:"violations"`
}
type RESTPolicyViolationsWLData ¶
type RESTPolicyViolationsWLData struct {
ViolationWorkloads []*RESTViolationWorkload `json:"violation_workloads"`
}
type RESTPollFedRulesReq ¶
type RESTPollFedRulesReq struct { ID string `json:"id"` // id of joint cluster Name string `json:"name"` // name of joint cluster JointTicket string `json:"joint_ticket"` // generated using joint cluster's secret FedKvVersion string `json:"fed_kv_version"` // kv version in the code of joint cluster Revisions map[string]uint64 `json:"revisions"` // key is fed rules type, value is the revision }
for polling fed rules/settings from joint clusters to master cluster
type RESTPollFedRulesResp ¶
type RESTPollFedRulesResp struct { Result int `json:"result"` // value: _fedSuccess/.... PollInterval uint32 `json:"poll_interval"` // in minute Settings []byte `json:"settings"` // marshall of RESTFedRulesSettings Revisions map[string]uint64 `json:"revisions"` // key is fed rules type, value is the revision }
type RESTProbeContainer ¶
type RESTProbeContainersData ¶
type RESTProbeContainersData struct {
Containers []*RESTProbeContainer `json:"containers"`
}
type RESTProbeProcess ¶
type RESTProbeProcess struct { Pid int32 `json:"pid"` Ppid int32 `json:"ppid"` Name string `json:"name"` Ruid uint32 `json:"ruid"` Euid uint32 `json:"euid"` ScanTimes uint32 `json:"scan_times"` StartTime uint64 `json:"start_times"` Reported uint32 `json:"reported"` Container string `json:"container"` }
type RESTProbeProcessesData ¶
type RESTProbeProcessesData struct {
Processes []*RESTProbeProcess `json:"processes"`
}
type RESTProbeSummary ¶
type RESTProbeSummary struct { ContainerMap uint32 `json:"containers"` PidContainerMap uint32 `json:"pid_containers"` PidProcMap uint32 `json:"pid_procs"` NewProcesses uint32 `json:"new_procs"` NewSuspicProc uint32 `json:"new_suspicious_procs"` ContainerStops uint32 `json:"stopped_container"` PidSet uint32 `json:"pids"` SessionTable uint32 `json:"host_sessions"` }
type RESTProbeSummaryData ¶
type RESTProbeSummaryData struct {
Summary *RESTProbeSummary `json:"summary"`
}
type RESTProcessInfo ¶
type RESTProcessInfo struct { Name string `json:"name"` Pid uint32 `json:"pid"` Parent uint32 `json:"parent"` Group uint32 `json:"group"` Session uint32 `json:"session"` Cmdline string `json:"cmdline"` Root bool `json:"root"` User string `json:"user"` Status string `json:"status"` StartAtTimeStamp int64 `json:"start_timestamp"` Action string `json:"action"` }
type RESTProcessList ¶
type RESTProcessList struct {
Processes []*RESTProcessInfo `json:"processes"`
}
type RESTProcessProfile ¶
type RESTProcessProfileConfig ¶
type RESTProcessProfileConfig struct { Group string `json:"group"` AlertDisable *bool `json:"alert_disabled,omitempty"` HashEnable *bool `json:"hash_enabled,omitempty"` Baseline *string `json:"baseline,omitempty"` ProcessChgList *[]RESTProcessProfileEntryConfig `json:"process_change_list,omitempty"` ProcessDelList *[]RESTProcessProfileEntryConfig `json:"process_delete_list,omitempty"` ProcessRepList *[]RESTProcessProfileEntryConfig `json:"process_replace_list,omitempty"` }
type RESTProcessProfileConfigData ¶
type RESTProcessProfileConfigData struct {
Config *RESTProcessProfileConfig `json:"process_profile_config"`
}
type RESTProcessProfileData ¶
type RESTProcessProfileData struct {
Profile *RESTProcessProfile `json:"process_profile"`
}
type RESTProcessProfileEntry ¶
type RESTProcessProfileEntry struct { Name string `json:"name"` Path string `json:"path,omitempty"` User string `json:"user,omitempty"` Uid int32 `json:"uid,omitempty"` Action string `json:"action"` CfgType string `json:"cfg_type"` Uuid string `json:"uuid"` Group string `json:"group,omitempty"` AllowFileUpdate bool `json:"allow_update"` CreatedTimeStamp int64 `json:"created_timestamp"` UpdatedTimeStamp int64 `json:"last_modified_timestamp"` }
type RESTProcessProfilesData ¶
type RESTProcessProfilesData struct {
Profiles []*RESTProcessProfile `json:"process_profiles"`
}
type RESTProcessRuleResp ¶
type RESTProcessRuleResp struct {
Entry *RESTProcessUuidEntry `json:"process_rule"`
}
type RESTProcessRulesResp ¶
type RESTProcessRulesResp struct {
Entries []RESTProcessUuidEntry `json:"process_rules"`
}
type RESTProcessUuidEntry ¶
type RESTProcessUuidEntry struct { Active int `json:"active"` Group string `json:"group"` Rule RESTProcessProfileEntry `json:"rule"` }
uuid for process rules
type RESTProfiling ¶
type RESTProfilingData ¶
type RESTProfilingData struct {
Profiling *RESTProfiling `json:"profiling"`
}
type RESTProtoPort ¶
type RESTPwdProfile ¶
type RESTPwdProfile struct { Name string `json:"name"` Comment string `json:"comment"` MinLen int `json:"min_len"` MinUpperCount int `json:"min_uppercase_count"` // for alphabet characters MinLowerCount int `json:"min_lowercase_count"` // for alphabet characters MinDigitCount int `json:"min_digit_count"` MinSpecialCount int `json:"min_special_count"` EnablePwdExpiration bool `json:"enable_password_expiration"` PwdExpireAfterDays int `json:"password_expire_after_days"` // must be > 0 when EnablePwdExpiration is true EnablePwdHistory bool `json:"enable_password_history"` PwdHistoryCount int `json:"password_keep_history_count"` EnableBlockAfterFailedLogin bool `json:"enable_block_after_failed_login"` // for "Block X minutes after N times consecutive failed attempts" BlockAfterFailedCount int `json:"block_after_failed_login_count"` // must be > 0 when EnableBlockAfterFailedLogin is true BlockMinutes int `json:"block_minutes"` // must be > 0 when EnableBlockAfterFailedLogin is true }
password profile
type RESTPwdProfileBasic ¶
type RESTPwdProfileBasic struct { MinLen int `json:"min_len"` MinUpperCount int `json:"min_uppercase_count"` // for alphabet characters MinLowerCount int `json:"min_lowercase_count"` // for alphabet characters MinDigitCount int `json:"min_digit_count"` MinSpecialCount int `json:"min_special_count"` }
type RESTPwdProfileConditional ¶
type RESTPwdProfileConditional struct { Name *string `json:"name,omitempty"` Comment *string `json:"comment,omitempty"` MinLen int `json:"min_len"` MinUpperCount int `json:"min_uppercase_count"` // for alphabet characters MinLowerCount int `json:"min_lowercase_count"` // for alphabet characters MinDigitCount int `json:"min_digit_count"` MinSpecialCount int `json:"min_special_count"` EnablePwdExpiration *bool `json:"enable_password_expiration,omitempty"` PwdExpireAfterDays *int `json:"password_expire_after_days,omitempty"` // must be > 0 when EnablePwdExpiration is true EnablePwdHistory *bool `json:"enable_password_history,omitempty"` PwdHistoryCount *int `json:"password_keep_history_count,omitempty"` EnableBlockAfterFailedLogin *bool `json:"enable_block_after_failed_login,omitempty"` // for "Block X minutes after N times consecutive failed attempts" BlockAfterFailedCount *int `json:"block_after_failed_login_count,omitempty"` // must be > 0 when EnableBlockAfterFailedLogin is true BlockMinutes *int `json:"block_minutes,omitempty"` // must be > 0 when EnableBlockAfterFailedLogin is true }
type RESTPwdProfileConfig ¶
type RESTPwdProfileConfig struct { Name string `json:"name"` Active *bool `json:"active,omitempty"` Comment *string `json:"comment,omitempty"` MinLen *int `json:"min_len,omitempty"` MinUpperCount *int `json:"min_uppercase_count,omitempty"` // for alphabet characters MinLowerCount *int `json:"min_lowercase_count,omitempty"` // for alphabet characters MinDigitCount *int `json:"min_digit_count,omitempty"` // for 0 ~ 9 MinSpecialCount *int `json:"min_special_count,omitempty"` // !”#$%&'()*+,-./:;<=>?@[\]^_`{|}~ EnablePwdExpiration *bool `json:"enable_password_expiration,omitempty"` PwdExpireAfterDays *int `json:"password_expire_after_days,omitempty"` // must be > 0 when EnablePwdExpiration is true EnablePwdHistory *bool `json:"enable_password_history,omitempty"` PwdHistoryCount *int `json:"password_keep_history_count,omitempty"` EnableBlockAfterFailedLogin *bool `json:"enable_block_after_failed_login,omitempty"` // for "Block X minutes after N times consecutive failed attempts" BlockAfterFailedCount *int `json:"block_after_failed_login_count,omitempty"` // must be > 0 when EnableBlockAfterFailedLogin is true BlockMinutes *int `json:"block_minutes,omitempty"` // must be > 0 when EnableBlockAfterFailedLogin is true }
type RESTPwdProfileConfigData ¶
type RESTPwdProfileConfigData struct {
Config *RESTPwdProfileConfig `json:"config"`
}
type RESTPwdProfileData ¶
type RESTPwdProfileData struct {
PwdProfile *RESTPwdProfile `json:"pwd_profile"`
}
type RESTPwdProfileDataConditional ¶
type RESTPwdProfileDataConditional struct {
PwdProfile *RESTPwdProfileConditional `json:"pwd_profile"`
}
type RESTPwdProfilesData ¶
type RESTPwdProfilesData struct { PwdProfiles []*RESTPwdProfile `json:"pwd_profiles"` ActiveProfileName string `json:"active_profile_name"` }
type RESTPwdProfilesDataCfgMap ¶
type RESTPwdProfilesDataCfgMap struct { RESTPwdProfilesData AlwaysReload bool `json:"always_reload"` }
type RESTRegistry ¶
type RESTRegistry struct { Name string `json:"name"` Type string `json:"registry_type"` Registry string `json:"registry"` Username string `json:"username"` Password string `json:"password,cloak"` AuthToken string `json:"auth_token,cloak"` AuthWithToken bool `json:"auth_with_token"` Domains []string `json:"domains"` Filters []string `json:"filters"` RescanImage bool `json:"rescan_after_db_update"` ScanLayers bool `json:"scan_layers"` RepoLimit int `json:"repo_limit"` TagLimit int `json:"tag_limit"` Schedule RESTScanSchedule `json:"schedule"` AwsKey *RESTAWSAccountKey `json:"aws_key,omitempty"` GcrKey *RESTGCRKey `json:"gcr_key,omitempty"` JfrogMode string `json:"jfrog_mode"` JfrogAQL bool `json:"jfrog_aql"` GitlabApiUrl string `json:"gitlab_external_url"` GitlabPrivateToken string `json:"gitlab_private_token,cloak"` IBMCloudTokenURL string `json:"ibm_cloud_token_url"` IBMCloudAccount string `json:"ibm_cloud_account"` }
type RESTRegistryConfig ¶
type RESTRegistryConfig struct { Name string `json:"name"` Type string `json:"registry_type"` Registry *string `json:"registry,omitempty"` Domains *[]string `json:"domains,omitempty"` Filters *[]string `json:"filters,omitempty"` Username *string `json:"username,omitempty"` Password *string `json:"password,omitempty,cloak"` AuthToken *string `json:"auth_token,omitempty,cloak"` AuthWithToken *bool `json:"auth_with_token,omitempty"` RescanImage *bool `json:"rescan_after_db_update,omitempty"` ScanLayers *bool `json:"scan_layers,omitempty"` RepoLimit *int `json:"repo_limit,omitempty"` TagLimit *int `json:"tag_limit,omitempty"` Schedule *RESTScanSchedule `json:"schedule,omitempty"` AwsKey *RESTAWSAccountKeyConfig `json:"aws_key,omitempty"` GcrKey *RESTGCRKeyConfig `json:"gcr_key,omitempty"` JfrogMode *string `json:"jfrog_mode,omitempty"` JfrogAQL *bool `json:"jfrog_aql,omitempty"` GitlabApiUrl *string `json:"gitlab_external_url,omitempty"` GitlabPrivateToken *string `json:"gitlab_private_token,omitempty,cloak"` IBMCloudTokenURL *string `json:"ibm_cloud_token_url,omitempty"` IBMCloudAccount *string `json:"ibm_cloud_account,omitempty"` }
type RESTRegistryConfigData ¶
type RESTRegistryConfigData struct {
Config *RESTRegistryConfig `json:"config"`
}
type RESTRegistryDebugImage ¶
type RESTRegistryDebugImage struct { Domain string `json:"domain"` Repository string `json:"repository"` Tags []*RESTRegistryDebugImageTag `json:"tags"` }
type RESTRegistryDebugImageData ¶
type RESTRegistryDebugImageData struct {
Images []*RESTRegistryDebugImage `json:"images"`
}
type RESTRegistryImageSummary ¶
type RESTRegistryImageSummary struct { Domain string `json:"domain"` Repository string `json:"repository"` Tag string `json:"tag"` ImageID string `json:"image_id"` Digest string `json:"digest"` Size int64 `json:"size"` Author string `json:"author"` RunAsRoot bool `json:"run_as_root"` Envs []string `json:"envs"` Labels map[string]string `json:"labels"` Layers []string `json:"layers"` RESTScanBrief }
type RESTRegistryImageSummaryData ¶
type RESTRegistryImageSummaryData struct {
Images []*RESTRegistryImageSummary `json:"images"`
}
type RESTRegistrySummary ¶
type RESTRegistrySummary struct { RESTRegistry Status string `json:"status"` ErrMsg string `json:"error_message"` ErrDetail string `json:"error_detail"` StartedAt string `json:"started_at"` RESTScanStatus }
type RESTRegistrySummaryData ¶
type RESTRegistrySummaryData struct {
Summary *RESTRegistrySummary `json:"summary"`
}
type RESTRegistrySummaryListData ¶
type RESTRegistrySummaryListData struct {
Summarys []*RESTRegistrySummary `json:"summarys"`
}
type RESTRegistryTestData ¶
type RESTRegistryTestData struct {
Config *RESTRegistry `json:"config"`
}
type RESTRegistryTestStep ¶
type RESTRegistryTestStepData ¶
type RESTRegistryTestStepData struct {
Steps []*RESTRegistryTestStep `json:"steps"`
}
type RESTResponseRule ¶
type RESTResponseRule struct { ID uint32 `json:"id"` Event string `json:"event"` Comment string `json:"comment"` Group string `json:"group"` Conditions []share.CLUSEventCondition `json:"conditions"` Actions []string `json:"actions"` Webhooks []string `json:"webhooks"` Disable bool `json:"disable"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) }
type RESTResponseRuleActionData ¶
type RESTResponseRuleActionData struct {
Insert *RESTResponseRuleInsert `json:"insert,omitempty"`
}
type RESTResponseRuleConfig ¶
type RESTResponseRuleConfig struct { ID uint32 `json:"id"` Comment *string `json:"comment,omitempty"` Group *string `json:"group,omitempty"` Event *string `json:"event,omitempty"` Conditions *[]share.CLUSEventCondition `json:"conditions,omitempty"` Actions *[]string `json:"actions,omitempty"` Webhooks *[]string `json:"webhooks,omitempty"` Disable *bool `json:"disable,omitempty"` CfgType string `json:"cfg_type"` // CfgTypeLearned / CfgTypeUserCreated / CfgTypeGround / CfgTypeFederal (see above) }
Omit fields indicate that it's not modified.
type RESTResponseRuleConfigData ¶
type RESTResponseRuleConfigData struct {
Config *RESTResponseRuleConfig `json:"config"`
}
type RESTResponseRuleData ¶
type RESTResponseRuleData struct {
Rule *RESTResponseRule `json:"rule"`
}
type RESTResponseRuleInsert ¶
type RESTResponseRuleInsert struct { // nil: last; 0: first; +id: after rule 'id'; -id: before rule 'id' After *int `json:"after,omitempty"` Rules []*RESTResponseRule `json:"rules"` }
type RESTResponseRuleOptionData ¶
type RESTResponseRuleOptionData struct { Options map[string]*RESTResponseRuleOptions `json:"response_rule_options"` Webhooks []string `json:"webhooks"` }
type RESTResponseRuleOptions ¶
type RESTResponseRulesData ¶
type RESTResponseRulesData struct {
Rules []*RESTResponseRule `json:"rules"`
}
type RESTRiskScoreMetrics ¶
type RESTRiskScoreMetrics struct { Platform string `json:"platform"` K8sVersion string `json:"kube_version"` OCVersion string `json:"openshift_version"` NewServiceMode string `json:"new_service_policy_mode"` DiscoverGroups int `json:"discover_groups"` MonitorGroups int `json:"monitor_groups"` ProtectGroups int `json:"protect_groups"` Groups int `json:"groups"` RunningPods int `json:"running_pods"` PrivilegedWLs int `json:"privileged_wls"` RootWLs int `json:"root_wls"` DenyAdmCtrlRules int `json:"deny_adm_ctrl_rules"` DiscoverCVEs int `json:"discover_cves"` MonitorCVEs int `json:"monitor_cves"` ProtectCVEs int `json:"protect_cves"` PlatformCVEs int `json:"platform_cves"` HostCVEs int `json:"host_cves"` Hosts int `json:"hosts"` DiscoverExtEPs int `json:"discover_ext_eps"` MonitorExtEPs int `json:"monitor_ext_eps"` ProtectExtEPs int `json:"protect_ext_eps"` ThrtExtEPs int `json:"threat_ext_eps"` VioExtEPs int `json:"violate_ext_eps"` }
type RESTRolePermission ¶
type RESTRolePermitOptionInternal ¶
type RESTRolePermitOptionInternal struct { ID string Value uint64 SupportScope byte // 1: support global scope, 2: support domain scope, 3: support both scopes ReadSupported bool WriteSupported bool // non-nil only for complex permissions like PERM_RUNTIME_POLICIES. PERM_RUNTIME_POLICIES is visible to client but in controller it's PERM_NETWORK_POLICY + PERM_SYSTEM_POLICY ComplexPermits []*RESTRolePermitOptionInternal }
type RESTScanAppPackage ¶
type RESTScanAwsFuncDetail ¶
type RESTScanAwsFuncDetail struct { RESTScanBrief `json:"scan_brief"` RESTScanReport `json:"scan_report"` }
type RESTScanAwsFuncReport ¶
type RESTScanAwsFuncReport struct { FuncID string `json:"function_id"` NvSecID string `json:"nv_sec_id"` Version string `json:"version"` ScanResult RESTScanAwsFuncDetail `json:"scan_result"` AllowedRes map[string]RESTAwsFuncPermission `json:"allowed_resources"` // key: resource_name value: list of func in res ReqRes map[string]RESTAwsFuncPermission `json:"req_resources"` // key: resource_name value: list of func in res }
type RESTScanBrief ¶
type RESTScanBrief struct { Status string `json:"status"` HighVuls int `json:"high"` MedVuls int `json:"medium"` Result string `json:"result"` ScannedTimeStamp int64 `json:"scanned_timestamp"` ScannedAt string `json:"scanned_at"` BaseOS string `json:"base_os"` CVEDBVersion string `json:"scanner_version"` CVEDBCreateTime string `json:"cvedb_create_time"` }
type RESTScanConfig ¶
type RESTScanConfig struct {
AutoScan bool `json:"auto_scan"`
}
type RESTScanConfigData ¶
type RESTScanConfigData struct {
Config *RESTScanConfig `json:"config"`
}
type RESTScanImageSummary ¶
type RESTScanImageSummary struct { Image string `json:"image"` ImageID string `json:"image_id"` Author string `json:"author"` RESTScanBrief }
type RESTScanImageSummaryData ¶
type RESTScanImageSummaryData struct {
Summary []*RESTScanImageSummary `json:"images"`
}
type RESTScanLayer ¶
type RESTScanLayer struct { Digest string `json:"digest"` Cmds string `json:"cmds"` Vuls []*RESTVulnerability `json:"vulnerabilities"` Size int64 `json:"size"` }
type RESTScanLayersReport ¶
type RESTScanLayersReport struct {
Layers []*RESTScanLayer `json:"layers"`
}
type RESTScanLayersReportData ¶
type RESTScanLayersReportData struct {
Report *RESTScanLayersReport `json:"report"`
}
type RESTScanMeta ¶
type RESTScanModule ¶
type RESTScanModule struct { Name string `json:"name"` Version string `json:"version"` Source string `json:"source"` CVEs []*RESTModuleCve `json:"cves,omitempty"` CPEs []string `json:"cpes,omitempty"` }
type RESTScanPackageReqData ¶
type RESTScanPackageReqData struct { ProjectName string `json:"project_name"` FunctionName string `json:"function_name"` Region string `json:"region"` AppPkgs []RESTScanAppPackage `json:"application_packages"` }
type RESTScanPkgReport ¶
type RESTScanPkgReport struct { Verdict string `json:"verdict,omitempty"` NvSecId string `json:"nv_sec_id"` CVEDBVersion string `json:"cvedb_version"` CVEDBCreateTime string `json:"cvedb_create_time"` Vuls []*RESTVulnerability `json:"vulnerabilities"` }
type RESTScanPkgReportData ¶
type RESTScanPkgReportData struct {
Report *RESTScanPkgReport `json:"report"`
}
type RESTScanPlatformSummary ¶
type RESTScanPlatformSummary struct { Platform string `json:"platform"` K8sVersion string `json:"kube_version"` OCVersion string `json:"openshift_version"` RESTScanBrief }
type RESTScanPlatformSummaryData ¶
type RESTScanPlatformSummaryData struct {
Summary []*RESTScanPlatformSummary `json:"platforms"`
}
type RESTScanRepoReport ¶
type RESTScanRepoReport struct { Verdict string `json:"verdict,omitempty"` ImageID string `json:"image_id"` Registry string `json:"registry"` Repository string `json:"repository"` Tag string `json:"tag"` Digest string `json:"digest"` Size int64 `json:"size"` Author string `json:"author"` BaseOS string `json:"base_os"` CVEDBVersion string `json:"cvedb_version"` CVEDBCreateTime string `json:"cvedb_create_time"` Layers []*RESTScanLayer `json:"layers"` RESTScanReport }
type RESTScanRepoReportData ¶
type RESTScanRepoReportData struct {
Report *RESTScanRepoReport `json:"report"`
}
type RESTScanRepoReq ¶
type RESTScanRepoReq struct { Metadata RESTScanMeta `json:"metadata"` Registry string `json:"registry"` Username string `json:"username,omitempty"` Password string `json:"password,omitempty"` Repository string `json:"repository"` Tag string `json:"tag"` ScanLayers bool `json:"scan_layers"` BaseImage string `json:"base_image"` }
type RESTScanRepoReqData ¶
type RESTScanRepoReqData struct {
Request *RESTScanRepoReq `json:"request"`
}
type RESTScanRepoSubmitData ¶
type RESTScanRepoSubmitData struct {
Result *share.ScanResult `json:"result"`
}
This is for scanner to summit the scan result
type RESTScanReport ¶
type RESTScanReport struct { Vuls []*RESTVulnerability `json:"vulnerabilities"` Modules []*RESTScanModule `json:"modules,omitempty"` Checks []*RESTBenchItem `json:"checks,omitempty"` Secrets []*RESTScanSecret `json:"secrets,omitempty"` SetIDs []*RESTScanSetIdPerm `json:"setid_perms,omitempty"` Envs []string `json:"envs,omitempty"` Labels map[string]string `json:"labels,omitempty"` Cmds []string `json:"cmds,omitempty"` }
type RESTScanReportData ¶
type RESTScanReportData struct {
Report *RESTScanReport `json:"report"`
}
type RESTScanSchedule ¶
type RESTScanSecret ¶
type RESTScanSetIdPerm ¶
type RESTScanStatus ¶
type RESTScanStatus struct { Scanned int `json:"scanned"` Scheduled int `json:"scheduled"` Scanning int `json:"scanning"` Failed int `json:"failed"` CVEDBVersion string `json:"cvedb_version"` CVEDBCreateTime string `json:"cvedb_create_time"` }
func (*RESTScanStatus) GetDomain ¶
func (o *RESTScanStatus) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
type RESTScanStatusData ¶
type RESTScanStatusData struct {
Status *RESTScanStatus `json:"status"`
}
type RESTScanner ¶
type RESTScanner struct { ID string `json:"id"` CVEDBVersion string `json:"cvedb_version"` CVEDBCreateTime string `json:"cvedb_create_time"` JoinedTS int64 `json:"joined_timestamp"` RPCServer string `json:"server"` RPCServerPort uint16 `json:"port"` Containers int `json:"scanned_containers"` Hosts int `json:"scanned_hosts"` Images int `json:"scanned_images"` Serverless int `json:"scanned_serverless"` }
type RESTScannerData ¶
type RESTScannerData struct {
Scanners []*RESTScanner `json:"scanners"`
}
type RESTSecurityData ¶
type RESTSelfUserData ¶
type RESTServer ¶
type RESTServer struct { Name string `json:"server_name"` Type string `json:"server_type"` LDAP *RESTServerLDAP `json:"ldap,omitempty"` SAML *RESTServerSAML `json:"saml,omitempty"` OIDC *RESTServerOIDC `json:"oidc,omitempty"` }
type RESTServerConfig ¶
type RESTServerConfig struct { Name string `json:"name"` LDAP *RESTServerLDAPConfig `json:"ldap,omitempty"` SAML *RESTServerSAMLConfig `json:"saml,omitempty"` OIDC *RESTServerOIDCConfig `json:"oidc,omitempty"` }
type RESTServerConfigData ¶
type RESTServerConfigData struct {
Config *RESTServerConfig `json:"config"`
}
type RESTServerData ¶
type RESTServerData struct {
Server *RESTServer `json:"server"`
}
type RESTServerGroupRoleConfigData ¶
type RESTServerGroupRoleConfigData struct {
Groups []string `json:"groups"`
}
type RESTServerGroupRoleDomainsConfig ¶
type RESTServerGroupRoleDomainsConfig struct { Name string `json:"name"` // server name GroupRoleMapping *share.GroupRoleMapping `json:"mapped_roles,omitempty"` }
Used by CLI to set one group's role mapping at a time.
type RESTServerGroupRoleDomainsConfigData ¶
type RESTServerGroupRoleDomainsConfigData struct {
Config *RESTServerGroupRoleDomainsConfig `json:"config"`
}
type RESTServerGroupsOrderConfig ¶
type RESTServerGroupsOrderConfig struct { Name string `json:"name"` // server name Groups []string `json:"groups"` // groups in mapping order }
Used by CLI to set mapped groups order.
type RESTServerGroupsOrderConfigData ¶
type RESTServerGroupsOrderConfigData struct {
Config *RESTServerGroupsOrderConfig `json:"config"`
}
type RESTServerLDAP ¶
type RESTServerLDAP struct { Type string `json:"directory"` Hostname string `json:"hostname"` Port uint16 `json:"port"` SSL bool `json:"ssl"` BaseDN string `json:"base_dn"` BindDN string `json:"bind_dn"` BindPasswd string `json:"bind_password,cloak"` GroupMemberAttr string `json:"group_member_attr"` UserNameAttr string `json:"username_attr"` Enable bool `json:"enable"` DefaultRole string `json:"default_role"` RoleGroups map[string][]string `json:"role_groups,omitempty"` // role -> groups GroupMappedRoles []*share.GroupRoleMapping `json:"group_mapped_roles,omitempty"` // group -> (role -> domains) }
type RESTServerLDAPConfig ¶
type RESTServerLDAPConfig struct { Type *string `json:"directory,omitempty"` Hostname *string `json:"hostname,omitempty"` Port *uint16 `json:"port,omitempty"` SSL *bool `json:"ssl,omitempty"` BaseDN *string `json:"base_dn,omitempty"` BindDN *string `json:"bind_dn,omitempty"` BindPasswd *string `json:"bind_password,cloak,omitempty"` GroupMemberAttr *string `json:"group_member_attr,omitempty"` UserNameAttr *string `json:"username_attr,omitempty"` Enable *bool `json:"enable,omitempty"` DefaultRole *string `json:"default_role,omitempty"` RoleGroups *map[string][]string `json:"role_groups,omitempty"` // role -> groups. deprecated since 4.2 GroupMappedRoles *[]*share.GroupRoleMapping `json:"group_mapped_roles,omitempty"` // group -> (role -> domains) }
type RESTServerLDAPConfigCfgMap ¶
type RESTServerLDAPConfigCfgMap struct { RESTServerLDAPConfig AlwaysReload bool `json:"always_reload"` }
type RESTServerLDAPTest ¶
type RESTServerOIDC ¶
type RESTServerOIDC struct { Issuer string `json:"issuer"` AuthURL string `json:"authorization_endpoint"` TokenURL string `json:"token_endpoint"` UserInfoURL string `json:"user_info_endpoint"` ClientID string `json:"client_id"` ClientSecret string `json:"client_secret,cloak"` GroupClaim string `json:"group_claim"` Scopes []string `json:"scopes"` Enable bool `json:"enable"` DefaultRole string `json:"default_role"` RoleGroups map[string][]string `json:"role_groups,omitempty"` // role -> groups GroupMappedRoles []*share.GroupRoleMapping `json:"group_mapped_roles,omitempty"` // group -> (role -> domains) }
type RESTServerOIDCConfig ¶
type RESTServerOIDCConfig struct { Issuer *string `json:"issuer"` ClientID *string `json:"client_id"` ClientSecret *string `json:"client_secret,cloak"` GroupClaim *string `json:"group_claim"` Scopes *[]string `json:"scopes,omitempty"` Enable *bool `json:"enable"` DefaultRole *string `json:"default_role"` RoleGroups *map[string][]string `json:"role_groups,omitempty"` // role -> groups. deprecated since 4.2 GroupMappedRoles *[]*share.GroupRoleMapping `json:"group_mapped_roles,omitempty"` // group -> (role -> domains) }
type RESTServerOIDCConfigCfgMap ¶
type RESTServerOIDCConfigCfgMap struct { RESTServerOIDCConfig AlwaysReload bool `json:"always_reload"` }
type RESTServerRoleGroupsConfig ¶
type RESTServerRoleGroupsConfig struct { Name string `json:"name"` Role string `json:"role"` Groups []string `json:"groups"` }
Used by CLI to set one role mapping at a time.
type RESTServerRoleGroupsConfigData ¶
type RESTServerRoleGroupsConfigData struct {
Config *RESTServerRoleGroupsConfig `json:"config"`
}
type RESTServerSAML ¶
type RESTServerSAML struct { SSOURL string `json:"sso_url"` Issuer string `json:"issuer"` X509Cert string `json:"x509_cert,cloak"` GroupClaim string `json:"group_claim"` Enable bool `json:"enable"` DefaultRole string `json:"default_role"` RoleGroups map[string][]string `json:"role_groups,omitempty"` // role -> groups GroupMappedRoles []*share.GroupRoleMapping `json:"group_mapped_roles,omitempty"` // group -> (role -> domains) }
type RESTServerSAMLConfig ¶
type RESTServerSAMLConfig struct { SSOURL *string `json:"sso_url"` Issuer *string `json:"issuer"` X509Cert *string `json:"x509_cert,cloak"` GroupClaim *string `json:"group_claim"` Enable *bool `json:"enable,omitempty"` DefaultRole *string `json:"default_role,omitempty"` RoleGroups *map[string][]string `json:"role_groups,omitempty"` // role -> groups. deprecated since 4.2 GroupMappedRoles *[]*share.GroupRoleMapping `json:"group_mapped_roles,omitempty"` // group -> (role -> domains) }
type RESTServerSAMLConfigCfgMap ¶
type RESTServerSAMLConfigCfgMap struct { RESTServerSAMLConfig AlwaysReload bool `json:"always_reload"` }
type RESTServerTest ¶
type RESTServerTest struct { Name string `json:"name,omitempty"` // either name or one of server configs must present LDAP *RESTServerLDAPConfig `json:"ldap,omitempty"` TestLDAP *RESTServerLDAPTest `json:"test_ldap,omitempty"` }
type RESTServerTestData ¶
type RESTServerTestData struct {
Test *RESTServerTest `json:"test"`
}
type RESTServerTestResult ¶
type RESTServerTestResult struct {
Groups []string `json:"groups"`
}
type RESTServerTestResultData ¶
type RESTServerTestResultData struct {
Result *RESTServerTestResult `json:"result"`
}
type RESTServersData ¶
type RESTServersData struct { Servers []*RESTServer `json:"servers"` MappableRoles *RESTMappableRoles `json:"mappable_roles"` }
type RESTService ¶
type RESTService struct { Name string `json:"name"` Comment string `json:"comment"` PolicyMode string `json:"policy_mode"` ProfileMode string `json:"profile_mode"` NotScored bool `json:"not_scored"` Domain string `json:"domain"` PlatformRole string `json:"platform_role"` Members []*RESTWorkloadBrief `json:"members"` PolicyRules []*RESTPolicyRule `json:"policy_rules"` ResponseRules []*RESTResponseRule `json:"response_rules"` ServiceAddr *RESTIPPort `json:"service_addr,omitempty"` IngressExposure bool `json:"ingress_exposure"` EgressExposure bool `json:"egress_exposure"` RESTGroupCaps }
type RESTServiceBatchConfig ¶
type RESTServiceBatchConfigData ¶
type RESTServiceBatchConfigData struct {
Config *RESTServiceBatchConfig `json:"config"`
}
type RESTServiceConfig ¶
type RESTServiceConfigData ¶
type RESTServiceConfigData struct {
Config *RESTServiceConfig `json:"config"`
}
type RESTServiceData ¶
type RESTServiceData struct {
Service *RESTService `json:"service"`
}
type RESTServicesData ¶
type RESTServicesData struct {
Services []*RESTService `json:"services"`
}
type RESTSession ¶
type RESTSession struct { ID uint64 `json:"id"` Workload string `json:"workload_id"` EtherType uint16 `json:"ether_type"` Application string `json:"application"` ClientMAC string `json:"client_mac"` ServerMAC string `json:"server_mac"` ClientIP string `json:"client_ip"` ServerIP string `json:"server_ip"` ClientPort uint16 `json:"client_port"` ServerPort uint16 `json:"server_port"` ICMPCode uint8 `json:"icmp_code"` ICMPType uint8 `json:"icmp_type"` IPProto uint8 `json:"ip_proto"` ClientState string `json:"client_state"` ServerState string `json:"server_state"` ClientPkts uint32 `json:"client_pkts"` ServerPkts uint32 `json:"server_pkts"` ClientBytes uint64 `json:"client_bytes"` ServerBytes uint64 `json:"server_bytes"` ClientAsmPkts uint32 `json:"client_asm_pkts"` ServerAsmPkts uint32 `json:"server_asm_pkts"` ClientAsmBytes uint64 `json:"client_asm_bytes"` ServerAsmBytes uint64 `json:"server_asm_bytes"` Age uint32 `json:"age"` Idle uint32 `json:"idle"` Life uint32 `json:"life"` Ingress bool `json:"ingress"` Tap bool `json:"tap"` MidStream bool `json:"mid_stream"` PolicyID uint32 `json:"policy_id"` PolicyAction string `json:"policy_action"` XffIP string `json:"xff_ip"` XffApp string `json:"xff_app"` XffPort uint16 `json:"xff_port"` }
type RESTSessionList ¶
type RESTSessionList struct {
Sessions []*RESTSession `json:"sessions"`
}
type RESTSessionSummary ¶
type RESTSessionSummaryData ¶
type RESTSessionSummaryData struct {
Summary *RESTSessionSummary `json:"summary"`
}
type RESTSnifferArgs ¶
type RESTSnifferArgsData ¶
type RESTSnifferArgsData struct {
Sniffer *RESTSnifferArgs `json:"sniffer"`
}
type RESTSnifferData ¶
type RESTSnifferData struct {
Sniffer *RESTSnifferInfo `json:"sniffer"`
}
type RESTSnifferInfo ¶
type RESTSnifferInfo struct { ID string `json:"id"` AgentID string `json:"enforcer_id"` WorkloadID string `json:"container_id"` FileNumber uint32 `json:"file_number"` Size int64 `json:"size"` Status string `json:"status"` Args string `json:"args"` StartTime int64 `json:"start_time"` StopTime int64 `json:"stop_time"` }
type RESTSnifferResult ¶
type RESTSnifferResult struct {
ID string `json:"id"`
}
type RESTSnifferResultData ¶
type RESTSnifferResultData struct {
Result *RESTSnifferResult `json:"result"`
}
type RESTSniffersData ¶
type RESTSniffersData struct {
Sniffers []*RESTSnifferInfo `json:"sniffers"`
}
type RESTSystemConfig ¶
type RESTSystemConfig struct { NewServicePolicyMode string `json:"new_service_policy_mode"` NewServiceProfileBaseline string `json:"new_service_profile_baseline"` UnusedGroupAging uint8 `json:"unused_group_aging"` SyslogServer string `json:"syslog_ip"` SyslogIPProto uint8 `json:"syslog_ip_proto"` SyslogPort uint16 `json:"syslog_port"` SyslogLevel string `json:"syslog_level"` SyslogEnable bool `json:"syslog_status"` SyslogCategories []string `json:"syslog_categories"` SyslogInJSON bool `json:"syslog_in_json"` SingleCVEPerSyslog bool `json:"single_cve_per_syslog"` AuthOrder []string `json:"auth_order"` AuthByPlatform bool `json:"auth_by_platform"` InternalSubnets []string `json:"configured_internal_subnets,omitempty"` Webhooks []RESTWebhook `json:"webhooks"` ClusterName string `json:"cluster_name"` ControllerDebug []string `json:"controller_debug"` MonitorServiceMesh bool `json:"monitor_service_mesh"` RegistryHttpProxyEnable bool `json:"registry_http_proxy_status"` RegistryHttpsProxyEnable bool `json:"registry_https_proxy_status"` RegistryHttpProxy RESTProxy `json:"registry_http_proxy"` RegistryHttpsProxy RESTProxy `json:"registry_https_proxy"` IBMSAEpEnabled bool `json:"ibmsa_ep_enabled"` IBMSAEpStart uint32 `json:"ibmsa_ep_start"` IBMSAEpDashboardURL string `json:"ibmsa_ep_dashboard_url"` IBMSAEpConnectedAt string `json:"ibmsa_ep_connected_at"` XffEnabled bool `json:"xff_enabled"` }
If more log servers needed, they can be defined as servers.
type RESTSystemConfigConfig ¶
type RESTSystemConfigConfig struct { NewServicePolicyMode *string `json:"new_service_policy_mode,omitempty"` NewServiceProfileBaseline *string `json:"new_service_profile_baseline,omitempty"` UnusedGroupAging *uint8 `json:"unused_group_aging,omitempty"` SyslogServer *string `json:"syslog_ip,omitempty"` SyslogIPProto *uint8 `json:"syslog_ip_proto,omitempty"` SyslogPort *uint16 `json:"syslog_port,omitempty"` SyslogLevel *string `json:"syslog_level,omitempty"` SyslogEnable *bool `json:"syslog_status,omitempty"` SyslogCategories *[]string `json:"syslog_categories,omitempty"` SyslogInJSON *bool `json:"syslog_in_json,omitempty"` SingleCVEPerSyslog *bool `json:"single_cve_per_syslog"` AuthOrder *[]string `json:"auth_order,omitempty"` AuthByPlatform *bool `json:"auth_by_platform,omitempty"` WebhookEnable *bool `json:"webhook_status,omitempty"` // deprecated, kept for backward-compatibility, skip docs WebhookUrl *string `json:"webhook_url,omitempty"` // deprecated, kept for backward-compatibility, skip docs Webhooks *[]*RESTWebhook `json:"webhooks,omitempty"` ClusterName *string `json:"cluster_name,omitempty"` ControllerDebug *[]string `json:"controller_debug,omitempty"` MonitorServiceMesh *bool `json:"monitor_service_mesh,omitempty"` RegistryHttpProxyEnable *bool `json:"registry_http_proxy_status,omitempty"` RegistryHttpsProxyEnable *bool `json:"registry_https_proxy_status,omitempty"` RegistryHttpProxy *RESTProxy `json:"registry_http_proxy,omitempty"` RegistryHttpsProxy *RESTProxy `json:"registry_https_proxy,omitempty"` IBMSAEpEnabled *bool `json:"ibmsa_ep_enabled,omitempty"` IBMSAEpDashboardURL *string `json:"ibmsa_ep_dashboard_url,omitempty"` XffEnabled *bool `json:"xff_enabled,omitempty"` }
type RESTSystemConfigConfigCfgMap ¶
type RESTSystemConfigConfigCfgMap struct { RESTSystemConfigConfig AlwaysReload bool `json:"always_reload"` }
type RESTSystemConfigConfigData ¶
type RESTSystemConfigConfigData struct { Config *RESTSystemConfigConfig `json:"config"` FedConfig *RESTSystemConfigConfig `json:"fed_config"` }
type RESTSystemConfigData ¶
type RESTSystemConfigData struct { Config *RESTSystemConfig `json:"config"` FedConfig *RESTFedSystemConfig `json:"fed_config"` }
type RESTSystemRequest ¶
type RESTSystemRequest struct { PolicyMode *string `json:"policy_mode,omitempty"` Unquar *RESTUnquarReq `json:"unquarantine,omitempty"` }
type RESTSystemRequestData ¶
type RESTSystemRequestData struct {
Request *RESTSystemRequest `json:"request"`
}
type RESTSystemStats ¶
type RESTSystemStats struct { ExpiredTokens int `json:"expired_tokens"` ScanStateKeys int `json:"scan_state_keys"` ScanDataKeys int `json:"scan_data_keys"` }
func (*RESTSystemStats) GetDomain ¶
func (o *RESTSystemStats) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
type RESTSystemStatsData ¶
type RESTSystemStatsData struct {
Stats *RESTSystemStats `json:"stats"`
}
type RESTSystemSummary ¶
type RESTSystemSummary struct { Hosts int `json:"hosts"` Controllers int `json:"controllers"` Agents int `json:"enforcers"` OfflineAgents int `json:"disconnected_enforcers"` Domains int `json:"domains"` Workloads int `json:"workloads"` RunningWorkloads int `json:"running_workloads"` RunningPods int `json:"running_pods"` Services int `json:"services"` PolicyRules int `json:"policy_rules"` Scanners int `json:"scanners"` Platform string `json:"platform"` K8sVersion string `json:"kube_version"` OCVersion string `json:"openshift_version"` CVEDBVersion string `json:"cvedb_version"` CVEDBCreateTime string `json:"cvedb_create_time"` CompoVersions []string `json:"component_versions"` }
type RESTSystemSummaryData ¶
type RESTSystemSummaryData struct {
Summary *RESTSystemSummary `json:"summary"`
}
type RESTSystemUsageReport ¶
type RESTSystemUsageReport struct { Signature string `json:"signature"` ReportedTS int64 `json:"reported_timestamp"` ReportedAt string `json:"reported_at"` Platform string `json:"platform"` Hosts int `json:"hosts"` CPUCores int `json:"cores"` Controllers int `json:"controllers"` Agents int `json:"enforcers"` Scanners int `json:"scanners"` CVEDBVersion string `json:"cvedb_version"` Registries int `json:"registries"` Domains int `json:"domains"` RunningPods int `json:"running_pods"` Groups int `json:"groups"` MonitorGroups int `json:"monitor_groups"` ProtectGroups int `json:"protect_groups"` PolicyRules int `json:"policy_rules"` AdmCtrlRules int `json:"adm_ctrl_rules"` RespRules int `json:"response_rules"` CRDRules int `json:"crd_rules"` Clusters int `json:"clusters"` SLessProjs int `json:"sl_projs"` InstallationID string `json:"installation_id"` }
func (*RESTSystemUsageReport) GetDomain ¶
func (o *RESTSystemUsageReport) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
type RESTSystemUsageReportData ¶
type RESTSystemUsageReportData struct {
Usage []*RESTSystemUsageReport `json:"usage"`
}
type RESTSystemWebhookConfigData ¶
type RESTSystemWebhookConfigData struct {
Config *RESTWebhook `json:"config"`
}
type RESTThreatData ¶
type RESTThreatData struct {
Threat *Threat `json:"threat"`
}
type RESTThreatsData ¶
type RESTThreatsData struct {
Threats []*Threat `json:"threats"`
}
type RESTToken ¶
type RESTToken struct { Token string `json:"token"` GlobalPermits []*RESTRolePermission `json:"global_permissions"` DomainPermits map[string][]*RESTRolePermission `json:"domain_permissions"` // domain -> permissions RESTUser }
type RESTTokenAuthServer ¶
type RESTTokenAuthServersData ¶
type RESTTokenAuthServersData struct {
Servers []*RESTTokenAuthServer `json:"servers"`
}
type RESTTokenAuthServersRedirectData ¶
type RESTTokenAuthServersRedirectData struct {
Redirect *RESTTokenAuthServerRedirect `json:"redirect"`
}
type RESTTokenData ¶
type RESTTokenRedirect ¶
type RESTTokenRedirect struct {
Redirect string `json:"redirect_endpoint"`
}
type RESTUnquarReq ¶
type RESTUser ¶
type RESTUser struct { Fullname string `json:"fullname"` Server string `json:"server"` Username string `json:"username"` Password string `json:"password,cloak"` EMail string `json:"email"` Role string `json:"role"` Timeout uint32 `json:"timeout"` Locale string `json:"locale"` DefaultPWD bool `json:"default_password"` // If the user is using default password ModifyPWD bool `json:"modify_password"` // if the password should be modified RoleDomains map[string][]string `json:"role_domains,omitempty"` // role -> domains LastLoginTimeStamp int64 `json:"last_login_timestamp"` LastLoginAt string `json:"last_login_at"` LoginCount uint32 `json:"login_count"` BlockedForFailedLogin bool `json:"blocked_for_failed_login"` // if the user is blocked for too mnay failed login BlockedForPwdExpired bool `json:"blocked_for_password_expired"` // if the user is blocked for expired password }
type RESTUserConfig ¶
type RESTUserConfig struct { Fullname string `json:"fullname"` Password *string `json:"password,omitempty,cloak"` NewPassword *string `json:"new_password,omitempty,cloak"` PwdProfile *string `json:"pwd_profile"` EMail *string `json:"email,omitempty"` Role *string `json:"role,omitempty"` Timeout *uint32 `json:"timeout,omitempty"` Locale *string `json:"locale,omitempty"` RoleDomains *map[string][]string `json:"role_domains,omitempty"` // role -> domains }
type RESTUserConfigData ¶
type RESTUserConfigData struct {
Config *RESTUserConfig `json:"config"`
}
type RESTUserData ¶
type RESTUserData struct {
User *RESTUser `json:"user"`
}
type RESTUserPermitOption ¶
type RESTUserPermitOption struct { ID string `json:"id"` ReadSupported bool `json:"read_supported"` WriteSupported bool `json:"write_supported"` }
custom role
type RESTUserPermitOptions ¶
type RESTUserPermitOptions struct { GlobalOptions []*RESTUserPermitOption `json:"global_options"` DomainOptions []*RESTUserPermitOption `json:"domain_options"` }
type RESTUserPwdConfig ¶
type RESTUserPwdConfigData ¶
type RESTUserPwdConfigData struct {
Config *RESTUserPwdConfig `json:"config"`
}
type RESTUserRole ¶
type RESTUserRole struct { Name string `json:"name"` Comment string `json:"comment"` Reserved bool `json:"reserved"` // true for pre-defined roles Permissions []*RESTRolePermission `json:"permissions"` }
type RESTUserRoleConfig ¶
type RESTUserRoleConfig struct { Name string `json:"name"` Comment string `json:"comment"` Permissions []*RESTRolePermission `json:"permissions"` }
type RESTUserRoleConfigData ¶
type RESTUserRoleConfigData struct {
Config *RESTUserRoleConfig `json:"config"`
}
type RESTUserRoleData ¶
type RESTUserRoleData struct {
Role *RESTUserRole `json:"role"`
}
type RESTUserRoleDomainsConfig ¶
type RESTUserRoleDomainsConfig struct { Fullname string `json:"fullname"` Role string `json:"role"` Domains []string `json:"domains"` }
Used by CLI to set one role domain at a time.
type RESTUserRoleDomainsConfigData ¶
type RESTUserRoleDomainsConfigData struct {
Config *RESTUserRoleDomainsConfig `json:"config"`
}
type RESTUserRolesData ¶
type RESTUserRolesData struct {
Roles []*RESTUserRole `json:"roles"`
}
type RESTUserRolesDataCfgMap ¶
type RESTUserRolesDataCfgMap struct { RESTUserRolesData AlwaysReload bool `json:"always_reload"` }
type RESTUsersData ¶
type RESTUsersDataCfgMap ¶
type RESTUsersDataCfgMap struct { RESTUsersData AlwaysReload bool `json:"always_reload"` }
type RESTViolationWorkload ¶
type RESTViolationWorkload struct { Workload *RESTWorkloadBrief `json:"workload"` Count int `json:"count"` }
type RESTVulnPackageVersion ¶
type RESTVulnerability ¶
type RESTVulnerability struct { Name string `json:"name"` Score float32 `json:"score"` Severity string `json:"severity"` Vectors string `json:"vectors"` Description string `json:"description"` PackageName string `json:"package_name"` PackageVersion string `json:"package_version"` FixedVersion string `json:"fixed_version"` Link string `json:"link"` ScoreV3 float32 `json:"score_v3"` VectorsV3 string `json:"vectors_v3"` PublishedTS int64 `json:"published_timestamp"` LastModTS int64 `json:"last_modified_timestamp"` CPEs []string `json:"cpes,omitempty"` CVEs []string `json:"cves,omitempty"` FeedRating string `json:"feed_rating"` InBaseImage bool `json:"in_base_image"` Tags []string `json:"tags,omitempty"` }
type RESTVulnerabilityAsset ¶
type RESTVulnerabilityAsset struct { Name string `json:"name"` Severity string `json:"severity"` Description string `json:"description"` Packages map[string][]RESTVulnPackageVersion `json:"packages` PackageName string `json:"package_name"` // deprecated in 4.3.3 Link string `json:"link"` Score float32 `json:"score"` Vectors string `json:"vectors"` ScoreV3 float32 `json:"score_v3"` VectorsV3 string `json:"vectors_v3"` PublishedTS int64 `json:"published_timestamp"` LastModTS int64 `json:"last_modified_timestamp"` PackageVersions []RESTVulnPackageVersion `json:"package_versions"` // deprecated in 4.3.3 Workloads []RESTIDName `json:"workloads"` Nodes []RESTIDName `json:"nodes"` Images []RESTIDName `json:"images"` Platforms []RESTIDName `json:"platforms"` }
type RESTVulnerabilityAssetData ¶
type RESTVulnerabilityAssetData struct {
Vuls []*RESTVulnerabilityAsset `json:"vulnerabilities"`
}
type RESTVulnerabilityProfile ¶
type RESTVulnerabilityProfile struct { Name string `json:"name"` Entries []RESTVulnerabilityProfileEntry `json:"entries"` }
type RESTVulnerabilityProfileConfig ¶
type RESTVulnerabilityProfileConfig struct { Name string `json:"name"` Entries *[]*RESTVulnerabilityProfileEntry `json:"entries,omitempty"` }
type RESTVulnerabilityProfileConfigData ¶
type RESTVulnerabilityProfileConfigData struct {
Config *RESTVulnerabilityProfileConfig `json:"config"`
}
type RESTVulnerabilityProfileData ¶
type RESTVulnerabilityProfileData struct {
Profile *RESTVulnerabilityProfile `json:"profile"`
}
type RESTVulnerabilityProfileEntryConfigData ¶
type RESTVulnerabilityProfileEntryConfigData struct {
Config *RESTVulnerabilityProfileEntry `json:"config"`
}
type RESTVulnerabilityProfilesData ¶
type RESTVulnerabilityProfilesData struct {
Profiles []*RESTVulnerabilityProfile `json:"profiles"`
}
type RESTWafConfig ¶
type RESTWafCriteriaEntry ¶
type RESTWafGroup ¶
type RESTWafGroup struct { Name string `json:"name"` Status bool `json:"status"` Sensors []*RESTWafSetting `json:"sensors"` CfgType string `json:"cfg_type"` // CfgTypeUserCreated / CfgTypeGround }
type RESTWafGroupConfig ¶
type RESTWafGroupConfig struct { Name string `json:"name"` Status *bool `json:"status,omitempty"` DelSensors *[]string `json:"delete,omitempty"` //delete list used by CLI Sensors *[]RESTWafConfig `json:"sensors,omitempty"` //change list used by CLI RepSensors *[]RESTWafConfig `json:"replace,omitempty"` //replace list used by GUI }
type RESTWafGroupConfigData ¶
type RESTWafGroupConfigData struct {
Config *RESTWafGroupConfig `json:"config"`
}
type RESTWafGroupData ¶
type RESTWafGroupData struct {
WafGroup *RESTWafGroup `json:"waf_group"`
}
type RESTWafGroupsData ¶
type RESTWafGroupsData struct {
WafGroups []*RESTWafGroup `json:"waf_groups"`
}
type RESTWafRule ¶
type RESTWafRule struct { Name string `json:"name"` // simple rule anme ID uint32 `json:"id"` Patterns []RESTWafCriteriaEntry `json:"patterns"` CfgType string `json:"cfg_type"` }
type RESTWafRuleData ¶
type RESTWafRuleData struct {
Rule *RESTWafRuleDetail `json:"rule"`
}
type RESTWafRuleDetail ¶
type RESTWafRuleDetail struct { Sensors []string `json:"sensors"` Rules []*RESTWafRule `json:"rules"` }
type RESTWafRulesData ¶
type RESTWafRulesData struct {
Rules []*RESTWafRule `json:"rules"`
}
type RESTWafSensor ¶
type RESTWafSensorConfig ¶
type RESTWafSensorConfig struct { Name string `json:"name"` RuleChgList *[]RESTWafRule `json:"change,omitempty"` //change list used by CLI RuleDelList *[]RESTWafRule `json:"delete,omitempty"` //delete list used by CLI Rules *[]RESTWafRule `json:"rules,omitempty"` //replace list used by GUI Comment *string `json:"comment,omitempty"` }
type RESTWafSensorConfigData ¶
type RESTWafSensorConfigData struct {
Config *RESTWafSensorConfig `json:"config"`
}
type RESTWafSensorData ¶
type RESTWafSensorData struct {
Sensor *RESTWafSensor `json:"sensor"`
}
type RESTWafSensorExport ¶
type RESTWafSensorExport struct {
Names []string `json:"names"`
}
type RESTWafSensorsData ¶
type RESTWafSensorsData struct {
Sensors []*RESTWafSensor `json:"sensors"`
}
type RESTWafSetting ¶
type RESTWebhook ¶
type RESTWorkload ¶
type RESTWorkload struct { RESTWorkloadBrief AgentID string `json:"enforcer_id"` NetworkMode string `json:"network_mode"` CreatedAt string `json:"created_at"` StartedAt string `json:"started_at"` FinishedAt string `json:"finished_at"` Running bool `json:"running"` SecuredAt string `json:"secured_at"` ExitCode int `json:"exit_code"` Ifaces map[string][]*RESTIPAddr `json:"interfaces"` Ports []*RESTWorkloadPorts `json:"ports"` Labels map[string]string `json:"labels"` Applications []string `json:"applications"` MemoryLimit int64 `json:"memory_limit"` CPUs string `json:"cpus"` Children []*RESTWorkload `json:"children"` }
type RESTWorkloadBrief ¶
type RESTWorkloadBrief struct { ID string `json:"id"` Name string `json:"name"` DisplayName string `json:"display_name"` PodName string `json:"pod_name"` HostName string `json:"host_name"` HostID string `json:"host_id"` Image string `json:"image"` ImageID string `json:"image_id"` PlatformRole string `json:"platform_role"` Domain string `json:"domain"` State string `json:"state"` Service string `json:"service"` Author string `json:"author"` ServiceGroup string `json:"service_group"` CapSniff bool `json:"cap_sniff"` CapQuar bool `json:"cap_quarantine"` CapChgMode bool `json:"cap_change_mode"` PolicyMode string `json:"policy_mode"` ProfileMode string `json:"profile_mode"` ScanSummary *RESTScanBrief `json:"scan_summary"` Children []*RESTWorkloadBrief `json:"children"` QuarReason string `json:"quarantine_reason,omitempty"` ServiceMesh bool `json:"service_mesh"` ServiceMeshSidecar bool `json:"service_mesh_sidecar"` Privileged bool `json:"privileged"` RunAsRoot bool `json:"run_as_root"` }
func (*RESTWorkloadBrief) GetDomain ¶
func (o *RESTWorkloadBrief) GetDomain(f share.GetAccessObjectFunc) ([]string, []string)
NOTE: This is a special case. Only read is authorized, but there is no data structure associated
with the write action. We use this object to authorize again.
type RESTWorkloadConfig ¶
type RESTWorkloadConfigCfg ¶
type RESTWorkloadConfigCfg struct { Wire *string `json:"wire,omitempty"` Quarantine *bool `json:"quarantine,omitempty"` }
Omit fields indicate that it's not modified.
type RESTWorkloadConfigCfgData ¶
type RESTWorkloadConfigCfgData struct {
Config *RESTWorkloadConfigCfg `json:"config"`
}
type RESTWorkloadConfigData ¶
type RESTWorkloadConfigData struct {
Config *RESTWorkloadConfig `json:"config"`
}
type RESTWorkloadDetail ¶
type RESTWorkloadDetail struct { RESTWorkload Groups []string `json:"groups"` AppPorts map[string]string `json:"app_ports"` Children []*RESTWorkloadDetail `json:"children"` }
type RESTWorkloadDetailData ¶
type RESTWorkloadDetailData struct {
Workload *RESTWorkloadDetail `json:"workload"`
}
type RESTWorkloadIntercept ¶
type RESTWorkloadIntercept struct { ID string `json:"id"` Inline bool `json:"inline"` Quarantine bool `json:"quarantine"` Ports []*RESTWorkloadInterceptPort `json:"ports"` }
type RESTWorkloadInterceptData ¶
type RESTWorkloadInterceptData struct {
Intercept *RESTWorkloadIntercept `json:"intercept"`
}
type RESTWorkloadInterceptPort ¶
type RESTWorkloadInterceptPort struct { Port string `json:"port"` Peer string `json:"peer"` MAC string `json:"mac"` UCMAC string `json:"uc_mac"` BCMAC string `json:"bc_mac"` InPort string `json:"in_port"` ExPort string `json:"ex_port"` InPortRules string `json:"in_rules"` ExPortRules string `json:"ex_rules"` EnforcerRules string `json:"enforcer_rules"` }
type RESTWorkloadPorts ¶
type RESTWorkloadPorts struct { RESTProtoPort HostIP string `json:"host_ip"` HostPort uint16 `json:"host_port"` }
type RESTWorkloadRequest ¶
type RESTWorkloadRequest struct {
Command string `json:"command,omitempty"`
}
type RESTWorkloadRequestData ¶
type RESTWorkloadRequestData struct {
Request RESTWorkloadRequest `json:"request"`
}
type RESTWorkloadStatsData ¶
type RESTWorkloadsBriefData ¶
type RESTWorkloadsBriefData struct {
Workloads []*RESTWorkloadBrief `json:"workloads"`
}
type RESTWorkloadsData ¶
type RESTWorkloadsData struct {
Workloads []*RESTWorkload `json:"workloads"`
}
type Threat ¶
type Threat struct { LogCommon ID string `json:"id"` ThreatID uint32 `json:"threat_id"` ClientWL string `json:"client_workload_id"` ClientWLName string `json:"client_workload_name"` ClientWLDomain string `json:"client_workload_domain,omitempty"` ClientWLImage string `json:"client_workload_image,omitempty"` ClientWLService string `json:"client_workload_service,omitempty"` ServerWL string `json:"server_workload_id"` ServerWLName string `json:"server_workload_name"` ServerWLDomain string `json:"server_workload_domain,omitempty"` ServerWLImage string `json:"server_workload_image,omitempty"` ServerWLService string `json:"server_workload_service,omitempty"` Severity string `json:"severity"` Action string `json:"action"` Count uint32 `json:"count"` EtherType uint16 `json:"ether_type"` ClientPort uint16 `json:"client_port"` ServerPort uint16 `json:"server_port"` ServerConnPort uint16 `json:"server_conn_port"` ICMPCode uint8 `json:"icmp_code"` ICMPType uint8 `json:"icmp_type"` IPProto uint8 `json:"ip_proto"` ClientIP string `json:"client_ip"` ServerIP string `json:"server_ip"` Application string `json:"application"` Sensor string `json:"sensor"` Group string `json:"group"` Target string `json:"target"` Monitor bool `json:"monitor"` CapLen uint16 `json:"cap_len,omitempty"` Packet string `json:"packet,omitempty"` Msg string `json:"message"` }
type Violation ¶
type Violation struct { LogCommon ID string `json:"id"` ClientWL string `json:"client_id"` ClientName string `json:"client_name"` ClientDomain string `json:"client_domain,omitempty"` ClientImage string `json:"client_image,omitempty"` ClientService string `json:"client_service,omitempty"` ServerWL string `json:"server_id"` ServerName string `json:"server_name"` ServerDomain string `json:"server_domain,omitempty"` ServerImage string `json:"server_image,omitempty"` ServerService string `json:"server_service,omitempty"` ServerPort uint16 `json:"server_port"` IPProto uint8 `json:"ip_proto"` Applications []string `json:"applications"` Servers []string `json:"servers"` Sessions uint32 `json:"sessions"` PolicyAction string `json:"policy_action"` PolicyID uint32 `json:"policy_id"` ClientIP string `json:"client_ip"` ServerIP string `json:"server_ip"` Xff bool `json:"xff"` }