Fix DisclosureDate regex, and avoid checking Rank naming style

This commit is contained in:
sinn3r 2012-02-21 01:04:05 -06:00
parent ceb4888772
commit 1d71aec916
1 changed files with 2 additions and 2 deletions

View File

@ -71,7 +71,7 @@ def check_single_file(dparts, fparts, f_rel)
end
# Check disclosure date format
if content =~ /'DisclosureDate' => '(.+)'/
if content =~ /'DisclosureDate' => ['|\"](.+)['|\"]/
d = $1 #Captured date
# Flag if overall format is wrong
if d =~ /^... \d{1,2} \d{4}/
@ -115,7 +115,7 @@ def check_single_file(dparts, fparts, f_rel)
vars = content.scan(/([\x20|\w]+) \= [\'|\"]*\w[\'|\"]*/).flatten
vars.each do |v|
next if v =~ /^var/
next if v =~ /^var/ or v =~ /^Rank/
if v =~ /[a-z][A-Z]/ or v =~ /[A-Z][a-z]/
show_missing(f, "WARNING: Poor variable naming style for: '#{v}'", false)
end