diff --git a/Gemfile b/Gemfile index 203c2ba65..bc9ba0183 100644 --- a/Gemfile +++ b/Gemfile @@ -30,8 +30,6 @@ gem 'braille', :git => "http://github.com/nicanor/braille.git" gem 'bases' gem 'huffman' gem 'ruby-graphviz' -gem 'smbhash' -gem 'scrypt' gem 'rsa' gem 'gpgmeh' gem 'digest-sha3', :git => "http://github.com/izetex/digest-sha3-ruby" diff --git a/lib/objects/system.rb b/lib/objects/system.rb index 217375a1b..30dbd4b2f 100644 --- a/lib/objects/system.rb +++ b/lib/objects/system.rb @@ -319,13 +319,11 @@ class System end # execute calculation script and format output to an array of Base64 strings Print.verbose "Running: ruby #{selected.local_calc_file} #{args_string[0..200]} ..." - stdout, stderr, status = Open3.capture3("ruby #{selected.local_calc_file}", :stdin_data => args_string) + command = "bundle exec ruby #{selected.local_calc_file}" + stdout, stderr, status = Open3.capture3(command, :stdin_data => args_string) puts stderr outputs = stdout.chomp - # command = "ruby #{selected.local_calc_file} #{args_string}" - # Print.verbose "Running: #{command}" - # outputs = `#{command}`.chomp unless status Print.err "Module failed to run (#{command})" # TODO: this works, but subsequent attempts at resolving the scenario always fail ("Error can't add no data...") diff --git a/modules/encoders/hash/sha3-224/secgen_local/local.rb b/modules/encoders/hash/sha3-224/secgen_local/local.rb index b0804efd4..30fc8dfba 100644 --- a/modules/encoders/hash/sha3-224/secgen_local/local.rb +++ b/modules/encoders/hash/sha3-224/secgen_local/local.rb @@ -1,5 +1,6 @@ #!/usr/bin/ruby require_relative '../../../../../lib/objects/local_hash_encoder.rb' +require 'digest/sha3' class SHA3_224_Encoder < HashEncoder def initialize diff --git a/modules/encoders/hash/sha3-256/secgen_local/local.rb b/modules/encoders/hash/sha3-256/secgen_local/local.rb index 13cc8d460..b4d5f1a2c 100644 --- a/modules/encoders/hash/sha3-256/secgen_local/local.rb +++ b/modules/encoders/hash/sha3-256/secgen_local/local.rb @@ -1,5 +1,6 @@ #!/usr/bin/ruby require_relative '../../../../../lib/objects/local_hash_encoder.rb' +require 'digest/sha3' class SHA3_256_Encoder < HashEncoder def initialize diff --git a/modules/encoders/hash/sha3-384/secgen_local/local.rb b/modules/encoders/hash/sha3-384/secgen_local/local.rb index 888092fdf..bb86c3ce7 100644 --- a/modules/encoders/hash/sha3-384/secgen_local/local.rb +++ b/modules/encoders/hash/sha3-384/secgen_local/local.rb @@ -1,5 +1,6 @@ #!/usr/bin/ruby require_relative '../../../../../lib/objects/local_hash_encoder.rb' +require 'digest/sha3' class SHA3_384_Encoder < HashEncoder def initialize diff --git a/modules/encoders/hash/sha3-512/secgen_local/local.rb b/modules/encoders/hash/sha3-512/secgen_local/local.rb index 64ce3a5dc..d9be87d7f 100644 --- a/modules/encoders/hash/sha3-512/secgen_local/local.rb +++ b/modules/encoders/hash/sha3-512/secgen_local/local.rb @@ -1,5 +1,6 @@ #!/usr/bin/ruby require_relative '../../../../../lib/objects/local_hash_encoder.rb' +require 'digest/sha3' class SHA3_512_Encoder < HashEncoder def initialize diff --git a/modules/encoders/hash/sha3/secgen_local/local.rb b/modules/encoders/hash/sha3/secgen_local/local.rb index 8eebcf998..c3f353f80 100644 --- a/modules/encoders/hash/sha3/secgen_local/local.rb +++ b/modules/encoders/hash/sha3/secgen_local/local.rb @@ -1,7 +1,8 @@ #!/usr/bin/ruby require_relative '../../../../../lib/objects/local_hash_encoder.rb' +require 'digest/sha3' -class SHA1Encoder < HashEncoder +class SHA3Encoder < HashEncoder def initialize super self.module_name = 'SHA1 Encoder' @@ -12,4 +13,4 @@ class SHA1Encoder < HashEncoder end end -SHA1Encoder.new.run +SHA3Encoder.new.run