GerbenJavado / LinkFinder

A python script that finds endpoints in JavaScript files
https://gerbenjavado.com/discovering-hidden-content-using-linkfinder
MIT License
3.64k stars 588 forks source link

Regex not recognize filenames with extra dot in it #59

Open alex1704 opened 5 years ago

alex1704 commented 5 years ago

File example:

<html>
<body>
<script src="some-name.anotherone.js"></script>
</body>
</html>

Command: python linkfinder.py -i s.html -o cli outputs nothing Solution: Changing reqular expression by adding dot to filename regex. from: ([a-zA-Z0-9_\-]{1,} # filename to: ([a-zA-Z0-9_\-.]{1,} # filename

jarombrown commented 5 years ago

I'm having the same issue as @alex1704. Here is a shared regex with the change.

https://regex101.com/r/Oxciyz/2

Still seems to be missing some js files.

EdOverflow commented 5 years ago

@alex1704 & @jarombrown, please feel free to submit a pull request for this issue if you think your updated regular expression fixes this issue and I will review it.

alex1704 commented 5 years ago

Created - https://github.com/GerbenJavado/LinkFinder/pull/66