[tor-bugs] #29071 [Core Tor/Tor]: shellcheck: nagios-check-tor-authority-cert issues

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri Jan 11 15:51:29 UTC 2019


#29071: shellcheck: nagios-check-tor-authority-cert issues
------------------------------+----------------------------
     Reporter:  rl1987        |      Owner:  (none)
         Type:  defect        |     Status:  new
     Priority:  Medium        |  Milestone:
    Component:  Core Tor/Tor  |    Version:
     Severity:  Normal        |   Keywords:  technical-debt
Actual Points:                |  Parent ID:
       Points:                |   Reviewer:
      Sponsor:                |
------------------------------+----------------------------
 {{{

 In nagios-check-tor-authority-cert line 52:
 TMPFILE="`tempfile`"
          ^-- SC2006: Use $(..) instead of legacy `..`.
           ^-- SC2186: tempfile is deprecated. Use mktemp instead.


 In nagios-check-tor-authority-cert line 57:
         if [ "$?" = 0 ]; then
              ^-- SC2181: Check exit code directly with e.g. 'if mycmd;',
 not indirectly with $?.


 In nagios-check-tor-authority-cert line 77:
 elif [ "$(( $now + 7*24*60*60 ))" -ge "$expiryunix" ]; then
             ^-- SC2004: $/${} is unnecessary on arithmetic variables.


 In nagios-check-tor-authority-cert line 80:
 elif [ "$(( $now + 30*24*60*60 ))" -ge "$expiryunix" ]; then
             ^-- SC2004: $/${} is unnecessary on arithmetic variables.
 }}}

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/29071>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list