shocens.rb
# Censys
# TODO make less naiive
# 120 request/minute (no slow needed for one page @101 results per query)
# if more than one page. naiively sleep for five minutes to fill up bucket again
Censys
TODO make less naiive
120 request/minute (no slow needed for one page @101 results per query)
if more than one page. naiively sleep for five minutes to fill up bucket again
Censys TODO make less naiive 120 request / minute ( no slow needed for one page @101 results per query ) if more than one page . naiively sleep for five minutes to fill up bucket again
def check_token_bucket
    if $token_bucket >= 115
      puts "[!] Sleeping for five to prevent lock out...\n"
      sleep 60*5
      $token_bucket = 0
    end
end
def check_token_bucket if $token_bucket >= 115 puts "[!] Sleeping for five to prevent lock out...\n" sleep 60 * 5 $token_bucket = 0 end end
Censys
TODO make less naiive
120 request/minute (no slow needed for one page @101 results per query)
if more than one page.
Censys TODO make less naiive 120 request / minute ( no slow needed for one page @101 results per query ) if more than one page .