Documentation ¶
Index ¶
- Constants
- func ImportFromReader(ctx context.Context, reader io.Reader, database db.TransactionQuerier) error
- func NewBruteforcer(passwordProvider PasswordProvider, sc scanner.Scanner, statusFunc StatusFunc) *bruteforcer
- func NewDatabaseBruteforceProvider(queries DatabasePasswordProviderInterface) *databaseBruteforceProvider
- func NewDatabasePasswordProvider(ctx context.Context, database DatabasePasswordProviderInterface, ...) (*databasePasswordProvider, error)
- func NewPasswordListIterator(passwords []string) *passwordListProvider
- type BruteforceProvider
- type BruteforceUserStatus
- type Bruteforcer
- type DatabasePasswordProviderInterface
- type PasswordProvider
- type StatusFunc
Constants ¶
View Source
const MAX_PASSWORDS_PER_BATCH = 10000
Variables ¶
This section is empty.
Functions ¶
func ImportFromReader ¶
func NewBruteforcer ¶
func NewBruteforcer(passwordProvider PasswordProvider, sc scanner.Scanner, statusFunc StatusFunc) *bruteforcer
func NewDatabaseBruteforceProvider ¶
func NewDatabaseBruteforceProvider(queries DatabasePasswordProviderInterface) *databaseBruteforceProvider
func NewDatabasePasswordProvider ¶
func NewDatabasePasswordProvider(ctx context.Context, database DatabasePasswordProviderInterface, projectID int64) (*databasePasswordProvider, error)
func NewPasswordListIterator ¶
func NewPasswordListIterator(passwords []string) *passwordListProvider
Types ¶
type BruteforceProvider ¶
type BruteforceProvider interface {
NewBruteforcer(ctx context.Context, sc scanner.Scanner, statusFunc StatusFunc, projectID int64) (Bruteforcer, error)
}
type BruteforceUserStatus ¶
type Bruteforcer ¶
type Bruteforcer interface {
BruteforcePasswordAllUsers(ctx context.Context) ([]scanner.ScanResult, error)
}
type DatabasePasswordProviderInterface ¶
type DatabasePasswordProviderInterface interface { GetBruteforcePasswordsPaginated(ctx context.Context, arg queries.GetBruteforcePasswordsPaginatedParams) ([]*queries.DefaultBruteforcePassword, error) GetSpecificBruteforcePasswordID(ctx context.Context, arg queries.GetSpecificBruteforcePasswordIDParams) (int64, error) CreateBruteforcedPassword(ctx context.Context, arg queries.CreateBruteforcedPasswordParams) (*queries.BruteforcedPassword, error) GetBruteforcedPasswords(ctx context.Context, arg queries.GetBruteforcedPasswordsParams) (*queries.BruteforcedPassword, error) GetBruteforcePasswordsForProjectCount(ctx context.Context, projectID int64) (int64, error) UpdateBruteforcedPassword(ctx context.Context, arg queries.UpdateBruteforcedPasswordParams) (*queries.BruteforcedPassword, error) }
type PasswordProvider ¶
type PasswordProvider interface { GetCount() (int64, error) GetSpecificPassword(password string) (int64, bool, error) Next() bool Error() error Current() (int64, string, error) Start(index int64) error Close() SavePasswordHash(username, hash, password string, maxInternalID int64) error GetPasswordByHash(username, hash string) (string, int64, error) }
type StatusFunc ¶
type StatusFunc = func(map[scanner.User]BruteforceUserStatus) error
Click to show internal directories.
Click to hide internal directories.