MCPcopy
hub / github.com/nsonaniya2010/SubDomainizer / subextractor

Function subextractor

SubDomainizer.py:626–662  ·  view source on GitHub ↗

This function is used to call other functions to find secrets, cloud URLs etc. Parameters -------- cloudlist: object Precompiled regex object to find cloud URLs. p: object Precompiled regex object to find secret (high entropy strings) from content in the list.

(cloudlist, p, regex, ipv4reg, url)

Source from the content-addressed store, hash-verified

624
625
626def subextractor(cloudlist, p, regex, ipv4reg, url):
627 """
628
629 This function is used to call other functions to find secrets, cloud URLs etc.
630
631 Parameters
632 --------
633 cloudlist: object
634 Precompiled regex object to find cloud URLs.
635 p: object
636 Precompiled regex object to find secret (high entropy strings) from content in the list.
637 regex: object
638 Precompiled regex object to find subdomains for a given domain.
639 ipv4reg: object
640 Precompiled regex object to find IP version 4 addresses within content.
641 url: str
642 Original URL from user provided input (URL argument).
643 """
644 jsfile = JsExtract()
645 jsfile.IntJsExtract(url, heads)
646 jsfile.ExtJsExtract(url, heads)
647 jsthread = ThreadPool(300)
648 jsthread.map(jsfile.SaveExtJsContent, jsLinkList)
649 jsthread.close()
650 jsthread.join()
651 print(termcolor.colored("Finding secrets, cloud URLs, subdomains in all Javascript files...",
652 color='yellow',
653 attrs=['bold']))
654 threads = ThreadPool(300)
655 threads.starmap(getInfoFromData,
656 zip(new_final_dict.keys(), new_final_dict.values(), repeat(cloudlist), repeat(p), repeat(regex),
657 repeat(ipv4reg), repeat(url)))
658 threads.close()
659 threads.join()
660 print(termcolor.colored("Searching completed...",
661 color='blue', attrs=['bold']))
662 finallist.clear()
663
664
665def savedata():

Callers 1

SubDomainizer.pyFile · 0.85

Calls 3

IntJsExtractMethod · 0.95
ExtJsExtractMethod · 0.95
JsExtractClass · 0.85

Tested by

no test coverage detected