[tor-bugs] #29068 [Core Tor/Tor]: shellcheck: zero_length_keys.sh issues

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


#29068: shellcheck: zero_length_keys.sh 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 zero_length_keys.sh line 22:
 if [ $# -eq 0 ] || [ ! -f ${1} ] || [ ! -x ${1} ]; then
                           ^-- SC2086: Double quote to prevent globbing and
 word splitting.
                                            ^-- SC2086: Double quote to
 prevent globbing and word splitting.


 In zero_length_keys.sh line 34:
 DATA_DIR=`mktemp -d -t tor_zero_length_keys.XXXXXX`
          ^-- SC2006: Use $(..) instead of legacy `..`.


 In zero_length_keys.sh line 43:
 trap "rm -rf '$DATA_DIR'" 0
               ^-- SC2064: Use single quotes, otherwise this expands now
 rather than when signalled.
 }}}

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


More information about the tor-bugs mailing list