### [CVE-2021-23362](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-23362) ![](https://img.shields.io/static/v1?label=Product&message=hosted-git-info&color=blue) ![](https://img.shields.io/static/v1?label=Version&message=unspecified%20&color=brightgreen) ![](https://img.shields.io/static/v1?label=Vulnerability&message=Regular%20Expression%20Denial%20of%20Service%20(ReDoS)&color=brightgreen) ### Description The package hosted-git-info before 3.0.8 are vulnerable to Regular Expression Denial of Service (ReDoS) via regular expression shortcutMatch in the fromUrl function in index.js. The affected regular expression exhibits polynomial worst-case time complexity. ### POC #### Reference - https://github.com/npm/hosted-git-info/commits/v2 - https://snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-1088356 - https://snyk.io/vuln/SNYK-JS-HOSTEDGITINFO-1088355 #### Github - https://github.com/engn33r/awesome-redos-security - https://github.com/marcosrg9/YouTubeTV - https://github.com/retr0-13/auditjs - https://github.com/sonatype-nexus-community/auditjs