metasploit-credential 5.0.4 → 5.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e8c662ab01206eb5505e4547ea2d0d092ef9a5dcd53b3e3d7a3f0e24080bc080
4
- data.tar.gz: 412d0c389cd2157da7e1594b4ed4f71cd97cd212673b52027a07fbb5dabbe266
3
+ metadata.gz: d140b2eb720061d68c2e0fec85404497f81a6051a9f8d976f878f36c23aed270
4
+ data.tar.gz: 620eb8b84e8668482a0b33c2b65a5d1db8a9898f62afb8c839f8d8bf40e07428
5
5
  SHA512:
6
- metadata.gz: cf857bc495a3084d6d092bcd47bcefc77774e40a681d299ab6e9f63249f1095dfb8c8c5938663bbf060720ad0fac7716bd30536581b821801e8278c3c618c7ba
7
- data.tar.gz: b1296d879cfec2c95064f0fc38f46ab513cc7de077bfaeebd1c63a4b16383ec6b26a04a384eb95f180a4b419523e19a6864345c78cbd605f2901942fd68be97c
6
+ metadata.gz: 480728a45afedefb42fe8c564ccef3389c4e479bc7234179450e90f0d3c25ccf58a6b9cfced84d0896ee88c9d0b3f5b3c195473fb156de5998ace3eff665ffc8
7
+ data.tar.gz: 1519aa87cb68fe5711bc812cad71ef329f73f20b6b2dfc09d53167011a59744a518a637ea5aac5929a6d8a3c57ab57d74f42746dcad654e2d5cc29bc3aeb482b
checksums.yaml.gz.sig CHANGED
Binary file
@@ -10,17 +10,118 @@ class Metasploit::Credential::NonreplayableHash < Metasploit::Credential::Passwo
10
10
  # The names of John the Ripper supported formats, from the "jumbo" edition.
11
11
  # Listed in the format section of the output of +john --help+ on the CLI
12
12
  # Current as of 2014-06-12
13
- VALID_JTR_FORMATS = %w(afs bf bf-opencl bfegg bsdi crc32 des django dmd5 dominosec dragonfly3-32 dragonfly3-64
14
- dragonfly4-32 dragonfly4-64 drupal7 dummy dynamic_n epi episerver gost hdaa hmac-md5 hmac-sha1
15
- hmac-sha224 hmac-sha256 hmac-sha384 hmac-sha512 hmailserver ipb2 keepass keychain krb4 krb5 lm
16
- lotus5 md4-gen md5 md5crypt-opencl md5ns mediawiki mscash mscash2 mscash2-opencl mschapv2
17
- mskrb5 mssql mssql05 mysql mysql-sha1 mysql-sha1-opencl nethalflm netlm netlmv2 netntlm
18
- netntlmv2 nsldap nt nt-opencl nt2 odf office oracle oracle11 osc pdf phpass phpass-opencl phps
19
- pix-md5 pkzip po pwsafe pwsafe-opencl racf rar raw-md4 raw-md4-opencl raw-md5 raw-md5-opencl
20
- raw-md5u raw-sha raw-sha1 raw-sha1-linkedin raw-sha1-ng raw-sha1-opencl raw-sha224 raw-sha256
21
- raw-sha384 raw-sha512 raw-sha512-opencl salted-sha1 sapb sapg sha1-gen sha256crypt sha512crypt
22
- sha512crypt-opencl sip ssh ssha-opencl sybasease trip vnc wbb3 wpapsk wpapsk-opencl xsha
23
- xsha512 xsha512-opencl zip)
13
+ VALID_JTR_FORMATS = %w(
14
+ afs
15
+ bf
16
+ bf-opencl
17
+ bfegg
18
+ bsdi
19
+ crc32
20
+ des
21
+ django
22
+ dmd5
23
+ dominosec
24
+ dragonfly3-32
25
+ dragonfly3-64
26
+ dragonfly4-32
27
+ dragonfly4-64
28
+ drupal7
29
+ dummy
30
+ dynamic_n
31
+ epi
32
+ episerver
33
+ gost
34
+ hdaa
35
+ hmac-md5
36
+ hmac-sha1
37
+ hmac-sha224
38
+ hmac-sha256
39
+ hmac-sha384
40
+ hmac-sha512
41
+ hmailserver
42
+ ipb2
43
+ keepass
44
+ keychain
45
+ krb4
46
+ krb5
47
+ lm
48
+ lotus5
49
+ md4-gen
50
+ md5
51
+ md5crypt-opencl
52
+ md5ns
53
+ mediawiki
54
+ mscash
55
+ mscash2
56
+ mscash2-opencl
57
+ mschapv2
58
+ mskrb5
59
+ mssql
60
+ mssql05
61
+ mysql
62
+ mysql-sha1
63
+ mysql-sha1-opencl
64
+ nethalflm
65
+ netlm
66
+ netlmv2
67
+ netntlm
68
+ netntlmv2
69
+ nsldap
70
+ nt
71
+ nt-opencl
72
+ nt2
73
+ odf
74
+ office
75
+ oracle
76
+ oracle11
77
+ osc
78
+ pdf
79
+ phpass
80
+ phpass-opencl
81
+ phps
82
+ pix-md5
83
+ pkzip
84
+ po
85
+ pwsafe
86
+ pwsafe-opencl
87
+ racf
88
+ rar
89
+ raw-md4
90
+ raw-md4-opencl
91
+ raw-md5
92
+ raw-md5-opencl
93
+ raw-md5u
94
+ raw-sha
95
+ raw-sha1
96
+ raw-sha1-linkedin
97
+ raw-sha1-ng
98
+ raw-sha1-opencl
99
+ raw-sha224
100
+ raw-sha256
101
+ raw-sha384
102
+ raw-sha512
103
+ raw-sha512-opencl
104
+ salted-sha1
105
+ sapb
106
+ sapg
107
+ sha1-gen
108
+ sha256crypt
109
+ sha512crypt
110
+ sha512crypt-opencl
111
+ sip
112
+ ssh
113
+ ssha-opencl
114
+ sybasease
115
+ trip
116
+ vnc
117
+ wbb3
118
+ wpapsk
119
+ wpapsk-opencl
120
+ xsha
121
+ xsha512
122
+ xsha512-opencl
123
+ zip
124
+ )
24
125
 
25
126
  #
26
127
  # Attributes
@@ -224,7 +224,7 @@ class Metasploit::Credential::Importer::Core
224
224
  end
225
225
  if all_creds_valid
226
226
  core_opts.each do |item|
227
- if Metasploit::Credential::Core.where(public: item[:public], private: item[:private]).blank?
227
+ if Metasploit::Credential::Core.where(origin: item[:origin], workspace_id: item[:workspace_id], public: item[:public], private: item[:private]).blank?
228
228
  create_credential_core(item)
229
229
  end
230
230
  end
@@ -3,7 +3,7 @@
3
3
  module Metasploit
4
4
  module Credential
5
5
  # VERSION is managed by GemRelease
6
- VERSION = '5.0.4'
6
+ VERSION = '5.0.7'
7
7
 
8
8
  # @return [String]
9
9
  #
@@ -1,6 +1,6 @@
1
1
  development: &pgsql
2
2
  adapter: postgresql
3
- database: metasploit-credential_development0
3
+ database: metasploit-credential_development4
4
4
  username: msf
5
5
  password: pass123
6
6
  host: localhost
@@ -10,4 +10,4 @@ development: &pgsql
10
10
  min_messages: warning
11
11
  test:
12
12
  <<: *pgsql
13
- database: metasploit-credential_test0
13
+ database: metasploit-credential_test4
@@ -215,6 +215,31 @@ RSpec.describe Metasploit::Credential::Importer::Core do
215
215
  expect{core_csv_importer.import!}.to change(Metasploit::Credential::Core, :count).from(1).to(2)
216
216
  end
217
217
  end
218
+
219
+ describe "when the data in the CSV contains a duplicate from another workspace" do
220
+ let(:preexisting_cred_data) do
221
+ core_csv_importer.csv_object.gets
222
+ row = core_csv_importer.csv_object.first
223
+ core_csv_importer.csv_object.rewind
224
+ {
225
+ username: row['username'],
226
+ private_data: row['private_data'],
227
+ }
228
+ end
229
+
230
+ before(:example) do
231
+ core = Metasploit::Credential::Core.new
232
+ core.public = FactoryBot.create(:metasploit_credential_username, username: preexisting_cred_data[:username])
233
+ core.private = FactoryBot.create(:metasploit_credential_password, data: preexisting_cred_data[:private_data])
234
+ core.origin = FactoryBot.create(:metasploit_credential_origin_import)
235
+ core.workspace = FactoryBot.create(:mdm_workspace)
236
+ core.save!
237
+ end
238
+
239
+ it 'should create a new Metasploit::Credential::Core for each row in the import' do
240
+ expect{core_csv_importer.import!}.to change(Metasploit::Credential::Core, :count).from(1).to(3)
241
+ end
242
+ end
218
243
  end
219
244
  end
220
245
 
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metasploit-credential
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.4
4
+ version: 5.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Metasploit Hackers
@@ -93,7 +93,7 @@ cert_chain:
93
93
  EknWpNgVhohbot1lfVAMmIhdtOVaRVcQQixWPwprDj/ydB8ryDMDosIMcw+fkoXU
94
94
  9GJsSaSRRYQ9UUkVL27b64okU8D48m8=
95
95
  -----END CERTIFICATE-----
96
- date: 2021-09-03 00:00:00.000000000 Z
96
+ date: 2022-04-11 00:00:00.000000000 Z
97
97
  dependencies:
98
98
  - !ruby/object:Gem::Dependency
99
99
  name: metasploit-concern
metadata.gz.sig CHANGED
Binary file