~ubuntu-branches/debian/squeeze/ntp/squeeze-201010051545

« back to all changes in this revision

Viewing changes to debian/ntpdate.init.d

  • Committer: Bazaar Package Importer
  • Author(s): Kurt Roeckx
  • Date: 2009-01-05 21:10:03 UTC
  • mfrom: (1.2.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20090105211003-mh6zc3um4k1uhsj7
Tags: 1:4.2.4p4+dfsg-8
It did not properly check the return value of EVP_VerifyFinal
which results in an malformed DSA signature being treated as
a good signature rather than as an error.  (CVE-2009-0021)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/sh
2
 
 
3
 
PATH=/sbin:/bin
4
 
 
5
 
test -f /usr/sbin/ntpdate || exit 0
6
 
 
7
 
if test -f /etc/default/ntpdate ; then
8
 
. /etc/default/ntpdate
9
 
else
10
 
NTPSERVERS="pool.ntp.org"
11
 
fi
12
 
 
13
 
test -n "$NTPSERVERS" || exit 0
14
 
 
15
 
. /lib/lsb/init-functions
16
 
 
17
 
case "$1" in
18
 
start|force-reload)
19
 
  log_begin_msg "Synchronizing clock to $NTPSERVERS..."
20
 
  /usr/sbin/ntpdate -b -s $NTPOPTIONS $NTPSERVERS
21
 
  log_end_msg $?
22
 
  ;;
23
 
restart|reload)
24
 
  # Drop -b to slew clock rather than step it if called after system is up
25
 
  log_begin_msg "Synchronizing clock to $NTPSERVERS..."
26
 
  /usr/sbin/ntpdate -s $NTPOPTIONS $NTPSERVERS
27
 
  log_end_msg $?
28
 
  ;;
29
 
stop)
30
 
  ;;
31
 
*)
32
 
  log_success_msg "Usage: /etc/init.d/ntpdate {start|stop|restart|reload|force-reload}"
33
 
  exit 1
34
 
esac
35
 
 
36
 
exit 0