Documentation
¶
Index ¶
- Variables
- func AddContent(pbWebContent *clientpb.WebContent, webContentDir string) (*clientpb.WebContent, error)
- func AddWebSite(webSiteName string, webContentDir string) (*clientpb.Website, error)
- func AllCrackFiles() ([]*models.CrackFile, error)
- func BeaconByID(id string) (*models.Beacon, error)
- func BeaconTaskByEnvelopeID(beaconID string, envelopeID int64) (*clientpb.BeaconTask, error)
- func BeaconTaskByID(id string) (*clientpb.BeaconTask, error)
- func BeaconTasksByBeaconID(beaconID string) ([]*clientpb.BeaconTask, error)
- func CanaryByDomain(domain string) (*clientpb.DNSCanary, error)
- func CheckKeyExReplay(ciphertext []byte) error
- func CountTasksByBeaconID(beaconID string) (int64, int64, error)
- func CrackFilesByType(fileType clientpb.CrackFileType) ([]*models.CrackFile, error)
- func CrackFilesDiskUsage() (int64, error)
- func CrackWordlistByName(name string) (*models.CrackFile, error)
- func CrackstationByHostUUID(hostUUID string) (*models.Crackstation, error)
- func CredentialByID(id string) (*clientpb.Credential, error)
- func CredentialsByCollection(collection string) ([]*clientpb.Credential, error)
- func CredentialsByHashType(hashType clientpb.HashType) ([]*clientpb.Credential, error)
- func DeleteC2(c2ID uuid.UUID) error
- func DeleteKeyValue(key string, value string) error
- func DeleteListener(JobID uint32) error
- func DeleteProfile(name string) error
- func GetByCrackFileByID(id string) (*models.CrackFile, error)
- func GetCertificateInfo(categoryOptions uint32, cn string) ([]*models.Certificate, error)
- func GetCrackTaskByID(id string) (*models.CrackTask, error)
- func GetKeyValue(key string) (string, error)
- func HTTPC2ConfigUpdate(newConf *clientpb.HTTPC2Config, oldConf *clientpb.HTTPC2Config) error
- func HostByHostID(id uuid.UUID) (*clientpb.Host, error)
- func HostByHostUUID(id string) (*models.Host, error)
- func IOCByID(id string) (*clientpb.IOC, error)
- func ImplantBuildByID(id string) (*clientpb.ImplantBuild, error)
- func ImplantBuildByName(name string) (*clientpb.ImplantBuild, error)
- func ImplantBuildByPublicKeyDigest(publicKeyDigest [32]byte) (*clientpb.ImplantBuild, error)
- func ImplantBuildByResourceID(resourceID uint64) (*clientpb.ImplantBuild, error)
- func ImplantBuilds() (*clientpb.ImplantBuilds, error)
- func ImplantConfigByID(id string) (*clientpb.ImplantConfig, error)
- func ImplantConfigWithC2sByID(id string) (*clientpb.ImplantConfig, error)
- func ImplantProfileByName(name string) (*clientpb.ImplantProfile, error)
- func ImplantProfileNames() ([]string, error)
- func ImplantProfiles() ([]*clientpb.ImplantProfile, error)
- func ListBeacons() ([]*clientpb.Beacon, error)
- func ListCanaries() ([]*clientpb.DNSCanary, error)
- func ListHosts() ([]*clientpb.Host, error)
- func ListenerByJobID(JobID uint32) (*clientpb.ListenerJob, error)
- func ListenerJobs() ([]*clientpb.ListenerJob, error)
- func LoadHTTPC2ConfigByName(name string) (*clientpb.HTTPC2Config, error)
- func LoadHTTPC2s() ([]*clientpb.HTTPC2Config, error)
- func OperatorAll() ([]*models.Operator, error)
- func OperatorByToken(value string) (*models.Operator, error)
- func PendingBeaconTasksByBeaconID(id string) ([]*models.BeaconTask, error)
- func PlaintextCredentialsByHashType(hashType clientpb.HashType) ([]*clientpb.Credential, error)
- func ProfileByName(name string) (*clientpb.ImplantProfile, error)
- func RemoveContent(id string) error
- func RemoveWebSite(id string) error
- func RenameBeacon(id string, name string) error
- func ResourceIDByName(name string) (*clientpb.ResourceID, error)
- func ResourceIDByType(resourceType string) ([]*clientpb.ResourceID, error)
- func ResourceIDByValue(id uint64) (*clientpb.ResourceID, error)
- func ResourceIDs() ([]*clientpb.ResourceID, error)
- func SaveC2Listener(listenerConf *clientpb.ListenerJob) error
- func SaveHTTPC2Config(httpC2Config *clientpb.HTTPC2Config) error
- func SaveImplantBuild(ib *clientpb.ImplantBuild) (*clientpb.ImplantBuild, error)
- func SaveImplantConfig(ic *clientpb.ImplantConfig) (*clientpb.ImplantConfig, error)
- func SaveResourceID(r *clientpb.ResourceID) error
- func SaveWatchTowerConfig(m *clientpb.MonitoringProvider) error
- func Session() *gorm.DB
- func SetKeyValue(key string, value string) error
- func UpdateBeaconCheckinByID(id string, next int64) error
- func UpdateHTTPC2Listener(listenerConf *clientpb.ListenerJob) error
- func WGPeerIPs() ([]string, error)
- func WatchTowerConfigDel(m *clientpb.MonitoringProvider) error
- func WatchTowerConfigs() ([]*clientpb.MonitoringProvider, error)
- func WebContentByIDAndPath(id string, path string, webContentDir string, eager bool) (*clientpb.WebContent, error)
- func WebsiteByName(name string, webContentDir string) (*clientpb.Website, error)
- func Websites(webContentDir string) ([]*clientpb.Website, error)
Constants ¶
This section is empty.
Variables ¶
var Client = newDBClient()
Client - Database Client
var ( // ErrRecordNotFound - Record not found error ErrRecordNotFound = gorm.ErrRecordNotFound )
Functions ¶
func AddContent ¶ added in v1.6.0
func AddContent(pbWebContent *clientpb.WebContent, webContentDir string) (*clientpb.WebContent, error)
AddContent - Add content to website
func AddWebSite ¶ added in v1.6.0
AddWebsite - Return website, create if it does not exist
func AllCrackFiles ¶ added in v1.6.0
func BeaconByID ¶ added in v1.5.0
BeaconByID - Select a Beacon by ID
func BeaconTaskByEnvelopeID ¶ added in v1.5.0
func BeaconTaskByEnvelopeID(beaconID string, envelopeID int64) (*clientpb.BeaconTask, error)
BeaconTasksByEnvelopeID - Select a (sent) BeaconTask by its envelope ID
func BeaconTaskByID ¶ added in v1.5.0
func BeaconTaskByID(id string) (*clientpb.BeaconTask, error)
BeaconTaskByID - Select a specific BeaconTask by ID, this will fetch the full request/response
func BeaconTasksByBeaconID ¶ added in v1.5.0
func BeaconTasksByBeaconID(beaconID string) ([]*clientpb.BeaconTask, error)
BeaconTasksByBeaconID - Get all tasks for a specific beacon by default will not fetch the request/response columns since these could be arbitrarily large.
func CanaryByDomain ¶
CanaryByDomain - Check if a canary exists
func CheckKeyExReplay ¶ added in v1.6.0
CheckKeyExReplay - Store the hash of a key exchange to prevent replays
func CountTasksByBeaconID ¶ added in v1.5.0
CountTasksByBeaconID - Select a (sent) BeaconTask by its envelope ID
func CrackFilesByType ¶ added in v1.6.0
func CrackFilesByType(fileType clientpb.CrackFileType) ([]*models.CrackFile, error)
CrackFilesByType - Get all files by crack file type
func CrackFilesDiskUsage ¶ added in v1.6.0
CrackFilesDiskUsage - Get all files by crack file type
func CrackWordlistByName ¶ added in v1.6.0
CrackWordlistByName - Get all files by crack file type
func CrackstationByHostUUID ¶ added in v1.6.0
func CrackstationByHostUUID(hostUUID string) (*models.Crackstation, error)
CrackstationByHostUUID - Get crackstation by the session's reported HostUUID
func CredentialByID ¶ added in v1.6.0
func CredentialByID(id string) (*clientpb.Credential, error)
CredentialsByID
func CredentialsByCollection ¶ added in v1.6.0
func CredentialsByCollection(collection string) ([]*clientpb.Credential, error)
CredentialsByHashType
func CredentialsByHashType ¶ added in v1.6.0
func CredentialsByHashType(hashType clientpb.HashType) ([]*clientpb.Credential, error)
CredentialsByHashType
func DeleteKeyValue ¶ added in v1.5.0
DeleteKeyValue - Delete a key/value pair
func DeleteListener ¶ added in v1.6.0
func DeleteProfile ¶ added in v1.6.0
DeleteProfile - Delete a profile from the database
func GetByCrackFileByID ¶ added in v1.6.0
GetByCrackFileByID - Get a crack task by its ID
func GetCertificateInfo ¶ added in v1.6.0
func GetCertificateInfo(categoryOptions uint32, cn string) ([]*models.Certificate, error)
Certificates
func GetCrackTaskByID ¶ added in v1.6.0
GetCrackTaskByID - Get a crack task by its ID
func GetKeyValue ¶ added in v1.5.0
GetKeyValue - Get a value from a key
func HTTPC2ConfigUpdate ¶ added in v1.6.0
func HTTPC2ConfigUpdate(newConf *clientpb.HTTPC2Config, oldConf *clientpb.HTTPC2Config) error
func HostByHostID ¶ added in v1.5.0
HostByHostID - Get host by the session's reported HostUUID
func HostByHostUUID ¶ added in v1.5.0
HostByHostUUID - Get host by the session's reported HostUUID
func ImplantBuildByID ¶ added in v1.6.0
func ImplantBuildByID(id string) (*clientpb.ImplantBuild, error)
ImplantBuildByID - Fetch implant build from ID
func ImplantBuildByName ¶
func ImplantBuildByName(name string) (*clientpb.ImplantBuild, error)
ImplantBuildByName - Fetch implant build by name
func ImplantBuildByPublicKeyDigest ¶ added in v1.6.0
func ImplantBuildByPublicKeyDigest(publicKeyDigest [32]byte) (*clientpb.ImplantBuild, error)
ImplantBuildByPublicKeyDigest - Fetch implant build by it's ecc public key
func ImplantBuildByResourceID ¶ added in v1.6.0
func ImplantBuildByResourceID(resourceID uint64) (*clientpb.ImplantBuild, error)
ImplantBuildByResourceID - Fetch implant build from resource ID
func ImplantBuilds ¶
func ImplantBuilds() (*clientpb.ImplantBuilds, error)
ImplantBuilds - Return all implant builds
func ImplantConfigByID ¶ added in v1.5.0
func ImplantConfigByID(id string) (*clientpb.ImplantConfig, error)
ImplantConfigByID - Fetch implant config by id
func ImplantConfigWithC2sByID ¶ added in v1.5.30
func ImplantConfigWithC2sByID(id string) (*clientpb.ImplantConfig, error)
ImplantConfigWithC2sByID - Fetch implant build by name
func ImplantProfileByName ¶
func ImplantProfileByName(name string) (*clientpb.ImplantProfile, error)
ImplantProfileByName - Fetch implant build by name
func ImplantProfileNames ¶
ImplantProfileNames - Fetch a list of all build names
func ImplantProfiles ¶
func ImplantProfiles() ([]*clientpb.ImplantProfile, error)
ImplantProfiles - Fetch a map of name<->profiles current in the database
func ListBeacons ¶ added in v1.5.0
ListBeacons - Select a Beacon by ID
func ListCanaries ¶
ListCanaries - List of all embedded canaries
func ListenerByJobID ¶ added in v1.6.0
func ListenerByJobID(JobID uint32) (*clientpb.ListenerJob, error)
func ListenerJobs ¶ added in v1.6.0
func ListenerJobs() ([]*clientpb.ListenerJob, error)
func LoadHTTPC2ConfigByName ¶ added in v1.6.0
func LoadHTTPC2ConfigByName(name string) (*clientpb.HTTPC2Config, error)
func LoadHTTPC2s ¶ added in v1.6.0
func LoadHTTPC2s() ([]*clientpb.HTTPC2Config, error)
func OperatorAll ¶ added in v1.5.0
OperatorAll - Select all operators from the database
func OperatorByToken ¶ added in v1.5.0
OperatorByToken - Select an operator by token value
func PendingBeaconTasksByBeaconID ¶ added in v1.5.0
func PendingBeaconTasksByBeaconID(id string) ([]*models.BeaconTask, error)
PendingBeaconTasksByBeaconID - Select a Beacon by ID, ordered by creation time
func PlaintextCredentialsByHashType ¶ added in v1.6.0
func PlaintextCredentialsByHashType(hashType clientpb.HashType) ([]*clientpb.Credential, error)
PlaintextCredentials
func ProfileByName ¶
func ProfileByName(name string) (*clientpb.ImplantProfile, error)
ProfileByName - Fetch a single profile from the database
func RemoveContent ¶ added in v1.6.0
func RemoveWebSite ¶ added in v1.6.0
func RenameBeacon ¶ added in v1.5.5
RenameBeacon - Rename a beacon
func ResourceIDByName ¶ added in v1.6.0
func ResourceIDByName(name string) (*clientpb.ResourceID, error)
ResourceID by name
func ResourceIDByType ¶ added in v1.6.0
func ResourceIDByType(resourceType string) ([]*clientpb.ResourceID, error)
ResourceID queries
func ResourceIDByValue ¶ added in v1.6.0
func ResourceIDByValue(id uint64) (*clientpb.ResourceID, error)
ResourceID by value
func ResourceIDs ¶ added in v1.6.0
func ResourceIDs() ([]*clientpb.ResourceID, error)
func SaveC2Listener ¶ added in v1.6.0
func SaveC2Listener(listenerConf *clientpb.ListenerJob) error
func SaveHTTPC2Config ¶ added in v1.6.0
func SaveHTTPC2Config(httpC2Config *clientpb.HTTPC2Config) error
func SaveImplantBuild ¶ added in v1.6.0
func SaveImplantBuild(ib *clientpb.ImplantBuild) (*clientpb.ImplantBuild, error)
SaveImplantBuild
func SaveImplantConfig ¶ added in v1.6.0
func SaveImplantConfig(ic *clientpb.ImplantConfig) (*clientpb.ImplantConfig, error)
SaveImplantConfig
func SaveResourceID ¶ added in v1.6.0
func SaveResourceID(r *clientpb.ResourceID) error
func SaveWatchTowerConfig ¶ added in v1.6.0
func SaveWatchTowerConfig(m *clientpb.MonitoringProvider) error
func SetKeyValue ¶ added in v1.5.0
SetKeyValue - Set the value for a key/value pair
func UpdateBeaconCheckinByID ¶ added in v1.5.0
UpdateBeaconCheckinByID - Update the beacon's last / next checkin
func UpdateHTTPC2Listener ¶ added in v1.6.0
func UpdateHTTPC2Listener(listenerConf *clientpb.ListenerJob) error
func WatchTowerConfigDel ¶ added in v1.6.0
func WatchTowerConfigDel(m *clientpb.MonitoringProvider) error
func WatchTowerConfigs ¶ added in v1.6.0
func WatchTowerConfigs() ([]*clientpb.MonitoringProvider, error)
watchtower - List configurations
func WebContentByIDAndPath ¶ added in v1.6.0
func WebContentByIDAndPath(id string, path string, webContentDir string, eager bool) (*clientpb.WebContent, error)
WebContent by ID and path
func WebsiteByName ¶
WebsiteByName - Get website by name
Types ¶
This section is empty.