chore: fix function names in comment (#5110)

This commit is contained in:
Anna Smith 2024-04-27 21:10:33 +08:00 committed by GitHub
parent 7ce1b3e43d
commit e96fdf2e40
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 5 additions and 5 deletions

View File

@ -394,7 +394,7 @@ func EnablePassiveMode() NucleiSDKOptions {
}
}
// WithAuthOptions allows setting a custom authprovider implementation
// WithAuthProvider allows setting a custom authprovider implementation
func WithAuthProvider(provider authprovider.AuthProvider) NucleiSDKOptions {
return func(e *NucleiEngine) error {
e.authprovider = provider

View File

@ -95,7 +95,7 @@ func (e *ThreadSafeNucleiEngine) GlobalResultCallback(callback func(event *outpu
e.eng.resultCallbacks = []func(*output.ResultEvent){callback}
}
// ExecuteWithCallback executes templates on targets and calls callback on each result(only if results are found)
// ExecuteNucleiWithOpts executes templates on targets and calls callback on each result(only if results are found)
// This method can be called concurrently and it will use some global resources but can be runned parallelly
// by invoking this method with different options and targets
// Note: Not all options are thread-safe. this method will throw error if you try to use non-thread-safe options

View File

@ -219,7 +219,7 @@ func GetAuthDataFromFile(file string) (*Authx, error) {
return GetAuthDataFromJSON(bin)
}
// GetTemplateIDsFromSecretFile reads the template IDs from the secret file
// GetTemplatePathsFromSecretFile reads the template IDs from the secret file
func GetTemplatePathsFromSecretFile(file string) ([]string, error) {
auth, err := GetAuthDataFromFile(file)
if err != nil {

View File

@ -166,12 +166,12 @@ func (c *Config) GetTemplateIndexFilePath() string {
return filepath.Join(c.TemplatesDirectory, NucleiTemplatesIndexFileName)
}
// GetTemplatesConfigFilePath returns checksum file path of nuclei templates
// GetChecksumFilePath returns checksum file path of nuclei templates
func (c *Config) GetChecksumFilePath() string {
return filepath.Join(c.TemplatesDirectory, NucleiTemplatesCheckSumFileName)
}
// GetCLIOptsConfigFilePath returns the nuclei cli config file path
// GetFlagsConfigFilePath returns the nuclei cli config file path
func (c *Config) GetFlagsConfigFilePath() string {
return filepath.Join(c.configDir, CLIConfigFileName)
}