mirror of
https://github.com/projectdiscovery/nuclei.git
synced 2025-12-17 23:05:26 +00:00
* introduce typescript files generation using ast + tmpl * feat valid ts with scraping * feat remove old logic + tsdocs for all modules * fix ikev and related bugs * typescript docs for js modules * lint,build + ldap realm fix * go mod tidy * fix named imports ast parsing * fix ast code generation errors * complete support for ts files generation * support go global/const in ts docs * updated template * feat: typescript using go code generation * nuke jsdoc generator * update generated ts dir structure * fix multifile ts gen issue * fix panic in ts code gen * fix test * update docs of js libs * feat: add doc+example for every js class,function,method * fix missing quotes in ikev example --------- Co-authored-by: Sandeep Singh <sandeep@projectdiscovery.io>
32 lines
725 B
Go
32 lines
725 B
Go
package rdp
|
|
|
|
import (
|
|
lib_rdp "github.com/projectdiscovery/nuclei/v3/pkg/js/libs/rdp"
|
|
|
|
"github.com/dop251/goja"
|
|
"github.com/projectdiscovery/nuclei/v3/pkg/js/gojs"
|
|
)
|
|
|
|
var (
|
|
module = gojs.NewGojaModule("nuclei/rdp")
|
|
)
|
|
|
|
func init() {
|
|
module.Set(
|
|
gojs.Objects{
|
|
// Functions
|
|
|
|
// Var and consts
|
|
|
|
// Objects / Classes
|
|
"CheckRDPAuthResponse": gojs.GetClassConstructor[lib_rdp.CheckRDPAuthResponse](&lib_rdp.CheckRDPAuthResponse{}),
|
|
"IsRDPResponse": gojs.GetClassConstructor[lib_rdp.IsRDPResponse](&lib_rdp.IsRDPResponse{}),
|
|
"RDPClient": gojs.GetClassConstructor[lib_rdp.RDPClient](&lib_rdp.RDPClient{}),
|
|
},
|
|
).Register()
|
|
}
|
|
|
|
func Enable(runtime *goja.Runtime) {
|
|
module.Enable(runtime)
|
|
}
|