+ 13
CHALLENGE: Write a Brute force code
Brute force is a trial and error method used to crack passwords. Brute force cracking uses every possible combination of letters, numbers and symbols at every possible lengths to crack the password. Challenge: Write a code that uses the Brute force method to crack a password that has a length of more than 2 characters . Your code must include: âą a variable that contains the password âą an array of symbols,letters and numbers âą a function that will combine all the values from the array to find the password
13 RĂ©ponses
+ 8
@MrCoder, yes, I totally agree with you, the given code is just an incomplete example due to SL limitations.. Do you have some fully working program? Share it with us! :)
+ 7
I have not written my own one (yet), but just the other day I found this video.
https://youtu.be/0PM10vOtd6o
It explains how bruteforce works and I learned a lot from it (It is in java, just like the code of @thex).
+ 6
Another example, this one cracks SHA1 hashes...
https://code.sololearn.com/cpZmxS2B8657/#py
+ 6
@MrCoder Thanks for sharing! Here is a little program I wrote some time ago, it uses brute force algorithm to create lists of passwords or dictionaries (like Hashcat does, but easier to use):
https://bitbucket.org/ksaver/kranky/src/45d3d1b53e878dc5a7729b34f3745254df7823f2/src/kranky.py
+ 5
Here is an example code written in Python:
https://code.sololearn.com/cd8Y1zz4Qkg5/#py
Due to SoloLearn Time Limits, charset contains a limited set of characters, but in your Python interpreter you can try it with some larger samples..
+ 5
How about this :P. Written in Java.
https://code.sololearn.com/cdB72Z8jCETo
but not working well in playground with many places because of memory limit ;)
--------------
Ad: In the meantime I also created a recursive version. Here the link to both projects on Github I uploaded the iterative and the recursive. The iterative is the same like the one I uploaded to Codelearn.
https://github.com/thexmanxyz/kata-bruteforce-iterative
https://github.com/thexmanxyz/kata-bruteforce-recursive
+ 4
Just giving this info what a REAL Brute Force is
Your code must never use the password, You can't use its length and contents in the code. Also it is like
aaa
aab
aac
...
aaz
aba
+ 4
You sure do use your own algorithm :) It's nice, my code is shortened because of .next! function in rb
+ 3
my try...with automatic key length setter...
https://code.sololearn.com/c3vprJdNVDJY/?ref=app
+ 3
Enjoyed this, thanks. Not the most pythonic and there's at least one too many variables being passed to the sub
https://code.sololearn.com/c1lsvj0olzJF/?ref=app
+ 3
Thank you :), Yes I do have a brute force software I'm afraid it lacks some feature, I'll put it in github then I'll put the link :D
+ 3
@noobcĂžder Here you go buddy
https://github.com/Z34O/brute-force
+ 2
@The Coding Sloth, that's a nice recursive solution mine is just iterative :). I watched the video right now. I will try that one later.