Open prayas7102 opened 2 days ago
Hey there, I put together a quick script to see if I understood the workings. I would like to know if it is something that could satisfy the 3 steps, mentioned in the issue, before I'd look into adding a PR. Since, I am not particularly familiar with NPM packaging, and haven't been upto date with JS/TS recently. Cheers :)
You can consolidate the four files (
DetectBruteForceAttack.ts
,DetectInputValidation.ts
,InsecureAuthentication.ts
, andAnalyzeSecurityHeaders.ts
) into a single script since they share common libraries and calling functions. The only variation between these files is the dataset, which can be loaded based on the specific vulnerability check being performed.By creating a single script, you can automate the detection of brute force attacks, input validation, insecure authentication, and security header analysis. This script can selectively load the appropriate dataset according to the type of vulnerability being checked, making the process more efficient and reducing code duplication.
Key steps:
This approach simplifies the process and ensures scalability when adding new vulnerability checks in the future.
Make sure the end user/developer (who downloads the NPM package) is able to smoothly run the NPM package after these changes.