From 394eaf39d605f9b0e916d25d3d5cd223b0c5246e Mon Sep 17 00:00:00 2001 From: Ansgar Burchardt Date: Thu, 30 May 2013 14:33:30 +0200 Subject: [PATCH] Allow timestamps in binary packages starting from 1975 Reference: --- config/debian-security/dak.conf | 2 -- config/debian/dak.conf | 2 -- daklib/checks.py | 2 +- docs/README.config | 11 ++++++----- setup/dak-minimal.conf.template | 2 -- 5 files changed, 7 insertions(+), 12 deletions(-) diff --git a/config/debian-security/dak.conf b/config/debian-security/dak.conf index 1da7d355..f6459d5c 100644 --- a/config/debian-security/dak.conf +++ b/config/debian-security/dak.conf @@ -12,8 +12,6 @@ Dinstall PackagesServer "packages.debian.org"; Bcc "archive@ftp-master.debian.org"; // GroupOverrideFilename "override.group-maint"; - FutureTimeTravelGrace 28800; // 8 hours - PastCutoffYear "1984"; SkipTime 300; CloseBugs "false"; OverrideDisparityCheck "false"; diff --git a/config/debian/dak.conf b/config/debian/dak.conf index a14cd80b..9258ec6e 100644 --- a/config/debian/dak.conf +++ b/config/debian/dak.conf @@ -12,8 +12,6 @@ Dinstall PackagesServer "packages.debian.org"; TrackingServer "packages.qa.debian.org"; Bcc "archive@ftp-master.debian.org"; - FutureTimeTravelGrace 28800; // 8 hours - PastCutoffYear "1984"; SkipTime 300; BXANotify "true"; CloseBugs "true"; diff --git a/daklib/checks.py b/daklib/checks.py index 5202f1bf..3e7a73d4 100644 --- a/daklib/checks.py +++ b/daklib/checks.py @@ -328,7 +328,7 @@ class BinaryTimestampCheck(Check): def check(self, upload): cnf = Config() future_cutoff = time.time() + cnf.find_i('Dinstall::FutureTimeTravelGrace', 24*3600) - past_cutoff = time.mktime(time.strptime(cnf.find('Dinstall::PastCutoffYear', '1984'), '%Y')) + past_cutoff = time.mktime(time.strptime(cnf.find('Dinstall::PastCutoffYear', '1975'), '%Y')) class TarTime(object): def __init__(self): diff --git a/docs/README.config b/docs/README.config index 7fabb4ee..0e9dbd33 100644 --- a/docs/README.config +++ b/docs/README.config @@ -108,14 +108,15 @@ Dinstall //// option is set. // BXANotify "true"; - //// FutureTimeTravelGrace (required): specifies how many seconds into the + //// FutureTimeTravelGrace (optional): specifies how many seconds into the //// future timestamps are allowed to be inside a deb before being rejected. - //// 28800 = 8 hours - FutureTimeTravelGrace 28800; + //// Defaults to 86400 (24 hours) if not specified. + FutureTimeTravelGrace 86400; - //// PastCutoffYear (required): specifies the cut-off year which is used when + //// PastCutoffYear (optional): specifies the cut-off year which is used when //// deciding whether or not to reject packages based on the file timestamp. - PastCutoffYear "1984"; + //// Defaults to "1975" if not specified. + PastCutoffYear "1975"; //// SkipTime (required): an integer value which is the number of seconds //// that a file must be older than (via it's last modified timestamp) diff --git a/setup/dak-minimal.conf.template b/setup/dak-minimal.conf.template index 834c37ac..3b6b27ad 100644 --- a/setup/dak-minimal.conf.template +++ b/setup/dak-minimal.conf.template @@ -28,8 +28,6 @@ Dinstall MyAdminAddress "dak@__DAKFQDN__"; MyDistribution "TestDakInstance"; - FutureTimeTravelGrace 28800; // 8 hours - PastCutoffYear "1984"; SkipTime 10; DefaultSuite "unstable"; -- 2.39.2