zzmez commited on
Commit
236f43c
·
1 Parent(s): 2d732cf

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +150 -0
app.py ADDED
@@ -0,0 +1,150 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+ from utils.gradio_utils import *
3
+
4
+ domains_template = """tenderax.com
5
+ reach-fortune.com
6
+ joyful-healthy-hair.com
7
+ roadbastion.com
8
+ telesellshow.com
9
+ quoteinalley.com
10
+ pulsetrens.com
11
+ conzurup.com
12
+ enhancexp.com
13
+ crystaldump.com
14
+ wizuite.com
15
+ rental-navigate.com
16
+ habitatbutler.com
17
+ equir-group.com
18
+ gardenscented.com
19
+ send-xp.com
20
+ muzicarea.com
21
+ markiq-brand.com
22
+ oceanoger.com
23
+ sagepagecos.com
24
+ onestopdistribute.com
25
+ zotep.com
26
+ social-ascend.com
27
+ sorganbell.com
28
+ dotbokeeping.com
29
+ prentior.com
30
+ allign-simple.com
31
+ healthskoot.com
32
+ busadminister.com
33
+ roboryzor.com
34
+ theadaptivetrips.com
35
+ neat-true.com
36
+ race-move.com
37
+ chap-views.com
38
+ sunysuites.com
39
+ willpowersocial.com
40
+ avantezores.com
41
+ snortbears.com
42
+ avatarctica.com
43
+ realbloxes.com
44
+ tradessprint.com
45
+ pulsecoverage.com
46
+ devicesco.com
47
+ skyward-bill-board.com
48
+ match-salon-finder.com
49
+ appcanister.com
50
+ natural-dermi-cool.com
51
+ appotor.com
52
+ kid-pocket.com
53
+ cebnext.com
54
+ inno-crista.com
55
+ craftitbyhand.com
56
+ taveas.com
57
+ pro-story-anthology.com
58
+ textropolitan.com
59
+ decorld.com
60
+ knockand-blok.com
61
+ stratusdomain.com
62
+ cloriyes.com
63
+ intromobs.com
64
+ funnygrids.com
65
+ bright-seen.com
66
+ close-stop.com
67
+ lets-tech.com
68
+ globehereme.com
69
+ lemon-abode.com
70
+ skyzark.com
71
+ tracwares.com
72
+ extraclubs.com
73
+ magicspix.com
74
+ technayas.com
75
+ queltys.com
76
+ meta-choose.com
77
+ salesultrax.com
78
+ travelingnarrative.com
79
+ domtions.com
80
+ rising-beats.com
81
+ vintacrafts.com
82
+ blaze-trophy.com
83
+ clever-wiz.com
84
+ encraftey.com
85
+ canvats.com
86
+ ad-nu-vu.com
87
+ thehandshops.com
88
+ craft-pleasure.com
89
+ patio-style-chef.com
90
+ rollerdip.com
91
+ skilled-code.com
92
+ atomic-boom.com
93
+ thedropgears.com"""
94
+
95
+
96
+ with gr.Blocks() as aeon:
97
+ with gr.Tab(label="Mix domains and IPs"):
98
+ with gr.Row():
99
+ with gr.Column():
100
+ ip_subclasses_raw = gr.Textbox(label="IP Subclasses plain text", \
101
+ value="""192.168.1.1/24""", lines=2)
102
+ with gr.Column():
103
+ num_of_ips = gr.Number(label="Number of IPs per /24", value=4)
104
+ with gr.Row():
105
+ domains_raw = gr.Textbox(label="Domains", value="gogu.com\nasd.com\ndsa.com\ngigi.com")
106
+ greet_btn = gr.Button("Compute IPs")
107
+ output_ips = gr.Textbox(label="List of IPs")
108
+
109
+ greet_btn.click(fn=generate_ips_per_subclass, inputs=[ip_subclasses_raw, num_of_ips],\
110
+ outputs=output_ips)
111
+
112
+
113
+ output_mix = gr.Code(label="Mixed IPs and Domains")
114
+
115
+ with gr.Row():
116
+ with gr.Column():
117
+ reset_btn = gr.ClearButton(label="Reset", components=[ip_subclasses_raw, domains_raw])
118
+ with gr.Column():
119
+ mix_btn = gr.Button("Mix IPs and Domains")
120
+ mix_btn.click(fn=mix, inputs=[domains_raw, output_ips, num_of_ips],\
121
+ outputs=output_mix)
122
+ with gr.Tab(label="SWAKS"):
123
+ with gr.Row():
124
+ with gr.Column():
125
+ ip_addresses_raw = gr.Textbox(lines=2, value="192.168.1.1/24", label="IP Classes")
126
+ with gr.Column():
127
+ with gr.Row():
128
+ with gr.Column():
129
+ max_ips = gr.Number(value=0, label="Max IPs to search for before stopping")
130
+ with gr.Column():
131
+ sample_size = gr.Number(value=5, label="Number of commands per subdomain")
132
+ domains = gr.Textbox(lines=5, max_lines=5,value=domains_template, label="Domains")
133
+ with gr.Row():
134
+ header_box = gr.Textbox(label="Header Used to Create Commands", visible=False)
135
+ max_ips.change(fn=update_header, inputs=max_ips, outputs=header_box)
136
+ with gr.Row():
137
+ with gr.Column():
138
+ gen_cmds_btn = gr.Button(label="Generate Commands")
139
+
140
+ # with gr.Column():
141
+ # reset_btn = gr.ClearButton(components=[ip_subclasses_raw, num_of_ips, domains_raw])
142
+ with gr.Row():
143
+ cmds = gr.Code(lines=20, value="Generate Commands")
144
+
145
+ gen_cmds_btn.click(fn=generate_cmds_from_bulk, inputs=[ip_addresses_raw, domains, max_ips, sample_size], outputs=[cmds])
146
+
147
+ with gr.Accordion("Tips and tricks"):
148
+ gr.Markdown("The subdomains are IPs from [1-19] and [201-254]")
149
+
150
+ aeon.launch(auth=("admin", "13441369"), share=True)