pwn 0.4.699 → 0.4.701

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,74 +0,0 @@
1
- #!/usr/bin/env ruby
2
- # frozen_string_literal: true
3
-
4
- require 'nokogiri/diff'
5
- require 'optparse'
6
-
7
- opts = {}
8
- OptionParser.new do |options|
9
- options.on('-aXML', '--xml-a=XML', '<Required - First XML to Compare)>') do |x1|
10
- opts[:x1_path] = x1
11
- end
12
-
13
- options.on('-bXML', '--xml-b=XML', '<Required - Second XML to Compare)>') do |x2|
14
- opts[:x2_path] = x2
15
- end
16
-
17
- options.on('-dDIFF', '--xml-diff=DIFF', '<Required - Path of XML Diff to Generate)>') do |d|
18
- opts[:diff_path] = d
19
- end
20
- end.parse!
21
-
22
- if opts.empty?
23
- puts `#{$PROGRAM_NAME} --help`
24
- exit 1
25
- end
26
-
27
- # Compare the diff of two XML files using the nokogiri gem in Ruby
28
- # and output the diff to a new XML file using the same format as the
29
- # the original XML files.
30
- begin
31
- x1_path = opts[:x1_path]
32
- x2_path = opts[:x2_path]
33
- diff_path = opts[:diff_path]
34
-
35
- x1 = Nokogiri::XML(File.read(x1_path))
36
- x2 = Nokogiri::XML(File.read(x2_path))
37
-
38
- diff_xml = Nokogiri::XML::Builder.new do |xml|
39
- xml.diff do
40
- x1.root.traverse do |node|
41
- next unless node.element?
42
-
43
- node_name = node.name
44
- node_x2 = x2.at_xpath(node.path)
45
-
46
- if node_x2.nil?
47
- xml.delete do
48
- xml.send(node_name, node.attributes)
49
- end
50
- elsif node_x2 != node
51
- xml.change do
52
- xml.send(node_name, node.attributes)
53
- end
54
- end
55
- end
56
-
57
- x2.root.traverse do |node|
58
- next unless node.element?
59
-
60
- node_name = node.name
61
- node_x1 = x1.at_xpath(node.path)
62
-
63
- xml.add do
64
- xml.send(node_name, node.attributes) if node_x1.nil?
65
- end
66
- end
67
- end
68
- end
69
-
70
- File.write(diff_path, diff_xml.to_xml)
71
- rescue StandardError => e
72
- puts "Error: #{e.message}"
73
- exit 1
74
- end
@@ -1,8 +0,0 @@
1
- #!/bin/bash
2
- source /etc/profile.d/globals.sh
3
-
4
- $screen_cmd "${apt} install -y nmap ncat ${assess_update_errors}"
5
- grok_error
6
-
7
- $screen_cmd "cd /opt && git clone https://github.com/ninp0/nmap_all_live_hosts.git && ln -sf /opt/nmap_all_live_hosts/nmap_all_live_hosts.sh /usr/local/bin/ ${assess_update_errors}"
8
- grok_error