Skip to content

Commit

Permalink
Update dirfinder.py
Browse files Browse the repository at this point in the history
  • Loading branch information
CyberPlatoon authored Mar 4, 2023
1 parent f94a8c4 commit 99036b0
Showing 1 changed file with 19 additions and 7 deletions.
26 changes: 19 additions & 7 deletions dirfinder.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import requests
from termcolor import colored
import subprocess



Expand All @@ -17,6 +18,7 @@
=======================================================
-By Pradeep Kumar
https://github.com/CyberPlatoon/
""", 'green'))


Expand All @@ -40,7 +42,7 @@
print("\n")


Output = open("Output/"+Output_File, "w")
#Output = open("Output/"+Output_File, "w")
file = open(wordlist+".txt", "r")
file_Ex = open("extensions.txt", "r")

Expand All @@ -51,21 +53,28 @@
#print("{} and {}".format(url,response.status_code))
status =response.status_code
size = response.headers.get('content-length', 0)
#SubOutput = str(subprocess.run("echo "+url+" > Output/"+Output))


if response.status_code==200:
#print(url+" ===> 200")
stu200 = url+" ===> 200"
print(colored(" [+] ", 'green') + stu200)
Output.write(stu200+"\n")
#print(SubOutput)
Output = open("Output/"+Output_File, "w")
Output.write(url)
Output.close()




if response.status_code==403:
#print(url+" ===> 403")
stu403 = url+" ===> 403"
print(colored(" [+] ", 'red') + stu403)
Output.write(stu403+"\n")
Output = open("Output/"+Output_File, "w")
Output.write(url)
Output.close()



Expand All @@ -90,16 +99,19 @@
#print(url+" ===> 200")
satatus200 = url+" ===> 200"
print(colored(" [+] ", 'green') + satatus200)
Output.write(satatus200+"\n")
Output = open("Output/"+Output_File, "w")
Output.write(url)
Output.close()



if response.status_code==403:
#print(url+" ===> 403")
satatus403 = url+" ===> 403"
print(colored(" [+] ", 'red') + satatus403)
Output.write(satatus403+"\n")

Output = open("Output/"+Output_File, "w")
Output.write(url)
Output.close()



Expand All @@ -110,7 +122,7 @@



Output.close()

file.close()
file_Ex.close()

Expand Down

0 comments on commit 99036b0

Please sign in to comment.