violent_ruby 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +12 -0
- data/.rspec +2 -0
- data/.travis.yml +5 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +131 -0
- data/Rakefile +6 -0
- data/bin/python_sucks +18 -0
- data/lib/violent_ruby.rb +11 -0
- data/lib/violent_ruby/ftp_brute_forcer/README.md +421 -0
- data/lib/violent_ruby/ftp_brute_forcer/Vagrantfile +30 -0
- data/lib/violent_ruby/ftp_brute_forcer/ftp_brute_forcer.rb +143 -0
- data/lib/violent_ruby/ssh_brute_forcer/README.md +131 -0
- data/lib/violent_ruby/ssh_brute_forcer/Vagrantfile +20 -0
- data/lib/violent_ruby/ssh_brute_forcer/ssh_brute_forcer.rb +206 -0
- data/lib/violent_ruby/unix_password_cracker/README.md +38 -0
- data/lib/violent_ruby/unix_password_cracker/unix_password_cracker.rb +117 -0
- data/lib/violent_ruby/version.rb +3 -0
- data/lib/violent_ruby/vulnerability_scanner/README.md +88 -0
- data/lib/violent_ruby/vulnerability_scanner/vulnerability_scanner.rb +275 -0
- data/resources/dictionary.txt +7 -0
- data/resources/etc_passwd_file +2 -0
- data/resources/ftp_ips.txt +1 -0
- data/resources/ftp_passwords.txt +5 -0
- data/resources/ftp_ports.txt +2 -0
- data/resources/ftp_users.txt +6 -0
- data/resources/ssh_ips.txt +1 -0
- data/resources/ssh_passwords.txt +3 -0
- data/resources/ssh_ports.txt +2 -0
- data/resources/ssh_users.txt +4 -0
- data/violent_ruby.gemspec +28 -0
- metadata +148 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: b695549147a05c96fe7b4826dfb03e5db7510ccf
|
4
|
+
data.tar.gz: c4320ebaa7cf05c18b4b2ad0f4dd3a5fe56513c8
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: b458561b7678717776fa90a8d49ef9a5860f505b7f5c21f2d6b138f25891b030c3898085ce0d8bfff6653c462c1db7033fa1233ff9899890379bc96875cfaed0
|
7
|
+
data.tar.gz: fbf8936c616b3832a4f9d6926debac7b3b13e38dbb390b2a501aa17f2dd84da2350fea8d56bb049d5525f691c2744ddafb7a140cc3a732ef2c09d3829c78c2a1
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
2
|
+
|
3
|
+
## Our Pledge
|
4
|
+
|
5
|
+
In the interest of fostering an open and welcoming environment, we as
|
6
|
+
contributors and maintainers pledge to making participation in our project and
|
7
|
+
our community a harassment-free experience for everyone, regardless of age, body
|
8
|
+
size, disability, ethnicity, gender identity and expression, level of experience,
|
9
|
+
nationality, personal appearance, race, religion, or sexual identity and
|
10
|
+
orientation.
|
11
|
+
|
12
|
+
## Our Standards
|
13
|
+
|
14
|
+
Examples of behavior that contributes to creating a positive environment
|
15
|
+
include:
|
16
|
+
|
17
|
+
* Using welcoming and inclusive language
|
18
|
+
* Being respectful of differing viewpoints and experiences
|
19
|
+
* Gracefully accepting constructive criticism
|
20
|
+
* Focusing on what is best for the community
|
21
|
+
* Showing empathy towards other community members
|
22
|
+
|
23
|
+
Examples of unacceptable behavior by participants include:
|
24
|
+
|
25
|
+
* The use of sexualized language or imagery and unwelcome sexual attention or
|
26
|
+
advances
|
27
|
+
* Trolling, insulting/derogatory comments, and personal or political attacks
|
28
|
+
* Public or private harassment
|
29
|
+
* Publishing others' private information, such as a physical or electronic
|
30
|
+
address, without explicit permission
|
31
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
32
|
+
professional setting
|
33
|
+
|
34
|
+
## Our Responsibilities
|
35
|
+
|
36
|
+
Project maintainers are responsible for clarifying the standards of acceptable
|
37
|
+
behavior and are expected to take appropriate and fair corrective action in
|
38
|
+
response to any instances of unacceptable behavior.
|
39
|
+
|
40
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
41
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
42
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
43
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
44
|
+
threatening, offensive, or harmful.
|
45
|
+
|
46
|
+
## Scope
|
47
|
+
|
48
|
+
This Code of Conduct applies both within project spaces and in public spaces
|
49
|
+
when an individual is representing the project or its community. Examples of
|
50
|
+
representing a project or community include using an official project e-mail
|
51
|
+
address, posting via an official social media account, or acting as an appointed
|
52
|
+
representative at an online or offline event. Representation of a project may be
|
53
|
+
further defined and clarified by project maintainers.
|
54
|
+
|
55
|
+
## Enforcement
|
56
|
+
|
57
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
58
|
+
reported by contacting the project team at kgruber1@emich.edu. All
|
59
|
+
complaints will be reviewed and investigated and will result in a response that
|
60
|
+
is deemed necessary and appropriate to the circumstances. The project team is
|
61
|
+
obligated to maintain confidentiality with regard to the reporter of an incident.
|
62
|
+
Further details of specific enforcement policies may be posted separately.
|
63
|
+
|
64
|
+
Project maintainers who do not follow or enforce the Code of Conduct in good
|
65
|
+
faith may face temporary or permanent repercussions as determined by other
|
66
|
+
members of the project's leadership.
|
67
|
+
|
68
|
+
## Attribution
|
69
|
+
|
70
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
+
available at [http://contributor-covenant.org/version/1/4][version]
|
72
|
+
|
73
|
+
[homepage]: http://contributor-covenant.org
|
74
|
+
[version]: http://contributor-covenant.org/version/1/4/
|
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2017 Kent Gruber
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,131 @@
|
|
1
|
+
# Violent Ruby 🎻
|
2
|
+
|
3
|
+
Violent Ruby is a collection of tools for Hackers, Forensic Analysts, Penetration Testers and Security Engineers.
|
4
|
+
|
5
|
+
#### Development Notice
|
6
|
+
|
7
|
+
⚠️ Gem is still in development.
|
8
|
+
|
9
|
+
## Installation
|
10
|
+
|
11
|
+
$ gem install violent_ruby
|
12
|
+
|
13
|
+
## Usage
|
14
|
+
|
15
|
+
```ruby
|
16
|
+
require 'violent_ruby'
|
17
|
+
```
|
18
|
+
|
19
|
+
### Vulnerability Scanner
|
20
|
+
|
21
|
+
The vulnerability scanner is a banner grabber that can check banners on ports and check if they're known to be vulnerable. However, you will need to provide the list of known vulnerable banners yourself.
|
22
|
+
|
23
|
+
```ruby
|
24
|
+
require 'violent_ruby'
|
25
|
+
|
26
|
+
scanner = ViolentRuby::VulnerabilityScanner.new
|
27
|
+
scanner.targets = "127.0.0.1"
|
28
|
+
scanner.known_vulnerabilities = "MS-IIS WEB SERVER 5.0"
|
29
|
+
|
30
|
+
scanner.scan(ports: 80, 8080)
|
31
|
+
# => [{:ip=>"127.0.0.1", :port=>8080, :banner=>"MS-IIS WEB SERVER 5.0"}]
|
32
|
+
```
|
33
|
+
|
34
|
+
### Unix Password Cracker
|
35
|
+
|
36
|
+
The unix password cracker provide a simple interface to crack unix passwords. As hackers do.
|
37
|
+
|
38
|
+
```ruby
|
39
|
+
require 'violent_ruby'
|
40
|
+
|
41
|
+
password_cracker = ViolentRuby::UnixPasswordCracker.new
|
42
|
+
password_cracker.file = "resources/etc_passwd_file"
|
43
|
+
password_cracker.dictionary = "resources/dictionary.txt"
|
44
|
+
|
45
|
+
password_cracker.crack!
|
46
|
+
# => [{:username=>"victim", :encrypted_password=>"HX9LLTdc/jiDE", :plaintext_password=>"egg"}]
|
47
|
+
```
|
48
|
+
|
49
|
+
### FTP Brute Forcer
|
50
|
+
|
51
|
+
The ftp brute forcer can be used to to brute force your way into a server over FTP.
|
52
|
+
|
53
|
+
```ruby
|
54
|
+
require 'violent_ruby'
|
55
|
+
|
56
|
+
ftp = FtpBruteForcer.new
|
57
|
+
ftp.users = "resources/ftp_users.txt"
|
58
|
+
ftp.ports = "resources/ftp_ports.txt"
|
59
|
+
ftp.ips = "resources/ftp_ips.txt"
|
60
|
+
ftp.passwords = "resources/ftp_passwords.txt"
|
61
|
+
|
62
|
+
ftp.brute_force!
|
63
|
+
# => [{:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"vagrant"},
|
64
|
+
# {:time=>2017-04-03 19:02:15 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"ftp"},
|
65
|
+
# {:time=>2017-04-03 19:02:18 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"root"}]
|
66
|
+
```
|
67
|
+
|
68
|
+
### SSH Brute Forcer
|
69
|
+
|
70
|
+
The ssh brute forcer can be used to to brute force your way into a server over SSH.
|
71
|
+
|
72
|
+
```ruby
|
73
|
+
require 'violent_ruby'
|
74
|
+
|
75
|
+
ssh = SSHBruteForcer.new
|
76
|
+
ssh.users = "resources/ssh_users.txt"
|
77
|
+
ssh.ports = "resources/ssh_ports.txt"
|
78
|
+
ssh.ips = "resources/ssh_ips.txt"
|
79
|
+
ssh.passwords = "resources/ssh_passwords.txt"
|
80
|
+
|
81
|
+
ssh.brute_force do |result|
|
82
|
+
result
|
83
|
+
# => [{:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"22", :user=>"vagrant", :password=>"vagrant"},
|
84
|
+
end
|
85
|
+
```
|
86
|
+
### Violent Ruby Shell
|
87
|
+
|
88
|
+
The `Violent Ruby` shell provides quick access to all of Violent Ruby in a custom Pry shell.
|
89
|
+
|
90
|
+
This is provided via a file called `python_sucks` when the gem is installed.
|
91
|
+
|
92
|
+
```ruby
|
93
|
+
$ python_sucks
|
94
|
+
🎻 (main)> scanner = VulnerabilityScanner.new
|
95
|
+
=> #<ViolentRuby::VulnerabilityScanner:0x007fc9531aab20 @known_vulnerabilities=[], @targets=[]>
|
96
|
+
🎻 (main)> scanner.targets = "127.0.0.1"
|
97
|
+
=> "127.0.0.1"
|
98
|
+
scanner.known_vulnerabilities = "MS-IIS WEB SERVER 5.0"
|
99
|
+
=> "MS-IIS WEB SERVER 5.0"
|
100
|
+
scanner.scan(ports: 80, 8080)
|
101
|
+
=> [{:ip=>"127.0.0.1", :port=>8080, :banner=>"MS-IIS WEB SERVER 5.0"}]
|
102
|
+
🎻 (main)>
|
103
|
+
🎻 (main)>
|
104
|
+
🎻 (main)> show-method scanner.retrieve_banner
|
105
|
+
From: /path_to_where_this_is/violent_ruby/lib/violent_ruby/vulnerability_scanner/vulnerability_scanner.rb @ line 107:
|
106
|
+
Owner: ViolentRuby::VulnerabilityScanner
|
107
|
+
Visibility: public
|
108
|
+
Number of lines: 14
|
109
|
+
|
110
|
+
def retrieve_banner(ip, port, seconds = 2)
|
111
|
+
banner = false
|
112
|
+
Timeout.timeout(seconds) do
|
113
|
+
socket = TCPSocket.new(ip, port)
|
114
|
+
banner = socket.recv(1024)
|
115
|
+
socket.close
|
116
|
+
end
|
117
|
+
return false unless banner
|
118
|
+
banner.strip!
|
119
|
+
yield banner if block_given?
|
120
|
+
banner
|
121
|
+
rescue
|
122
|
+
false
|
123
|
+
end
|
124
|
+
🎻 (main)> help
|
125
|
+
🎻 (main)> exit
|
126
|
+
```
|
127
|
+
|
128
|
+
## License
|
129
|
+
|
130
|
+
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
131
|
+
|
data/Rakefile
ADDED
data/bin/python_sucks
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
require 'violent_ruby'
|
3
|
+
require 'pry'
|
4
|
+
|
5
|
+
include ViolentRuby
|
6
|
+
|
7
|
+
prompt_name = '🎻 '
|
8
|
+
|
9
|
+
Pry.config.prompt = [
|
10
|
+
proc { |target_self, nest_level, pry|
|
11
|
+
"#{prompt_name}(#{Pry.view_clip(target_self)})#{":#{nest_level}" unless nest_level.zero?}> "
|
12
|
+
},
|
13
|
+
proc { |target_self, nest_level, pry|
|
14
|
+
"#{prompt_name}(#{Pry.view_clip(target_self)})#{":#{nest_level}" unless nest_level.zero?}* "
|
15
|
+
}
|
16
|
+
]
|
17
|
+
Pry.config.prompt_name = prompt_name
|
18
|
+
Pry.start
|
data/lib/violent_ruby.rb
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
require "violent_ruby/ftp_brute_forcer/ftp_brute_forcer"
|
2
|
+
require "violent_ruby/ssh_brute_forcer/ssh_brute_forcer"
|
3
|
+
require "violent_ruby/vulnerability_scanner/vulnerability_scanner"
|
4
|
+
require "violent_ruby/unix_password_cracker/unix_password_cracker"
|
5
|
+
require "violent_ruby/version"
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
module ViolentRuby
|
10
|
+
# Your code goes here...
|
11
|
+
end
|
@@ -0,0 +1,421 @@
|
|
1
|
+
# FTP Brute Forcer
|
2
|
+
|
3
|
+
Using brute-force, you can easily try to force your way into a server over FTP.
|
4
|
+
|
5
|
+
## Vagrantfile
|
6
|
+
|
7
|
+
In this directory, along with the ruby code and the README.md, you'll find a `Vagrantfile` which you can use to setup a VM to test out the FTP Brute Forcer. This requires you to have [vagrant](https://www.vagrantup.com/) installed.
|
8
|
+
|
9
|
+
#### Start VM
|
10
|
+
|
11
|
+
```shell
|
12
|
+
$ pwd
|
13
|
+
/somewhere/violent_ruby/lib/violent_ruby/ftp_brute_forcer
|
14
|
+
$ ls
|
15
|
+
README.md Vagrantfile ftp_brute_forcer.rb
|
16
|
+
$ vagrant up
|
17
|
+
Bringing machine 'default' up with 'virtualbox' provider...
|
18
|
+
==> default: Importing base box 'debian/jessie64'...
|
19
|
+
==> ect...
|
20
|
+
```
|
21
|
+
|
22
|
+
#### SSH into VM
|
23
|
+
|
24
|
+
Very simply `vagrant ssh` will allow you to SSH into the VM to make changes or monitor the VM while brute-forcing it for blue team research.
|
25
|
+
|
26
|
+
```shell
|
27
|
+
$ vagrant ssh
|
28
|
+
|
29
|
+
The programs included with the Debian GNU/Linux system are free software;
|
30
|
+
the exact distribution terms for each program are described in the
|
31
|
+
individual files in /usr/share/doc/*/copyright.
|
32
|
+
|
33
|
+
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
|
34
|
+
permitted by applicable law.
|
35
|
+
vagrant@jessie:~$
|
36
|
+
```
|
37
|
+
|
38
|
+
The VM should be provisioned with vsftp, and it should be running with anonymous access turned on. Because that's fun.
|
39
|
+
|
40
|
+
#### Stop VM
|
41
|
+
|
42
|
+
If you've logged into the VM via ssh, logout and then use `vagrant destroy` to destroy the VM.
|
43
|
+
|
44
|
+
```shell
|
45
|
+
$ vagrant destroy
|
46
|
+
default: Are you sure you want to destroy the 'default' VM? [y/N] y
|
47
|
+
==> default: Forcing shutdown of VM...
|
48
|
+
==> default: Destroying VM and associated drives...
|
49
|
+
```
|
50
|
+
|
51
|
+
## Initialization
|
52
|
+
|
53
|
+
```ruby
|
54
|
+
require 'violent_ruby'
|
55
|
+
|
56
|
+
ftp = FtpBruteForcer.new
|
57
|
+
```
|
58
|
+
|
59
|
+
## Providing Required Files
|
60
|
+
|
61
|
+
```ruby
|
62
|
+
require 'violent_ruby'
|
63
|
+
|
64
|
+
ftp = FtpBruteForcer.new
|
65
|
+
|
66
|
+
ftp.users = "resources/ftp_users.txt"
|
67
|
+
ftp.ports = "resources/ftp_ports.txt"
|
68
|
+
ftp.ips = "resources/ftp_ips.txt"
|
69
|
+
ftp.passwords = "resources/ftp_passwords.txt"
|
70
|
+
```
|
71
|
+
|
72
|
+
#### Users
|
73
|
+
|
74
|
+
A `.users` file should contain a list of ftp usernames to use.
|
75
|
+
|
76
|
+
```
|
77
|
+
anonymous
|
78
|
+
ftp
|
79
|
+
vagrant
|
80
|
+
root
|
81
|
+
admin
|
82
|
+
picat
|
83
|
+
```
|
84
|
+
|
85
|
+
#### Passwords
|
86
|
+
|
87
|
+
A `.passwords` file should contain a list of ftp passwords to use.
|
88
|
+
|
89
|
+
```
|
90
|
+
vagrant
|
91
|
+
ftp
|
92
|
+
root
|
93
|
+
toor
|
94
|
+
picat
|
95
|
+
```
|
96
|
+
|
97
|
+
#### IPs
|
98
|
+
|
99
|
+
A `.ips` file should contain a list of ip addresses to attempt connections on.
|
100
|
+
|
101
|
+
```
|
102
|
+
192.168.33.9
|
103
|
+
192.168.33.10
|
104
|
+
192.168.33.111
|
105
|
+
```
|
106
|
+
|
107
|
+
#### Ports
|
108
|
+
|
109
|
+
A `.ports` file should contain a list of ports to attempt connections on.
|
110
|
+
|
111
|
+
```
|
112
|
+
21
|
113
|
+
2121
|
114
|
+
```
|
115
|
+
## Brute Force'n
|
116
|
+
|
117
|
+
Once everything has been setup, we're going to be able to try start brute forcing!
|
118
|
+
|
119
|
+
```ruby
|
120
|
+
require 'violent_ruby'
|
121
|
+
|
122
|
+
ftp = FtpBruteForcer.new
|
123
|
+
|
124
|
+
ftp.users = "resources/ftp_users.txt"
|
125
|
+
ftp.ports = "resources/ftp_ports.txt"
|
126
|
+
ftp.ips = "resources/ftp_ips.txt"
|
127
|
+
ftp.passwords = "resources/ftp_passwords.txt"
|
128
|
+
|
129
|
+
results = ftp.brute_force!
|
130
|
+
results
|
131
|
+
# => [{:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"anonymous", :password=>"vagrant"},
|
132
|
+
# {:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"anonymous", :password=>"ftp"},
|
133
|
+
# {:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"anonymous", :password=>"root"},
|
134
|
+
# {:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"anonymous", :password=>"toor"},
|
135
|
+
# {:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"anonymous", :password=>"picat"},
|
136
|
+
# {:time=>2017-04-03 19:02:11 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"ftp", :password=>"vagrant"},
|
137
|
+
# {:time=>2017-04-03 19:02:12 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"ftp", :password=>"ftp"},
|
138
|
+
# {:time=>2017-04-03 19:02:12 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"ftp", :password=>"root"},
|
139
|
+
# {:time=>2017-04-03 19:02:12 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"ftp", :password=>"toor"},
|
140
|
+
# {:time=>2017-04-03 19:02:12 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"ftp", :password=>"picat"},
|
141
|
+
# {:time=>2017-04-03 19:02:12 -0400, :type=>"SUCCESS", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"vagrant"},
|
142
|
+
# {:time=>2017-04-03 19:02:15 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"ftp"},
|
143
|
+
# {:time=>2017-04-03 19:02:18 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"root"},
|
144
|
+
# {:time=>2017-04-03 19:02:21 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"toor"},
|
145
|
+
# {:time=>2017-04-03 19:02:24 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"vagrant", :password=>"picat"},
|
146
|
+
# {:time=>2017-04-03 19:02:27 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"root", :password=>"vagrant"},
|
147
|
+
# {:time=>2017-04-03 19:02:31 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"root", :password=>"ftp"},
|
148
|
+
# {:time=>2017-04-03 19:02:33 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"root", :password=>"root"},
|
149
|
+
# {:time=>2017-04-03 19:02:36 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"root", :password=>"toor"},
|
150
|
+
# {:time=>2017-04-03 19:02:38 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"root", :password=>"picat"},
|
151
|
+
# {:time=>2017-04-03 19:02:42 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"admin", :password=>"vagrant"},
|
152
|
+
# {:time=>2017-04-03 19:02:46 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"admin", :password=>"ftp"},
|
153
|
+
# {:time=>2017-04-03 19:02:48 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"admin", :password=>"root"},
|
154
|
+
# {:time=>2017-04-03 19:02:51 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"admin", :password=>"toor"},
|
155
|
+
# {:time=>2017-04-03 19:02:54 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"admin", :password=>"picat"},
|
156
|
+
# {:time=>2017-04-03 19:02:57 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"picat", :password=>"vagrant"},
|
157
|
+
# {:time=>2017-04-03 19:03:00 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"picat", :password=>"ftp"},
|
158
|
+
# {:time=>2017-04-03 19:03:03 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"picat", :password=>"root"},
|
159
|
+
# {:time=>2017-04-03 19:03:06 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"picat", :password=>"toor"},
|
160
|
+
# {:time=>2017-04-03 19:03:09 -0400, :type=>"FAILURE", :ip=>"192.168.33.10", :port=>"21", :user=>"picat", :password=>"picat"}]
|
161
|
+
```
|
162
|
+
|
163
|
+
#### Results as Json?
|
164
|
+
|
165
|
+
```
|
166
|
+
require 'violent_ruby'
|
167
|
+
require 'json'
|
168
|
+
|
169
|
+
# same setup as before ...
|
170
|
+
|
171
|
+
results = ftp.brute_force!
|
172
|
+
|
173
|
+
# but, now json!
|
174
|
+
|
175
|
+
puts results.to_json
|
176
|
+
|
177
|
+
[
|
178
|
+
{
|
179
|
+
"time":"2017-04-03 20:20:33 -0400",
|
180
|
+
"type":"SUCCESS",
|
181
|
+
"ip":"192.168.33.10",
|
182
|
+
"port":"21",
|
183
|
+
"user":"anonymous",
|
184
|
+
"password":"vagrant"
|
185
|
+
},
|
186
|
+
{
|
187
|
+
"time":"2017-04-03 20:20:33 -0400",
|
188
|
+
"type":"SUCCESS",
|
189
|
+
"ip":"192.168.33.10",
|
190
|
+
"port":"21",
|
191
|
+
"user":"anonymous",
|
192
|
+
"password":"ftp"
|
193
|
+
},
|
194
|
+
{
|
195
|
+
"time":"2017-04-03 20:20:33 -0400",
|
196
|
+
"type":"SUCCESS",
|
197
|
+
"ip":"192.168.33.10",
|
198
|
+
"port":"21",
|
199
|
+
"user":"anonymous",
|
200
|
+
"password":"root"
|
201
|
+
},
|
202
|
+
{
|
203
|
+
"time":"2017-04-03 20:20:33 -0400",
|
204
|
+
"type":"SUCCESS",
|
205
|
+
"ip":"192.168.33.10",
|
206
|
+
"port":"21",
|
207
|
+
"user":"anonymous",
|
208
|
+
"password":"toor"
|
209
|
+
},
|
210
|
+
{
|
211
|
+
"time":"2017-04-03 20:20:33 -0400",
|
212
|
+
"type":"SUCCESS",
|
213
|
+
"ip":"192.168.33.10",
|
214
|
+
"port":"21",
|
215
|
+
"user":"anonymous",
|
216
|
+
"password":"picat"
|
217
|
+
},
|
218
|
+
{
|
219
|
+
"time":"2017-04-03 20:20:33 -0400",
|
220
|
+
"type":"SUCCESS",
|
221
|
+
"ip":"192.168.33.10",
|
222
|
+
"port":"21",
|
223
|
+
"user":"ftp",
|
224
|
+
"password":"vagrant"
|
225
|
+
},
|
226
|
+
{
|
227
|
+
"time":"2017-04-03 20:20:33 -0400",
|
228
|
+
"type":"SUCCESS",
|
229
|
+
"ip":"192.168.33.10",
|
230
|
+
"port":"21",
|
231
|
+
"user":"ftp",
|
232
|
+
"password":"ftp"
|
233
|
+
},
|
234
|
+
{
|
235
|
+
"time":"2017-04-03 20:20:33 -0400",
|
236
|
+
"type":"SUCCESS",
|
237
|
+
"ip":"192.168.33.10",
|
238
|
+
"port":"21",
|
239
|
+
"user":"ftp",
|
240
|
+
"password":"root"
|
241
|
+
},
|
242
|
+
{
|
243
|
+
"time":"2017-04-03 20:20:34 -0400",
|
244
|
+
"type":"SUCCESS",
|
245
|
+
"ip":"192.168.33.10",
|
246
|
+
"port":"21",
|
247
|
+
"user":"ftp",
|
248
|
+
"password":"toor"
|
249
|
+
},
|
250
|
+
{
|
251
|
+
"time":"2017-04-03 20:20:34 -0400",
|
252
|
+
"type":"SUCCESS",
|
253
|
+
"ip":"192.168.33.10",
|
254
|
+
"port":"21",
|
255
|
+
"user":"ftp",
|
256
|
+
"password":"picat"
|
257
|
+
},
|
258
|
+
{
|
259
|
+
"time":"2017-04-03 20:20:34 -0400",
|
260
|
+
"type":"SUCCESS",
|
261
|
+
"ip":"192.168.33.10",
|
262
|
+
"port":"21",
|
263
|
+
"user":"vagrant",
|
264
|
+
"password":"vagrant"
|
265
|
+
},
|
266
|
+
{
|
267
|
+
"time":"2017-04-03 20:20:36 -0400",
|
268
|
+
"type":"FAILURE",
|
269
|
+
"ip":"192.168.33.10",
|
270
|
+
"port":"21",
|
271
|
+
"user":"vagrant",
|
272
|
+
"password":"ftp"
|
273
|
+
},
|
274
|
+
{
|
275
|
+
"time":"2017-04-03 20:20:39 -0400",
|
276
|
+
"type":"FAILURE",
|
277
|
+
"ip":"192.168.33.10",
|
278
|
+
"port":"21",
|
279
|
+
"user":"vagrant",
|
280
|
+
"password":"root"
|
281
|
+
},
|
282
|
+
{
|
283
|
+
"time":"2017-04-03 20:20:42 -0400",
|
284
|
+
"type":"FAILURE",
|
285
|
+
"ip":"192.168.33.10",
|
286
|
+
"port":"21",
|
287
|
+
"user":"vagrant",
|
288
|
+
"password":"toor"
|
289
|
+
},
|
290
|
+
{
|
291
|
+
"time":"2017-04-03 20:20:45 -0400",
|
292
|
+
"type":"FAILURE",
|
293
|
+
"ip":"192.168.33.10",
|
294
|
+
"port":"21",
|
295
|
+
"user":"vagrant",
|
296
|
+
"password":"picat"
|
297
|
+
},
|
298
|
+
{
|
299
|
+
"time":"2017-04-03 20:20:48 -0400",
|
300
|
+
"type":"FAILURE",
|
301
|
+
"ip":"192.168.33.10",
|
302
|
+
"port":"21",
|
303
|
+
"user":"root",
|
304
|
+
"password":"vagrant"
|
305
|
+
},
|
306
|
+
{
|
307
|
+
"time":"2017-04-03 20:20:52 -0400",
|
308
|
+
"type":"FAILURE",
|
309
|
+
"ip":"192.168.33.10",
|
310
|
+
"port":"21",
|
311
|
+
"user":"root",
|
312
|
+
"password":"ftp"
|
313
|
+
},
|
314
|
+
{
|
315
|
+
"time":"2017-04-03 20:20:55 -0400",
|
316
|
+
"type":"FAILURE",
|
317
|
+
"ip":"192.168.33.10",
|
318
|
+
"port":"21",
|
319
|
+
"user":"root",
|
320
|
+
"password":"root"
|
321
|
+
},
|
322
|
+
{
|
323
|
+
"time":"2017-04-03 20:20:57 -0400",
|
324
|
+
"type":"FAILURE",
|
325
|
+
"ip":"192.168.33.10",
|
326
|
+
"port":"21",
|
327
|
+
"user":"root",
|
328
|
+
"password":"toor"
|
329
|
+
},
|
330
|
+
{
|
331
|
+
"time":"2017-04-03 20:21:00 -0400",
|
332
|
+
"type":"FAILURE",
|
333
|
+
"ip":"192.168.33.10",
|
334
|
+
"port":"21",
|
335
|
+
"user":"root",
|
336
|
+
"password":"picat"
|
337
|
+
},
|
338
|
+
{
|
339
|
+
"time":"2017-04-03 20:21:03 -0400",
|
340
|
+
"type":"FAILURE",
|
341
|
+
"ip":"192.168.33.10",
|
342
|
+
"port":"21",
|
343
|
+
"user":"admin",
|
344
|
+
"password":"vagrant"
|
345
|
+
},
|
346
|
+
{
|
347
|
+
"time":"2017-04-03 20:21:06 -0400",
|
348
|
+
"type":"FAILURE",
|
349
|
+
"ip":"192.168.33.10",
|
350
|
+
"port":"21",
|
351
|
+
"user":"admin",
|
352
|
+
"password":"ftp"
|
353
|
+
},
|
354
|
+
{
|
355
|
+
"time":"2017-04-03 20:21:09 -0400",
|
356
|
+
"type":"FAILURE",
|
357
|
+
"ip":"192.168.33.10",
|
358
|
+
"port":"21",
|
359
|
+
"user":"admin",
|
360
|
+
"password":"root"
|
361
|
+
},
|
362
|
+
{
|
363
|
+
"time":"2017-04-03 20:21:12 -0400",
|
364
|
+
"type":"FAILURE",
|
365
|
+
"ip":"192.168.33.10",
|
366
|
+
"port":"21",
|
367
|
+
"user":"admin",
|
368
|
+
"password":"toor"
|
369
|
+
},
|
370
|
+
{
|
371
|
+
"time":"2017-04-03 20:21:15 -0400",
|
372
|
+
"type":"FAILURE",
|
373
|
+
"ip":"192.168.33.10",
|
374
|
+
"port":"21",
|
375
|
+
"user":"admin",
|
376
|
+
"password":"picat"
|
377
|
+
},
|
378
|
+
{
|
379
|
+
"time":"2017-04-03 20:21:19 -0400",
|
380
|
+
"type":"FAILURE",
|
381
|
+
"ip":"192.168.33.10",
|
382
|
+
"port":"21",
|
383
|
+
"user":"picat",
|
384
|
+
"password":"vagrant"
|
385
|
+
},
|
386
|
+
{
|
387
|
+
"time":"2017-04-03 20:21:22 -0400",
|
388
|
+
"type":"FAILURE",
|
389
|
+
"ip":"192.168.33.10",
|
390
|
+
"port":"21",
|
391
|
+
"user":"picat",
|
392
|
+
"password":"ftp"
|
393
|
+
},
|
394
|
+
{
|
395
|
+
"time":"2017-04-03 20:21:25 -0400",
|
396
|
+
"type":"FAILURE",
|
397
|
+
"ip":"192.168.33.10",
|
398
|
+
"port":"21",
|
399
|
+
"user":"picat",
|
400
|
+
"password":"root"
|
401
|
+
},
|
402
|
+
{
|
403
|
+
"time":"2017-04-03 20:21:27 -0400",
|
404
|
+
"type":"FAILURE",
|
405
|
+
"ip":"192.168.33.10",
|
406
|
+
"port":"21",
|
407
|
+
"user":"picat",
|
408
|
+
"password":"toor"
|
409
|
+
},
|
410
|
+
{
|
411
|
+
"time":"2017-04-03 20:21:30 -0400",
|
412
|
+
"type":"FAILURE",
|
413
|
+
"ip":"192.168.33.10",
|
414
|
+
"port":"21",
|
415
|
+
"user":"picat",
|
416
|
+
"password":"picat"
|
417
|
+
}
|
418
|
+
]
|
419
|
+
```
|
420
|
+
|
421
|
+
Yay, serialization! Fo' cereal.
|