mirror of
https://github.com/lunchcat/sif.git
synced 2026-06-12 19:11:25 -07:00
feat(modules): infra for builtin modules
Infrastructure preparation for builtin complex Go module registration.
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
/*
|
||||
·━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━·
|
||||
: :
|
||||
: █▀ █ █▀▀ · Blazing-fast pentesting suite :
|
||||
: ▄█ █ █▀ · BSD 3-Clause License :
|
||||
: :
|
||||
: (c) 2022-2025 vmfunc, xyzeva, :
|
||||
: lunchcat alumni & contributors :
|
||||
: :
|
||||
·━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━·
|
||||
*/
|
||||
|
||||
package builtin
|
||||
|
||||
// Register registers all Go-based built-in scans as modules.
|
||||
// Allows complex Go scans to participate in the module system
|
||||
func Register() {
|
||||
// Built-in modules will be registered here
|
||||
}
|
||||
@@ -29,6 +29,7 @@ import (
|
||||
"github.com/dropalldatabases/sif/internal/modules"
|
||||
"github.com/dropalldatabases/sif/internal/output"
|
||||
"github.com/dropalldatabases/sif/internal/scan"
|
||||
"github.com/dropalldatabases/sif/internal/scan/builtin"
|
||||
"github.com/dropalldatabases/sif/internal/scan/frameworks"
|
||||
jsscan "github.com/dropalldatabases/sif/internal/scan/js"
|
||||
)
|
||||
@@ -140,6 +141,10 @@ func (app *App) Run() error {
|
||||
if err := loader.LoadAll(); err != nil {
|
||||
log.Warnf("Failed to load modules: %v", err)
|
||||
}
|
||||
|
||||
// Register built-in Go modules
|
||||
builtin.Register()
|
||||
|
||||
fmt.Println("Available modules:")
|
||||
for _, m := range modules.All() {
|
||||
info := m.Info()
|
||||
@@ -352,6 +357,9 @@ func (app *App) Run() error {
|
||||
log.Warnf("Failed to load modules: %v", err)
|
||||
}
|
||||
|
||||
// Register built-in Go modules
|
||||
builtin.Register()
|
||||
|
||||
// Determine which modules to run
|
||||
var toRun []modules.Module
|
||||
if app.settings.AllModules {
|
||||
|
||||
Reference in New Issue
Block a user