mirror of
https://github.com/projectdiscovery/nuclei.git
synced 2025-12-18 17:55:25 +00:00
fsm in-memory deduplication
This commit is contained in:
parent
3a8ee75b93
commit
731241c90e
@ -105,6 +105,11 @@ func (e *HTTPExecuter) ExecuteHTTP(URL string) (result Result) {
|
|||||||
result.Extractions = make(map[string]interface{})
|
result.Extractions = make(map[string]interface{})
|
||||||
dynamicvalues := make(map[string]interface{})
|
dynamicvalues := make(map[string]interface{})
|
||||||
|
|
||||||
|
// verify if the URL is already being processed
|
||||||
|
if e.bulkHttpRequest.HasGenerator(URL) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
e.bulkHttpRequest.CreateGenerator(URL)
|
e.bulkHttpRequest.CreateGenerator(URL)
|
||||||
for e.bulkHttpRequest.Next(URL) && !result.Done {
|
for e.bulkHttpRequest.Next(URL) && !result.Done {
|
||||||
httpRequest, err := e.bulkHttpRequest.MakeHTTPRequest(URL, dynamicvalues, e.bulkHttpRequest.Current(URL))
|
httpRequest, err := e.bulkHttpRequest.MakeHTTPRequest(URL, dynamicvalues, e.bulkHttpRequest.Current(URL))
|
||||||
|
|||||||
@ -123,6 +123,10 @@ func (r *BulkHTTPRequest) CreateGenerator(URL string) {
|
|||||||
r.gsfm.Add(URL)
|
r.gsfm.Add(URL)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (r *BulkHTTPRequest) HasGenerator(URL string) bool {
|
||||||
|
return r.gsfm.Has(URL)
|
||||||
|
}
|
||||||
|
|
||||||
func (r *BulkHTTPRequest) ReadOne(URL string) {
|
func (r *BulkHTTPRequest) ReadOne(URL string) {
|
||||||
r.gsfm.ReadOne(URL)
|
r.gsfm.ReadOne(URL)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user