| 36 | return |
| 37 | |
| 38 | def Search(flag,lsbox=None,low=10000,high=30000,maxtot=1000): |
| 39 | global timeset |
| 40 | timeset=0 |
| 41 | if lsbox!=None: |
| 42 | lsbox.insert(tk.END,"Searching from {0} to {1}".format(low,high)) |
| 43 | try: |
| 44 | f=open("web_list.txt",'r',encoding='utf-8') |
| 45 | lines=f.readlines() |
| 46 | f.close() |
| 47 | except: |
| 48 | lines=[] |
| 49 | f=open("web_list.txt",'a',encoding='utf-8') |
| 50 | queue=list(range(low,high+1)) |
| 51 | random.shuffle(queue) |
| 52 | for i in queue: |
| 53 | if(flag[0]): |
| 54 | break |
| 55 | while tot>maxtot: |
| 56 | continue |
| 57 | # print(i) |
| 58 | url="https://{0}.gradio.app/".format(i) |
| 59 | if url in lines: |
| 60 | continue |
| 61 | _thread.start_new_thread(Bing,(lsbox,url,f)) |
| 62 | time.sleep(0.005) |
| 63 | time.sleep(0.5) |
| 64 | while tot>0: |
| 65 | continue |
| 66 | f.close() |
| 67 | if lsbox!=None: |
| 68 | lsbox.insert(tk.END,"Searching Over") |