Module: Scanny::Checks::Helpers
- Included in:
- SystemTools::GpgUsageCheck, SystemTools::SudoCheck, SystemTools::TarCheck, SystemTools::TarCommandsCheck, SystemTools::UnzipCheck
- Defined in:
- lib/scanny/checks/helpers.rb
Instance Method Summary collapse
-
#build_pattern_exec_command(command) ⇒ Object
system(“command”) ‘command`.
Instance Method Details
#build_pattern_exec_command(command) ⇒ Object
system(“command”) ‘command`
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/scanny/checks/helpers.rb', line 6 def build_pattern_exec_command(command) command = command.to_s if command.is_a?(Symbol) result = command.inspect " SendWithArguments\n <\n name = :system | :exec | :spawn,\n arguments = ActualArguments<\n array = [\n any*,\n StringLiteral<string *= \#{result}>,\n any*\n ]\n >\n >\n |\n ExecuteString<string *= \#{result}>\n EOT\nend\n" |