Documentation ¶
Index ¶
- Constants
- func CTInputWorker(config *CTConfig, startChan chan<- int64)
- func CTOutputWorker(config *CTConfig, certChan <-chan []Certificate)
- func CTProcessWorker(config *CTConfig, startChan <-chan int64, certChan chan<- []Certificate)
- func ConnectLog(config *CTConfig) (*client.LogClient, error)
- func ExtractZip(src string, dst string) error
- func FilterInputWorker[I, O any](filter ProcessStep[I, O], instanceChan chan<- I)
- func FilterOutputWorker[I, O any](filter ProcessStep[I, O], resultsChan <-chan ProcessResult[I, O])
- func FilterProcessWorker[I, O any](filter ProcessStep[I, O], instanceChan <-chan I, ...)
- func Hash(s string) string
- func ImportCertificates(config *CTConfig)
- func PanicIfError(err error)
- func RunProcessStep[I, O any](step ProcessStep[I, O], workers int)
- func Unique[T comparable](slice []T) []T
- type AWSKey
- type CTConfig
- type Certificate
- type Database
- func (d *Database) AddAWSKeys(k []AWSKey) error
- func (d *Database) AddGitLab(g []GitLab) error
- func (d *Database) AddJenkins(j []Jenkins) error
- func (d *Database) AddJenkinsJob(o []JenkinsJob) error
- func (d *Database) Close()
- func (d *Database) GetUnprocessedAWSFindings() ([]Finding, error)
- func (d *Database) GetUnprocessedGitLabs() ([]GitLab, error)
- func (d *Database) GetUnprocessedInstancesForGitlab() ([]Instance, error)
- func (d *Database) GetUnprocessedInstancesForJenkins() ([]Instance, error)
- func (d *Database) GetUnprocessedJenkins() ([]Jenkins, error)
- func (d *Database) GetUnprocessedJenkinsAWSFindings() ([]JenkinsFinding, error)
- func (d *Database) GetUnprocessedJenkinsJobs() ([]JenkinsJob, error)
- func (d *Database) GetUnprocessedRepositories() ([]Repository, error)
- func (d *Database) IndexRange() (int64, int64, error)
- func (d *Database) InsertRepositories(repositories []Repository) error
- func (d *Database) LogFindings(finding []Finding) error
- func (d *Database) SaveJenkinsFindings(findings []JenkinsFinding) error
- func (d *Database) SetFindingProcessed(finding *Finding) error
- func (d *Database) SetGitlabProcessed(gitlab *GitLab) error
- func (d *Database) SetInstanceProcessed(instance *Instance) error
- func (d *Database) SetJenkinsFindingProcessed(finding *JenkinsFinding) error
- func (d *Database) SetJenkinsJobProcessed(job *JenkinsJob) error
- func (d *Database) SetJenkinsProcessed(jenkins *Jenkins) error
- func (d *Database) SetRepositoryProcessed(repository *Repository) error
- func (d *Database) StoreCertificates(certs []Certificate) error
- type Fan
- type Finding
- type GitLab
- type Instance
- type Jenkins
- type JenkinsFinding
- type JenkinsJob
- type ProcessResult
- type ProcessStep
- type Repository
Constants ¶
View Source
const CTWorkers = 30
View Source
const DatabaseFile = "./instances.db"
Variables ¶
This section is empty.
Functions ¶
func CTInputWorker ¶
func CTOutputWorker ¶
func CTOutputWorker(config *CTConfig, certChan <-chan []Certificate)
func CTProcessWorker ¶
func CTProcessWorker(config *CTConfig, startChan <-chan int64, certChan chan<- []Certificate)
func ExtractZip ¶
func FilterInputWorker ¶
func FilterInputWorker[I, O any](filter ProcessStep[I, O], instanceChan chan<- I)
func FilterOutputWorker ¶
func FilterOutputWorker[I, O any](filter ProcessStep[I, O], resultsChan <-chan ProcessResult[I, O])
func FilterProcessWorker ¶
func FilterProcessWorker[I, O any](filter ProcessStep[I, O], instanceChan <-chan I, resultChan chan<- ProcessResult[I, O])
func ImportCertificates ¶
func ImportCertificates(config *CTConfig)
func PanicIfError ¶
func PanicIfError(err error)
func RunProcessStep ¶
func RunProcessStep[I, O any](step ProcessStep[I, O], workers int)
func Unique ¶
func Unique[T comparable](slice []T) []T
Types ¶
type Certificate ¶
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
func NewDatabase ¶
func (*Database) AddAWSKeys ¶
func (*Database) AddJenkins ¶
func (*Database) AddJenkinsJob ¶
func (d *Database) AddJenkinsJob(o []JenkinsJob) error
func (*Database) GetUnprocessedAWSFindings ¶
func (*Database) GetUnprocessedGitLabs ¶
func (*Database) GetUnprocessedInstancesForGitlab ¶
func (*Database) GetUnprocessedInstancesForJenkins ¶
func (*Database) GetUnprocessedJenkins ¶
func (*Database) GetUnprocessedJenkinsAWSFindings ¶
func (d *Database) GetUnprocessedJenkinsAWSFindings() ([]JenkinsFinding, error)
func (*Database) GetUnprocessedJenkinsJobs ¶
func (d *Database) GetUnprocessedJenkinsJobs() ([]JenkinsJob, error)
func (*Database) GetUnprocessedRepositories ¶
func (d *Database) GetUnprocessedRepositories() ([]Repository, error)
func (*Database) InsertRepositories ¶
func (d *Database) InsertRepositories(repositories []Repository) error
func (*Database) LogFindings ¶
func (*Database) SaveJenkinsFindings ¶
func (d *Database) SaveJenkinsFindings(findings []JenkinsFinding) error
func (*Database) SetFindingProcessed ¶
func (*Database) SetGitlabProcessed ¶
func (*Database) SetInstanceProcessed ¶
func (*Database) SetJenkinsFindingProcessed ¶
func (d *Database) SetJenkinsFindingProcessed(finding *JenkinsFinding) error
func (*Database) SetJenkinsJobProcessed ¶
func (d *Database) SetJenkinsJobProcessed(job *JenkinsJob) error
func (*Database) SetJenkinsProcessed ¶
func (*Database) SetRepositoryProcessed ¶
func (d *Database) SetRepositoryProcessed(repository *Repository) error
func (*Database) StoreCertificates ¶
func (d *Database) StoreCertificates(certs []Certificate) error
type Fan ¶
type GitLab ¶
type GitLab struct { ID int InstanceID int Instance Instance `gorm:"foreignKey:InstanceID"` AllowSignup bool Email string Password string APIToken string Processed bool BaseURL string `gorm:"uniqueIndex:git_labs_base_url"` }
func (GitLab) GetInstanceID ¶
type Jenkins ¶
type Jenkins struct { ID int InstanceID int Instance Instance `gorm:"foreignKey:InstanceID"` AnonymousAPI bool BaseURL string `gorm:"uniqueIndex:jenkins_base_url"` Processed bool ScriptAccess bool }
func (Jenkins) GetInstanceID ¶
type JenkinsFinding ¶
type JenkinsJob ¶
type ProcessResult ¶
type ProcessStep ¶
Click to show internal directories.
Click to hide internal directories.