From c3615cbdcbf62ec275b047c6739c55a8a424c60b Mon Sep 17 00:00:00 2001 From: Unit 193 Date: Fri, 15 Apr 2016 00:03:56 -0400 Subject: Only use sha256 hashes, dropping sha1 and md5. --- mini-dinstall | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/mini-dinstall b/mini-dinstall index 6523d46..9827c8c 100755 --- a/mini-dinstall +++ b/mini-dinstall @@ -1125,7 +1125,9 @@ class ArchiveDirIndexer(threading.Thread): def _make_indexfile(self, dir, type, name, arch=None): cmdline = ['apt-ftparchive', type, dir, - '-o', 'APT::FTPArchive::AlwaysStat=true'] + '-o', 'APT::FTPArchive::AlwaysStat=true', + '-o', 'APT::FTPArchive::SHA1=false', + '-o', 'APT::FTPArchive::MD5=false'] if arch: cmdline += ['--arch', arch] if not nodb_mode: @@ -1423,7 +1425,7 @@ class SimpleSubdirArchiveDirIndexer(ArchiveDirIndexer): f.write('Architectures: ' + arch + '\n') if self._release_description: f.write('Description: ' + self._release_description + '\n') - for hash in [ 'md5', 'sha1', 'sha256' ]: + for hash in [ 'sha256' ]: self._do_hash(hash, indexfiles, f) f.close() if self._sign_releasefile(os.path.basename(tmpname), self._abspath(arch)): @@ -1524,7 +1526,7 @@ class FlatArchiveDirIndexer(ArchiveDirIndexer): f.write('Architectures: ' + string.join(self._arches, ' ') + '\n') if self._release_description: f.write('Description: ' + self._release_description + '\n') - for hash in [ 'md5', 'sha1', 'sha256' ]: + for hash in [ 'sha256' ]: self._do_hash(hash, indexfiles, f) f.close() if self._sign_releasefile(tmpname, self._abspath()): -- cgit v1.2.3