Skip to content

Commit b9a9b90

Browse files
committed
Update module to use added bcrypt gem
1 parent d4a8690 commit b9a9b90

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

modules/auxiliary/admin/http/cfme_manageiq_evm_pass_reset.rb

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
##
77

88
require 'msf/core'
9+
require 'bcrypt'
910
require 'digest'
1011
require 'openssl'
1112

@@ -49,16 +50,7 @@ def initialize
4950

5051
def password_for_newer_schema
5152
# Newer versions use ActiveModel's SecurePassword.
52-
begin
53-
require 'bcrypt'
54-
55-
BCrypt::Password.create(datastore['TARGETPASSWORD'])
56-
57-
rescue LoadError
58-
print_error('Can\'t load "bcrypt" gem')
59-
print_status('Using "smartvm" as the password of the target account for this request...')
60-
'$2a$10$OHgj8h5MtsbmIAC9RPsrK.PH9t6Y.qGZxjHxUToKUJtFLJ0eY42/u'
61-
end
53+
BCrypt::Password.create(datastore['TARGETPASSWORD'])
6254
end
6355

6456
def password_for_older_schema

0 commit comments

Comments
 (0)