Skip to content

Commit

Permalink
Refined gadget scoring for argv and envp
Browse files Browse the repository at this point in the history
  • Loading branch information
lebr0nli committed Jul 10, 2023
1 parent cdbe2f0 commit a3ceca3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/one_gadget/gadget.rb
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@ def calculate_score(expr)
when /^writable/ then calculate_writable_score(expr.sub('writable: ', ''))
when / == NULL$/ then calculate_null_score(expr.sub(' == NULL', ''))
when / <= 0$/ then calculate_null_score(expr.sub(' <= 0', ''))
when / is a valid argv$/ then 0.5 # TODO: Calculate the score more precisely
when / is a valid envp$/ then 0.5 # TODO: Calculate the score more precisely
when / is a valid (argv|envp)$/ then 0.2 # TODO: Calculate the score more precisely
end
end

Expand Down

0 comments on commit a3ceca3

Please sign in to comment.