rex-random_identifier 0.1.18 → 0.1.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 615a0a02f3a8f12d617828ee1875a52c6aee60d81ce8a22268ee0dd405846eec
4
- data.tar.gz: 55279a15cd3270f734fa402795581021a272492fd46e24234a9932448d139154
3
+ metadata.gz: 1535a86c7b5bcab6e709ba8337f165f2a5f0179ba2a82ab4f96b029a0630cb98
4
+ data.tar.gz: 191058bcd6288fe7ba429bcaa36f12861695f5b5cf7af92ce199f90ce4708c13
5
5
  SHA512:
6
- metadata.gz: a2984829ed7d831d0322bf3680d1b96f0428604f66b25c4170e99d9ae87000c898bfa022c2f7478afa7364351c664c1019748a9293625b46bae7300fa3a99609
7
- data.tar.gz: fc10df6eaa64992e75dab3c55cb8353545d7c57c56a316b37b0abdd9216c95e8c47729ad6900a7b39953c27358242f4dbb73e8c10e0f9615de21d176937da53f
6
+ metadata.gz: '08182b8117736c3c2b1113926c353c7b16f1f46935a7f5886a7c7f56aa0c341f174f54d4eefa54e3decbf4697b13a4ee442477864613fa7524ff33abdc5e68b9'
7
+ data.tar.gz: 58c553250b747f9474ae18f4535425c4ffdff3be321b328150305a03468040f0c875711681c968c8716903363e1630010750fc186cd431c81c3c177bbebc613f
data/README.md CHANGED
@@ -23,16 +23,15 @@ Or install it yourself as:
23
23
 
24
24
  Example
25
25
  ```ruby
26
- vars = Rex::RandomIdentifierGenerator.new
27
- asp_code = <<-END_CODE
28
- Sub #{vars[:func]}()
29
- Dim #{vars[:fso]}
30
- Set #{vars[:fso]} = CreateObject("Scripting.FileSystemObject")
31
- ...
32
- End Sub
33
- #{vars[:func]}
34
- END_CODE
35
- #
26
+ vars = Rex::RandomIdentifierGenerator.new
27
+ asp_code = <<-END_CODE
28
+ Sub #{vars[:func]}()
29
+ Dim #{vars[:fso]}
30
+ Set #{vars[:fso]} = CreateObject("Scripting.FileSystemObject")
31
+ ...
32
+ End Sub
33
+ #{vars[:func]}
34
+ END_CODE
36
35
  ```
37
36
 
38
37
  ## Development
@@ -44,4 +43,3 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
44
43
  ## Contributing
45
44
 
46
45
  Bug reports and pull requests are welcome on GitHub at https://github.com/rapid7/rex-random_identifier. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
47
-
@@ -427,7 +427,8 @@ class Rex::RandomIdentifier::Generator
427
427
  #
428
428
  # @return [Boolean] Is identifier forbidden?
429
429
  def forbid_id?(ident = nil)
430
- ident.nil? or @opts[:forbidden].any? {|f| f.match(/^#{ident}$/i) }
430
+ return true if ident.nil?
431
+ @opts[:forbidden].any? { |f| f.casecmp?(ident) }
431
432
  end
432
433
 
433
434
  end
@@ -1,5 +1,5 @@
1
1
  module Rex
2
2
  module RandomIdentifier
3
- VERSION = "0.1.18"
3
+ VERSION = "0.1.20"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rex-random_identifier
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.18
4
+ version: 0.1.20
5
5
  platform: ruby
6
6
  authors:
7
7
  - Metasploit Hackers