* Check if the variables are override by other means
- you can override the template variable value using command line flags
* Update lazy eval logic
- previously, we were checking any function/expression in variable
- now, update the logic, lazy eval only if variable contains any
protocol variable(global)
* add integration tests
* Add test to check the dsl function working in variable
* gather all generate variables logic in utils
* go mod update
* Refactor the generate variables function
* go mod update+ fix typo
---------
Co-authored-by: Sandeep Singh <sandeep@projectdiscovery.io>
Co-authored-by: sandeep <8293321+ehsandeep@users.noreply.github.com>
Co-authored-by: Tarun Koyalwar <tarun@projectdiscovery.io>
* Extend dns extractor to dns answer records
* add test template
* Ignore error for dns variables are not found
* Add all the records of answer section
* Fixed the wrong typecasting
* tlsx dep update
* upgrde httpx => 1.3.0
* Fix check for OS made in MustDisableSandbox() (#3631)
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
* Fix wrong template loading in dev branch (#3629)
* Templates wrong loading
* Add tests to cover following scenarios
- check optional fields only if template loaded
- it should return warning only if template is loaded
* enable color in windows (#3634)
* enable color in windows
* fixed win workflow
* typo update
---------
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
Co-authored-by: Ramana Reddy <ramanaredy.manda@gmail.com>
Co-authored-by: Suraj Kamath <kamathsuraj95@gmail.com>
Co-authored-by: Shubham Rasal <shubham@projectdiscovery.io>
* Templates wrong loading
* Add tests to cover following scenarios
- check optional fields only if template loaded
- it should return warning only if template is loaded
* Make severity attribute required
* Update test err msg
* minor
* Do not strict check serverity
* Fix failing test
* Don't print warning in workflow loader
- workflow loader that contains tags load all the template and parse it
- i.e it iw printing warning recursively, ignore as the templates
already getting valiated
* Fix error typo
* Resolve comments
- split the function into two diff
---------
Co-authored-by: Mzack9999 <mzack9999@protonmail.com>
Co-authored-by: Sandeep Singh <sandeep@projectdiscovery.io>
Co-authored-by: shubhamrasal <shubhamdharmarasal@gmail.com>
* Add fields from Classification section in a template to the -tc flag expression evaluation
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
* Add tests for filtering Classification section using -tc flag
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
* Fix hyphenated Metadata keys beings added to parameters
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
* Add tests to the fix for hyphenated fields encountered in Metadata section
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
---------
Signed-off-by: iamargus95 <kamathsuraj95@gmail.com>
* Initial library creation for downloading blobs from Azure
* Environment variable hooks for Azure config values
* Missing configuration checks for Azure blob connection
* Package dependencies for Azure client library
* Make output directory if it doesn't exist, add log for downloaded templates
* Add example formats for Azure properties
* Add path to the output after download
* Only download .yaml files instead of also .yml .json
* Evaluate payload variables
* Add variables evaluation
* Extend variables test
- to check evaluation of global variables in variables
- to check evaluation of golbal variables in payload
* Add default and cli variables to websocket, whois and dns proto
- use url.Parse with urlutil.Parse
* add mkdir support in headless screenshot
* use filepath to join paths
* print info when screenshot is saved
* change version to v2.9.1-dev
* minor fixings on windows path
---------
Co-authored-by: Mzack9999 <mzack9999@protonmail.com>
This will ensure that the host spray scanning strategy will actually
run rather than the system exiting quickly if that strategy is
applied. Once merged, this will resolveprojectdiscovery/nuclei#3463.
* Add http and tcp variables support in templates
* Update protocol name from networks to tcp
* Check template to use only one variable(either old or new ones)
- you can use http or requests | network or tcp
- add template doc example
* remove debug statement
* Add comment on new variables,
- New variables are not used in lib code
---------
Co-authored-by: Tarun Koyalwar <tarun@projectdiscovery.io>