From a7c835af20feeb470238ead3bda36af978c2600f Mon Sep 17 00:00:00 2001 From: Arch Librarian Date: Mon, 20 Sep 2004 16:57:20 +0000 Subject: [PATCH] Alfredo's vendor stuff Author: jgg Date: 2001-03-13 06:51:46 GMT Alfredo's vendor stuff --- apt-pkg/acquire-method.cc | 20 ++++++- apt-pkg/acquire-method.h | 8 ++- apt-pkg/cachefile.cc | 4 +- apt-pkg/deb/debindexfile.cc | 10 ++-- apt-pkg/deb/debrecords.cc | 12 ++++- apt-pkg/deb/debrecords.h | 3 +- apt-pkg/init.cc | 6 ++- apt-pkg/pkgrecords.h | 3 +- apt-pkg/sourcelist.cc | 93 ++++++++++++++++++++++++++++---- apt-pkg/sourcelist.h | 42 +++++++++++---- apt-pkg/tagfile.cc | 3 +- debian/changelog | 3 +- doc/apt.ent | 4 +- doc/makefile | 2 +- doc/vendors.list.5.sgml | 104 ++++++++++++++++++++++++++++++++++++ methods/ftp.cc | 4 +- methods/gzip.cc | 4 +- methods/http.cc | 4 +- methods/rsh.cc | 4 +- 19 files changed, 284 insertions(+), 49 deletions(-) create mode 100644 doc/vendors.list.5.sgml diff --git a/apt-pkg/acquire-method.cc b/apt-pkg/acquire-method.cc index 3b905f4e9..0ecd8df93 100644 --- a/apt-pkg/acquire-method.cc +++ b/apt-pkg/acquire-method.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: acquire-method.cc,v 1.25 2001/02/20 07:03:17 jgg Exp $ +// $Id: acquire-method.cc,v 1.26 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Acquire Method @@ -23,7 +23,8 @@ #include #include #include - +#include + #include #include #include @@ -175,6 +176,8 @@ void pkgAcqMethod::URIDone(FetchResult &Res, FetchResult *Alt) if (Res.MD5Sum.empty() == false) End += snprintf(End,sizeof(S)-50 - (End - S),"MD5-Hash: %s\n",Res.MD5Sum.c_str()); + if (Res.SHA1Sum.empty() == false) + End += snprintf(End,sizeof(S)-50 - (End - S),"SHA1-Hash: %s\n",Res.SHA1Sum.c_str()); if (Res.ResumePoint != 0) End += snprintf(End,sizeof(S)-50 - (End - S),"Resume-Point: %lu\n", @@ -199,6 +202,9 @@ void pkgAcqMethod::URIDone(FetchResult &Res, FetchResult *Alt) if (Alt->MD5Sum.empty() == false) End += snprintf(End,sizeof(S)-50 - (End - S),"Alt-MD5-Hash: %s\n", Alt->MD5Sum.c_str()); + if (Alt->SHA1Sum.empty() == false) + End += snprintf(End,sizeof(S)-50 - (End - S),"Alt-SHA1-Hash: %s\n", + Alt->SHA1Sum.c_str()); if (Alt->IMSHit == true) strcat(End,"Alt-IMS-Hit: true\n"); @@ -434,3 +440,13 @@ pkgAcqMethod::FetchResult::FetchResult() : LastModified(0), { } /*}}}*/ +// AcqMethod::FetchResult::TakeHashes - Load hashes /*{{{*/ +// --------------------------------------------------------------------- +/* This hides the number of hashes we are supporting from the caller. + It just deals with the hash class. */ +void pkgAcqMethod::FetchResult::TakeHashes(Hashes &Hash) +{ + MD5Sum = Hash.MD5.Result(); + SHA1Sum = Hash.SHA1.Result(); +} + /*}}}*/ diff --git a/apt-pkg/acquire-method.h b/apt-pkg/acquire-method.h index b32d80c43..4721a3b65 100644 --- a/apt-pkg/acquire-method.h +++ b/apt-pkg/acquire-method.h @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: acquire-method.h,v 1.14 2001/02/20 07:03:17 jgg Exp $ +// $Id: acquire-method.h,v 1.15 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Acquire Method - Method helper class + functions @@ -20,6 +20,7 @@ #pragma interface "apt-pkg/acquire-method.h" #endif +class Hashes; class pkgAcqMethod { protected: @@ -37,11 +38,14 @@ class pkgAcqMethod struct FetchResult { string MD5Sum; + string SHA1Sum; time_t LastModified; bool IMSHit; string Filename; unsigned long Size; - unsigned long ResumePoint; + unsigned long ResumePoint; + + void TakeHashes(Hashes &Hash); FetchResult(); }; diff --git a/apt-pkg/cachefile.cc b/apt-pkg/cachefile.cc index 74d136afb..4bc93fd7c 100644 --- a/apt-pkg/cachefile.cc +++ b/apt-pkg/cachefile.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: cachefile.cc,v 1.5 2001/02/20 07:03:17 jgg Exp $ +// $Id: cachefile.cc,v 1.6 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### CacheFile - Simple wrapper class for opening, generating and whatnot @@ -71,7 +71,7 @@ bool pkgCacheFile::Open(OpProgress &Progress,bool WithLock) /* This sux, remove it someday */ if (_error->empty() == false) - _error->Warning(_("You may want to run apt-get update to correct these missing files")); + _error->Warning(_("You may want to run apt-get update to correct these problems")); Cache = new pkgCache(Map); if (_error->PendingError() == true) diff --git a/apt-pkg/deb/debindexfile.cc b/apt-pkg/deb/debindexfile.cc index dcc916c1a..2cc1de8a1 100644 --- a/apt-pkg/deb/debindexfile.cc +++ b/apt-pkg/deb/debindexfile.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: debindexfile.cc,v 1.3 2001/02/23 06:41:55 jgg Exp $ +// $Id: debindexfile.cc,v 1.4 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Debian Specific sources.list types and the three sorts of Debian @@ -417,7 +417,8 @@ class debSLTypeDeb : public pkgSourceList::Type public: bool CreateItem(vector &List,string URI, - string Dist,string Section) const + string Dist,string Section, + pkgSourceList::Vendor const *Vendor) const { List.push_back(new debPackagesIndex(URI,Dist,Section)); return true; @@ -435,8 +436,9 @@ class debSLTypeDebSrc : public pkgSourceList::Type public: bool CreateItem(vector &List,string URI, - string Dist,string Section) const - { + string Dist,string Section, + pkgSourceList::Vendor const *Vendor) const + { List.push_back(new debSourcesIndex(URI,Dist,Section)); return true; }; diff --git a/apt-pkg/deb/debrecords.cc b/apt-pkg/deb/debrecords.cc index 0196992c6..6652a6ad9 100644 --- a/apt-pkg/deb/debrecords.cc +++ b/apt-pkg/deb/debrecords.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: debrecords.cc,v 1.9 2001/02/20 07:03:17 jgg Exp $ +// $Id: debrecords.cc,v 1.10 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Debian Package Records - Parser for debian package records @@ -53,7 +53,15 @@ string debRecordParser::Name() /* */ string debRecordParser::MD5Hash() { - return Section.FindS("MD5sum"); + return Section.FindS("MD5Sum"); +} + /*}}}*/ +// RecordParser::SHA1Hash - Return the archive hash /*{{{*/ +// --------------------------------------------------------------------- +/* */ +string debRecordParser::SHA1Hash() +{ + return Section.FindS("SHA1Sum"); } /*}}}*/ // RecordParser::Maintainer - Return the maintainer email /*{{{*/ diff --git a/apt-pkg/deb/debrecords.h b/apt-pkg/deb/debrecords.h index fd1c380dc..efef2e588 100644 --- a/apt-pkg/deb/debrecords.h +++ b/apt-pkg/deb/debrecords.h @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: debrecords.h,v 1.7 2001/02/20 07:03:17 jgg Exp $ +// $Id: debrecords.h,v 1.8 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Debian Package Records - Parser for debian package records @@ -36,6 +36,7 @@ class debRecordParser : public pkgRecords::Parser // These refer to the archive file for the Version virtual string FileName(); virtual string MD5Hash(); + virtual string SHA1Hash(); virtual string SourcePkg(); // These are some general stats about the package diff --git a/apt-pkg/init.cc b/apt-pkg/init.cc index 01b9d8665..930c45a87 100644 --- a/apt-pkg/init.cc +++ b/apt-pkg/init.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: init.cc,v 1.15 2001/02/20 07:03:17 jgg Exp $ +// $Id: init.cc,v 1.16 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Init - Initialize the package library @@ -63,11 +63,13 @@ bool pkgInitConfig(Configuration &Cnf) // Configuration Cnf.Set("Dir::Etc","etc/apt/"); Cnf.Set("Dir::Etc::sourcelist","sources.list"); + Cnf.Set("Dir::Etc::vendorlist","vendors.list"); + Cnf.Set("Dir::Etc::vendorparts","vendors.list.d"); Cnf.Set("Dir::Etc::main","apt.conf"); Cnf.Set("Dir::Etc::parts","apt.conf.d"); Cnf.Set("Dir::Etc::preferences","preferences"); Cnf.Set("Dir::Bin::methods","/usr/lib/apt/methods"); - + bool Res = true; // Read an alternate config file diff --git a/apt-pkg/pkgrecords.h b/apt-pkg/pkgrecords.h index af5fac646..08f004414 100644 --- a/apt-pkg/pkgrecords.h +++ b/apt-pkg/pkgrecords.h @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: pkgrecords.h,v 1.5 2001/02/20 07:03:17 jgg Exp $ +// $Id: pkgrecords.h,v 1.6 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Package Records - Allows access to complete package description records @@ -56,6 +56,7 @@ class pkgRecords::Parser // These refer to the archive file for the Version virtual string FileName() {return string();}; virtual string MD5Hash() {return string();}; + virtual string SHA1Hash() {return string();}; virtual string SourcePkg() {return string();}; // These are some general stats about the package diff --git a/apt-pkg/sourcelist.cc b/apt-pkg/sourcelist.cc index da7e38f6e..51289a43d 100644 --- a/apt-pkg/sourcelist.cc +++ b/apt-pkg/sourcelist.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: sourcelist.cc,v 1.18 2001/02/20 07:03:17 jgg Exp $ +// $Id: sourcelist.cc,v 1.19 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### List of Sources @@ -61,7 +61,7 @@ bool pkgSourceList::Type::FixupURI(string &URI) const URI = SubstVar(URI,"$(ARCH)",_config->Find("APT::Architecture")); - // Make sure that the URN is / postfixed + // Make sure that the URI is / postfixed if (URI[URI.size() - 1] != '/') URI += '/'; @@ -73,6 +73,7 @@ bool pkgSourceList::Type::FixupURI(string &URI) const /* This is a generic one that is the 'usual' format for sources.list Weird types may override this. */ bool pkgSourceList::Type::ParseLine(vector &List, + Vendor const *Vendor, const char *Buffer, unsigned long CurLine, string File) const @@ -95,7 +96,7 @@ bool pkgSourceList::Type::ParseLine(vector &List, if (ParseQuoteWord(Buffer,Section) == true) return _error->Error(_("Malformed line %lu in source list %s (Absolute dist)"),CurLine,File.c_str()); Dist = SubstVar(Dist,"$(ARCH)",_config->Find("APT::Architecture")); - return CreateItem(List,URI,Dist,Section); + return CreateItem(List,URI,Dist,Section,Vendor); } // Grab the rest of the dists @@ -104,7 +105,7 @@ bool pkgSourceList::Type::ParseLine(vector &List, do { - if (CreateItem(List,URI,Dist,Section) == false) + if (CreateItem(List,URI,Dist,Section,Vendor) == false) return false; } while (ParseQuoteWord(Buffer,Section) == true); @@ -125,12 +126,58 @@ pkgSourceList::pkgSourceList(string File) Read(File); } /*}}}*/ +// SourceList::ReadVendors - Read list of known package vendors /*{{{*/ +// --------------------------------------------------------------------- +/* This also scans a directory of vendor files similar to apt.conf.d + which can contain the usual suspects of distribution provided data. + The APT config mechanism allows the user to override these in their + configuration file. */ +bool pkgSourceList::ReadVendors() +{ + Configuration Cnf; + + string CnfFile = _config->FindDir("Dir::Etc::vendorparts"); + if (FileExists(CnfFile) == true) + if (ReadConfigDir(Cnf,CnfFile,true) == false) + return false; + CnfFile = _config->FindFile("Dir::Etc::vendorlist"); + if (FileExists(CnfFile) == true) + if (ReadConfigFile(Cnf,CnfFile,true) == false) + return false; + + // Process 'simple-key' type sections + const Configuration::Item *Top = Cnf.Tree("simple-key"); + for (Top = (Top == 0?0:Top->Child); Top != 0; Top = Top->Next) + { + Configuration Block(Top); + Vendor *Vendor; + + Vendor = new pkgSourceList::Vendor; + + Vendor->VendorID = Top->Tag; + Vendor->FingerPrint = Block.Find("Fingerprint"); + Vendor->Description = Block.Find("Name"); + + if (Vendor->FingerPrint.empty() == true || + Vendor->Description.empty() == true) + { + _error->Error(_("Vendor block %s is invalid"), Vendor->VendorID.c_str()); + delete Vendor; + continue; + } + + VendorList.push_back(Vendor); + } + + return !_error->PendingError(); +} + /*}}}*/ // SourceList::ReadMainList - Read the main source list from etc /*{{{*/ // --------------------------------------------------------------------- /* */ bool pkgSourceList::ReadMainList() { - return Read(_config->FindFile("Dir::Etc::sourcelist")); + return ReadVendors() && Read(_config->FindFile("Dir::Etc::sourcelist")); } /*}}}*/ // SourceList::Read - Parse the sourcelist file /*{{{*/ @@ -143,7 +190,7 @@ bool pkgSourceList::Read(string File) if (!F != 0) return _error->Errno("ifstream::ifstream",_("Opening %s"),File.c_str()); - List.erase(List.begin(),List.end()); + SrcList.erase(SrcList.begin(),SrcList.end()); char Buffer[300]; int CurLine = 0; @@ -173,7 +220,35 @@ bool pkgSourceList::Read(string File) if (Parse == 0) return _error->Error(_("Type '%s' is not known in on line %u in source list %s"),LineType.c_str(),CurLine,File.c_str()); - if (Parse->ParseLine(List,C,CurLine,File) == false) + // Authenticated repository + Vendor const *Vndr = 0; + if (C[0] == '[') + { + string VendorID; + + if (ParseQuoteWord(C,VendorID) == false) + return _error->Error(_("Malformed line %u in source list %s (vendor id)"),CurLine,File.c_str()); + + if (VendorID.length() < 2 || VendorID.end()[-1] != ']') + return _error->Error(_("Malformed line %u in source list %s (vendor id)"),CurLine,File.c_str()); + VendorID = string(VendorID,1,VendorID.size()-2); + + for (vector::const_iterator iter = VendorList.begin(); + iter != VendorList.end(); iter++) + { + if ((*iter)->VendorID == VendorID) + { + Vndr = *iter; + break; + } + } + + if (Vndr == 0) + return _error->Error(_("Unknown vendor ID '%s' in line %u of source list %s"), + VendorID.c_str(),CurLine,File.c_str()); + } + + if (Parse->ParseLine(SrcList,Vndr,C,CurLine,File) == false) return false; } return true; @@ -185,7 +260,7 @@ bool pkgSourceList::Read(string File) bool pkgSourceList::FindIndex(pkgCache::PkgFileIterator File, pkgIndexFile *&Found) const { - for (const_iterator I = List.begin(); I != List.end(); I++) + for (const_iterator I = SrcList.begin(); I != SrcList.end(); I++) { if ((*I)->FindInCache(*File.Cache()) == File) { @@ -202,7 +277,7 @@ bool pkgSourceList::FindIndex(pkgCache::PkgFileIterator File, /* */ bool pkgSourceList::GetIndexes(pkgAcquire *Owner) const { - for (const_iterator I = List.begin(); I != List.end(); I++) + for (const_iterator I = SrcList.begin(); I != SrcList.end(); I++) if ((*I)->GetIndexes(Owner) == false) return false; return true; diff --git a/apt-pkg/sourcelist.h b/apt-pkg/sourcelist.h index 3a6b274f6..1dc505425 100644 --- a/apt-pkg/sourcelist.h +++ b/apt-pkg/sourcelist.h @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: sourcelist.h,v 1.9 2001/02/20 07:03:17 jgg Exp $ +// $Id: sourcelist.h,v 1.10 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### SourceList - Manage a list of sources @@ -14,10 +14,14 @@ files.sgml. The types are mapped through a list of type definitions which handle - the actual construction of the type. After loading a source list all - you have is a list of package index files that have the ability + the actual construction of the back end type. After loading a source + list all you have is a list of package index files that have the ability to be Acquired. + The vendor machanism is similar, except the vendor types are hard + wired. Before loading the source list the vendor list is loaded. + This doesn't load key data, just the checks to preform. + ##################################################################### */ /*}}}*/ #ifndef PKGLIB_SOURCELIST_H @@ -37,6 +41,18 @@ class pkgSourceList { public: + // An available vendor + struct Vendor + { + string VendorID; + string FingerPrint; + string Description; + + /* Lets revisit these.. + bool MatchFingerPrint(string FingerPrint); + string FingerPrintDescr();*/ + }; + // List of supported source list types class Type { @@ -52,11 +68,13 @@ class pkgSourceList bool FixupURI(string &URI) const; virtual bool ParseLine(vector &List, + Vendor const *Vendor, const char *Buffer, unsigned long CurLine,string File) const; virtual bool CreateItem(vector &List,string URI, - string Dist,string Section) const = 0; - + string Dist,string Section, + Vendor const *Vendor) const = 0; + Type(); virtual ~Type() {}; }; @@ -64,19 +82,21 @@ class pkgSourceList typedef vector::const_iterator const_iterator; protected: - - vector List; + + vector SrcList; + vector VendorList; public: bool ReadMainList(); bool Read(string File); + bool ReadVendors(); // List accessors - inline const_iterator begin() const {return List.begin();}; - inline const_iterator end() const {return List.end();}; - inline unsigned int size() const {return List.size();}; - inline bool empty() const {return List.empty();}; + inline const_iterator begin() const {return SrcList.begin();}; + inline const_iterator end() const {return SrcList.end();}; + inline unsigned int size() const {return SrcList.size();}; + inline bool empty() const {return SrcList.empty();}; bool FindIndex(pkgCache::PkgFileIterator File, pkgIndexFile *&Found) const; diff --git a/apt-pkg/tagfile.cc b/apt-pkg/tagfile.cc index b480704a3..fdeb09329 100644 --- a/apt-pkg/tagfile.cc +++ b/apt-pkg/tagfile.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: tagfile.cc,v 1.27 2001/02/23 06:41:55 jgg Exp $ +// $Id: tagfile.cc,v 1.28 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### Fast scanner for RFC-822 type header information @@ -396,6 +396,7 @@ static const char *iTFRewritePackageOrder[] = { "Filename", "Size", "MD5Sum", + "SHA1Sum", "MSDOS-Filename", // Obsolete "Description", 0}; diff --git a/debian/changelog b/debian/changelog index 98d4b15d9..4197b3c90 100644 --- a/debian/changelog +++ b/debian/changelog @@ -6,7 +6,8 @@ apt (0.5.4) unstable; urgency=low * Various cosmetic code updates. Closes: #89066, #89066, #89152 * Add "pre-auto" as an option for DSelect::Clean (run autoclean after update). - + * More patches from Alfredo for Vendors and more SHA-1 stuff + -- Jason Gunthorpe Thu, 8 Mar 2001 22:48:06 -0700 apt (0.5.3) unstable; urgency=low diff --git a/doc/apt.ent b/doc/apt.ent index 1c95417b3..b85e05f70 100644 --- a/doc/apt.ent +++ b/doc/apt.ent @@ -78,8 +78,8 @@
apt@packages.debian.org
Jason Gunthorpe - 1998-2000 Jason Gunthorpe - 20 September 2000 + 1998-2001 Jason Gunthorpe + 12 March 2001
"> diff --git a/doc/makefile b/doc/makefile index 8aeb406fa..2ea37eae7 100644 --- a/doc/makefile +++ b/doc/makefile @@ -13,7 +13,7 @@ include $(DEBIANDOC_H) # Man pages SOURCE = apt-cache.8 apt-get.8 apt-cdrom.8 apt.conf.5 sources.list.5 \ apt-config.8 apt-sortpkgs.1 apt-ftparchive.1 apt_preferences.5 \ - apt-extracttemplates.1 + apt-extracttemplates.1 vendors.list.5 INCLUDES = apt.ent include $(SGML_MANPAGE_H) diff --git a/doc/vendors.list.5.sgml b/doc/vendors.list.5.sgml new file mode 100644 index 000000000..b9ef9aa56 --- /dev/null +++ b/doc/vendors.list.5.sgml @@ -0,0 +1,104 @@ + + +%aptent; + +]> + + + &apt-docinfo; + + + vendors.list + 5 + + + + + vendors.list + Security key configuration for APT + + + Description</> + <para> + The package vendor list contains a list of all vendors + from whom you wish to authenticate downloaded packages. + For each vendor listed, it must contain the corresponding + PGP key fingerprint, so that APT can perform signature + verification of the release file and subsequent checking + of the checksums of each downloaded package. + To have authentication enabled, you must add the + vendor identification string (see below) enclosed in + square braces to the sources.list line for all sites that mirror + the repository provided by that vendor. + <para> + The format of this file is similar to the one used by + apt.conf. It consists of an arbitrary number of blocks of + vendors, where each block starts with a string telling the + <replaceable/key_type/ and the <replaceable/vendor_id/. + <para> + Some vendors may have multiple blocks that define different + security policies for their distributions. Debian for instance + uses a different signing methodology for stable and unstable releases. + <para> + <replaceable/key_type/ is the type of the check required. + Currently, there is only one type available which is + <literal/simple-key/. + <para> + <replaceable/vendor_id/ is the vendor identification string. It is an + arbitrary string you must supply to uniquely identifify a + vendor that's listed in this file. + + Example: +<informalexample><programlisting> +single_key "joe" +{ + Fingerprint "0987AB4378FSD872343298787ACC"; + Name "Joe Shmoe <joe@shmoe.com>"; +} +</programlisting></informalexample> + + </RefSect1> + + <RefSect1><Title>The simple-key type</> + <para> + This type of verification is used when the vendor has a single + secured key that must be used to sign the Release file. The + following items should be present + + <VariableList> + <VarListEntry><Term>Fingerprint</Term> + <ListItem><Para> + The PGP fingerprint for the key. The fingerprint should be + expressed in the standard notion with or without spaces. + The <option/--fingerprint/ option for + <CiteRefEntry><RefEntryTitle><command/gpg/</RefEntryTitle><ManVolNum/1/</CiteRefEntry> + will show the fingerprint for the selected keys(s). + </VarListEntry> + + <VarListEntry><Term>Name</Term> + <ListItem><Para> + A string containing a description of the owner of + the key or vendor. You may put the vendor name and it's + email. The string must be quoted with ". + </VarListEntry> + + </VariableList> + </RefSect1> + + <RefSect1><Title>Files</> + <para> + <filename>/etc/apt/vendors.list</> + </RefSect1> + + <RefSect1><Title>See Also</> + <para> + &sources-list; + </RefSect1> + + &manbugs; + &manauthor; + +</refentry> + diff --git a/methods/ftp.cc b/methods/ftp.cc index edd150699..a3a7cd08a 100644 --- a/methods/ftp.cc +++ b/methods/ftp.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: ftp.cc,v 1.24 2001/03/06 07:15:29 jgg Exp $ +// $Id: ftp.cc,v 1.25 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### FTP Aquire Method - This is the FTP aquire method for APT. @@ -1056,7 +1056,7 @@ bool FtpMethod::Fetch(FetchItem *Itm) } Res.LastModified = FailTime; - Res.MD5Sum = Hash.MD5.Result(); + Res.TakeHashes(Hash); // Timestamp struct utimbuf UBuf; diff --git a/methods/gzip.cc b/methods/gzip.cc index 3f0efab4f..35ff692f4 100644 --- a/methods/gzip.cc +++ b/methods/gzip.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: gzip.cc,v 1.14 2001/03/11 22:37:35 jgg Exp $ +// $Id: gzip.cc,v 1.15 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### GZip method - Take a file URI in and decompress it into the target @@ -142,7 +142,7 @@ bool GzipMethod::Fetch(FetchItem *Itm) // Return a Done response Res.LastModified = Buf.st_mtime; Res.Size = Buf.st_size; - Res.MD5Sum = Hash.MD5.Result(); + Res.TakeHashes(Hash); URIDone(Res); diff --git a/methods/http.cc b/methods/http.cc index 0c520b33c..342b27993 100644 --- a/methods/http.cc +++ b/methods/http.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: http.cc,v 1.50 2001/03/06 07:15:29 jgg Exp $ +// $Id: http.cc,v 1.51 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### HTTP Aquire Method - This is the HTTP aquire method for APT. @@ -1109,7 +1109,7 @@ int HttpMethod::Loop() // Send status to APT if (Result == true) { - Res.MD5Sum = Server->In.Hash->MD5.Result(); + Res.TakeHashes(*Server->In.Hash); URIDone(Res); } else diff --git a/methods/rsh.cc b/methods/rsh.cc index 5326e5098..619cd9508 100644 --- a/methods/rsh.cc +++ b/methods/rsh.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: rsh.cc,v 1.3 2001/03/06 07:15:29 jgg Exp $ +// $Id: rsh.cc,v 1.4 2001/03/13 06:51:46 jgg Exp $ /* ###################################################################### RSH method - Transfer files via rsh compatible program @@ -462,7 +462,7 @@ bool RSHMethod::Fetch(FetchItem *Itm) } Res.LastModified = FailTime; - Res.MD5Sum = Hash.MD5.Result(); + Res.TakeHashes(Hash); // Timestamp struct utimbuf UBuf; -- 2.45.2