Skip to content

Commit f70cbb8

Browse files
committed
1 parent ad1737a commit f70cbb8

File tree

6 files changed

+48
-45
lines changed

6 files changed

+48
-45
lines changed

Fern-Wifi-Cracker/core/fern.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
from gui.main_window import *
2525

26-
__version__= 2.7
26+
__version__= 2.8
2727

2828
#
2929
# Main Window Class
@@ -75,6 +75,7 @@ def __init__(self):
7575
self.timer.setInterval(3000)
7676

7777

78+
7879
#self.DoubleClicked.connect(self.mouseDoubleClickEvent)
7980
self.refresh_intfacebutton.clicked.connect(self.refresh_interface)
8081
self.interface_combo.currentIndexChanged['QString'].connect(self.setmonitor)

Fern-Wifi-Cracker/core/toolbox/bruteforce_core.py

Lines changed: 40 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,14 @@
2525
# You should have received a copy of the GNU General Public License
2626
# along with this program. If not, see <http://www.gnu.org/licenses/>.
2727

28-
import re
29-
import time
30-
import base64
31-
import ftplib
32-
import socket
33-
import urllib2
28+
import re
29+
import time
30+
import base64
31+
import ftplib
32+
import socket
33+
import urllib2
3434

35-
from PyQt5 import QtCore
35+
from PyQt5 import QtCore
3636

3737

3838
class HTTP_Authentication(object):
@@ -110,11 +110,11 @@ def login_ftp(self,username,password):
110110

111111

112112
class Bruteforce_Attack(QtCore.QThread):
113-
successful_login_signal = QtCore.pyqtSignal('QString', 'QString')
114-
We_Got_Error_signal = QtCore.pyqtSignal()
115-
Next_Try_signal = QtCore.pyqtSignal()
116-
Finished_bruteforce_signal = QtCore.pyqtSignal()
117-
113+
successful_login_signal = QtCore.pyqtSignal('QString', 'QString')
114+
We_Got_Error_signal = QtCore.pyqtSignal()
115+
Next_Try_signal = QtCore.pyqtSignal()
116+
Finished_bruteforce_signal = QtCore.pyqtSignal()
117+
118118
def __init__(self):
119119
QtCore.QThread.__init__(self)
120120
self._timer = 0
@@ -201,49 +201,49 @@ def _run_bruteforce(self):
201201
self.next_try_details = (self._calculate_percentage(),username,password)
202202
try:
203203
self.bruteforce_http_method.login_http(username,password) # TELNET HERE
204-
self.successful_login_signal.emit(username, password)
204+
self.successful_login_signal.emit(username, password)
205205
except Exception,message:
206206
if("connection timed out" in str(message).lower()):
207207
self._error_message = "Unable to connect to the remote address, Connection timed out"
208-
self.We_Got_Error_signal.emit()
208+
self.We_Got_Error_signal.emit()
209209
return
210210
if("no route to host" in str(message).lower()):
211211
self._error_message = "Unable to connect to the remote address, Connection timed out"
212-
self.We_Got_Error_signal.emit()
212+
self.We_Got_Error_signal.emit()
213213
return
214214

215215
if("error 404" in str(message).lower()):
216216
self._error_message = "The remote target returned an HTTP 404 error code, meaning that the requested page does not exist"
217-
self.We_Got_Error_signal.emit()
217+
self.We_Got_Error_signal.emit()
218218
return
219219

220220
if("name or service not known" in str(message).lower()):
221221
self._error_message = "Unable to connect to the remote address, Connection timed out"
222-
self.We_Got_Error_signal.emit()
222+
self.We_Got_Error_signal.emit()
223223
return
224224

225225
if("unreachable" in str(message).lower()):
226226
self._error_message = "Unable to connect to the remote address, Connection timed out"
227-
self.We_Got_Error_signal.emit()
227+
self.We_Got_Error_signal.emit()
228228
return
229229

230230
if("connection refused" in str(message).lower()):
231231
self._error_message = "The connection was refused by the remote service, Please try again"
232-
self.We_Got_Error_signal.emit()
232+
self.We_Got_Error_signal.emit()
233233
return
234234

235235
if("no address associated" in str(message).lower()):
236236
self._error_message = "No address is associated with the target hostname"
237-
self.We_Got_Error_signal.emit()
237+
self.We_Got_Error_signal.emit()
238238
return
239239

240240
if(self.control == False):
241241
return
242242

243-
self.Next_Try_signal.emit()
243+
self.Next_Try_signal.emit()
244244
time.sleep(self._timer)
245245

246-
self.Finished_bruteforce_signal.emit()
246+
self.Finished_bruteforce_signal.emit()
247247
self.control = False
248248

249249

@@ -257,44 +257,44 @@ def _run_bruteforce(self):
257257
self.next_try_details = (self._calculate_percentage(),username,password)
258258
try:
259259
if(self.bruteforce_http_method.login_telnet(username,password)): # FTP HERE
260-
self.successful_login_signal.emit(username, password)
260+
self.successful_login_signal.emit(username, password)
261261
except Exception,message:
262262
if("name or service not known" in str(message).lower()):
263263
self._error_message = "Unable to resolve target hostname"
264-
self.We_Got_Error_signal.emit()
264+
self.We_Got_Error_signal.emit()
265265
return
266266

267267
if("connection timed out" in str(message).lower()):
268268
self._error_message = "Unable to connect to the remote address, Connection timed out"
269-
self.We_Got_Error_signal.emit()
269+
self.We_Got_Error_signal.emit()
270270
return
271271
if("no route to host" in str(message).lower()):
272272
self._error_message = "Unable to connect to the remote address, Connection timed out"
273-
self.We_Got_Error_signal.emit()
273+
self.We_Got_Error_signal.emit()
274274
return
275275

276276
if("unreachable" in str(message).lower()):
277277
self._error_message = "Unable to connect to the remote address, Connection timed out"
278-
self.We_Got_Error_signal.emit()
278+
self.We_Got_Error_signal.emit()
279279
return
280280

281281
if("connection refused" in str(message).lower()):
282282
self._error_message = "The connection was refused by the remote service, Please try again"
283-
self.We_Got_Error_signal.emit()
283+
self.We_Got_Error_signal.emit()
284284
return
285285

286286
if("no address associated" in str(message).lower()):
287287
self._error_message = "No address is associated with the target hostname"
288-
self.We_Got_Error_signal.emit()
288+
self.We_Got_Error_signal.emit()
289289
return
290290

291291
if(self.control == False):
292292
return
293293

294-
self.Next_Try_signal.emit()
294+
self.Next_Try_signal.emit()
295295
time.sleep(self._timer)
296296

297-
self.Finished_bruteforce_signal.emit()
297+
self.Finished_bruteforce_signal.emit()
298298
self.control = False
299299

300300

@@ -308,45 +308,45 @@ def _run_bruteforce(self):
308308
self.next_try_details = (self._calculate_percentage(),username,password)
309309
try:
310310
self.bruteforce_http_method.login_ftp(username,password) # FTP HERE
311-
self.successful_login_signal.emit(username, password)
311+
self.successful_login_signal.emit(username, password)
312312
except Exception,message:
313313
if("name or service not known" in str(message).lower()):
314314
self._error_message = "Unable to resolve target hostname"
315-
self.We_Got_Error_signal.emit()
315+
self.We_Got_Error_signal.emit()
316316
return
317317

318318
if("connection timed out" in str(message).lower()):
319319
self._error_message = "Unable to connect to the remote address, Connection timed out"
320-
self.We_Got_Error_signal.emit()
320+
self.We_Got_Error_signal.emit()
321321
return
322322
if("no route to host" in str(message).lower()):
323323
self._error_message = "Unable to connect to the remote address, Connection timed out"
324-
self.We_Got_Error_signal.emit()
324+
self.We_Got_Error_signal.emit()
325325
return
326326

327327
if("unreachable" in str(message).lower()):
328328
self._error_message = "Unable to connect to the remote address, Connection timed out"
329-
self.We_Got_Error_signal.emit()
329+
self.We_Got_Error_signal.emit()
330330
return
331331

332332
if("connection refused" in str(message).lower()):
333333
self._error_message = "The connection was refused by the remote service, Please try again"
334-
self.We_Got_Error_signal.emit()
334+
self.We_Got_Error_signal.emit()
335335
return
336336

337337

338338
if("no address associated" in str(message).lower()):
339339
self._error_message = "No address is associated with the target hostname"
340-
self.We_Got_Error_signal.emit()
340+
self.We_Got_Error_signal.emit()
341341
return
342342

343343
if(self.control == False):
344344
return
345345

346-
self.Next_Try_signal.emit()
346+
self.Next_Try_signal.emit()
347347
time.sleep(self._timer)
348348

349-
self.Finished_bruteforce_signal.emit()
349+
self.Finished_bruteforce_signal.emit()
350350
self.control = False
351351

352352

Fern-Wifi-Cracker/core/tools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ def __init__(self):
218218

219219

220220
def open_website(self):
221-
QtWidgets.QDesktopServices.openUrl(QtCore.QUrl("http://www.fern-pro.com/"))
221+
QtGui.QDesktopServices.openUrl(QtCore.QUrl("http://www.fern-pro.com/"))
222222
self.toggle_tip()
223223
self.close()
224224

Fern-Wifi-Cracker/core/wep.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ def __init__(self):
7373

7474
self.new_access_point_detected_signal.connect(self.display_new_access_point)
7575

76-
self.general_group_box.DoubleClicked.connect(self.mouseDoubleClickEvent)
76+
#self.general_group_box.DoubleClicked.connect(self.mouseDoubleClickEvent)
7777
self.ap_listwidget.itemSelectionChanged.connect(self.display_selected_target)
7878
self.attack_button.clicked.connect(self.launch_attack)
7979
self.wps_attack_radio.clicked.connect(self.check_reaver_status)
@@ -676,9 +676,11 @@ def crack_wep(self):
676676
directory = '/tmp/fern-log/WEP-DUMP/'
677677
variables.exec_command('killall aircrack-ng')
678678
process = subprocess.Popen('aircrack-ng '+ directory + 'wep_dump-01.cap -l '+ directory + 'wep_key.txt',shell = True,stdout = subprocess.PIPE,stderr = subprocess.PIPE,stdin = subprocess.PIPE)
679+
679680
status = process.stdout
680681
while 'wep_key.txt' not in os.listdir('/tmp/fern-log/WEP-DUMP/'):
681-
if 'Failed. Next try with' in status.readline():
682+
output = status.readline()
683+
if 'Failed. Next try with' in output:
682684
thread.start_new_thread(self.crack_wep,())
683685
break
684686
time.sleep(40)
-9.56 KB
Loading

Fern-Wifi-Cracker/version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
version = 2.7
1+
version = 2.8
22
total_files = 81

0 commit comments

Comments
 (0)