mirror of
https://github.com/projectdiscovery/nuclei.git
synced 2025-12-19 00:05:24 +00:00
33 lines
593 B
Go
33 lines
593 B
Go
|
|
package smb
|
||
|
|
|
||
|
|
import (
|
||
|
|
lib_smb "github.com/projectdiscovery/nuclei/v2/pkg/js/libs/smb"
|
||
|
|
|
||
|
|
"github.com/dop251/goja"
|
||
|
|
"github.com/projectdiscovery/nuclei/v2/pkg/js/gojs"
|
||
|
|
)
|
||
|
|
|
||
|
|
var (
|
||
|
|
module = gojs.NewGojaModule("nuclei/smb")
|
||
|
|
)
|
||
|
|
|
||
|
|
func init() {
|
||
|
|
module.Set(
|
||
|
|
gojs.Objects{
|
||
|
|
// Functions
|
||
|
|
|
||
|
|
// Var and consts
|
||
|
|
|
||
|
|
// Types (value type)
|
||
|
|
"SMBClient": func() lib_smb.SMBClient { return lib_smb.SMBClient{} },
|
||
|
|
|
||
|
|
// Types (pointer type)
|
||
|
|
"NewSMBClient": func() *lib_smb.SMBClient { return &lib_smb.SMBClient{} },
|
||
|
|
},
|
||
|
|
).Register()
|
||
|
|
}
|
||
|
|
|
||
|
|
func Enable(runtime *goja.Runtime) {
|
||
|
|
module.Enable(runtime)
|
||
|
|
}
|