From 40d76f715b4a71e2c69d185e83177b1c2cef9750 Mon Sep 17 00:00:00 2001 From: jbj Date: Wed, 14 Jul 1999 16:47:30 +0000 Subject: [PATCH] move checksig/resign major modes into rpmlib. CVS patchset: 3157 CVS date: 1999/07/14 16:47:30 --- CHANGES | 1 + Makefile.am | 4 +- checksig.c | 353 ---------------------------- checksig.h | 14 -- ftp.h | 33 --- http.h | 87 ------- lib/Makefile.am | 6 +- lib/rpmchecksig.c | 8 +- lib/rpmlib.h | 13 ++ po/POTFILES.in | 2 +- po/rpm.pot | 682 +++++++++++++++++++++++++++--------------------------- rpm.c | 5 +- url.h | 53 ----- 13 files changed, 368 insertions(+), 893 deletions(-) delete mode 100644 checksig.c delete mode 100644 checksig.h delete mode 100644 ftp.h delete mode 100644 http.h delete mode 100644 url.h diff --git a/CHANGES b/CHANGES index 971e440..1f657c1 100644 --- a/CHANGES +++ b/CHANGES @@ -4,6 +4,7 @@ - include shared libs in rpm-devel (no versioning yet). - add epoch (as [0-9]*:version-release) to install dependency parse. - move install/erase major modes into rpmlib. + - move checksig/resign major modes into rpmlib. 3.0.1 -> 3.0.2 - eliminate armv4 entries from rpmrc (Andrew E. Mileski). diff --git a/Makefile.am b/Makefile.am index e249ffe..20d0818 100644 --- a/Makefile.am +++ b/Makefile.am @@ -40,9 +40,9 @@ pkglib_SCRIPTS = find-provides find-requires mkinstalldirs \ config.guess config.sub noinst_HEADERS = \ - acconfig.h build.h checksig.h system.h + acconfig.h build.h system.h -rpm_SOURCES = build.c checksig.c rpm.c +rpm_SOURCES = build.c rpm.c rpm_LDADD = $(mylibs) @LIBMISC@ $(PROGRAMS): $(mylibs) @LIBMISC@ diff --git a/checksig.c b/checksig.c deleted file mode 100644 index facebb4..0000000 --- a/checksig.c +++ /dev/null @@ -1,353 +0,0 @@ -/* checksig.c: verify the signature of an RPM */ - -#include "system.h" - -#include "build/rpmbuild.h" - -#include "checksig.h" -#include "rpmlead.h" -#include "signature.h" - -int doReSign(int add, char *passPhrase, const char **argv) -{ - FD_t fd, ofd; - int count; - struct rpmlead lead; - unsigned short sigtype; - const char *rpm; - const char *sigtarget; - char tmprpm[1024]; - unsigned char buffer[8192]; - Header sig; - - while (*argv) { - rpm = *argv++; - fprintf(stdout, "%s:\n", rpm); - if (fdFileno(fd = fdOpen(rpm, O_RDONLY, 0644)) < 0) { - fprintf(stderr, _("%s: Open failed\n"), rpm); - exit(EXIT_FAILURE); - } - if (readLead(fd, &lead)) { - fprintf(stderr, _("%s: readLead failed\n"), rpm); - exit(EXIT_FAILURE); - } - if (lead.major == 1) { - fprintf(stderr, _("%s: Can't sign v1.0 RPM\n"), rpm); - exit(EXIT_FAILURE); - } - if (lead.major == 2) { - fprintf(stderr, _("%s: Can't re-sign v2.0 RPM\n"), rpm); - exit(EXIT_FAILURE); - } - if (rpmReadSignature(fd, &sig, lead.signature_type)) { - fprintf(stderr, _("%s: rpmReadSignature failed\n"), rpm); - exit(EXIT_FAILURE); - } - if (add != ADD_SIGNATURE) { - rpmFreeSignature(sig); - } - - /* Write the rest to a temp file */ - if (makeTempFile(NULL, &sigtarget, &ofd)) - exit(EXIT_FAILURE); - - while ((count = fdRead(fd, buffer, sizeof(buffer))) > 0) { - if (count == -1) { - perror(_("Couldn't read the header/archive")); - fdClose(ofd); - unlink(sigtarget); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - if (fdWrite(ofd, buffer, count) < 0) { - perror(_("Couldn't write header/archive to temp file")); - fdClose(ofd); - unlink(sigtarget); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - } - fdClose(fd); - fdClose(ofd); - - /* Start writing the new RPM */ - strcpy(tmprpm, rpm); - strcat(tmprpm, ".XXXXXX"); - mktemp(tmprpm); - - ofd = fdOpen(tmprpm, O_WRONLY|O_CREAT|O_TRUNC, 0644); - lead.signature_type = RPMSIG_HEADERSIG; - if (writeLead(ofd, &lead)) { - perror("writeLead()"); - fdClose(ofd); - unlink(sigtarget); - unlink(tmprpm); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - - /* Generate the signature */ - sigtype = rpmLookupSignatureType(RPMLOOKUPSIG_QUERY); - rpmMessage(RPMMESS_VERBOSE, _("Generating signature: %d\n"), sigtype); - if (add != ADD_SIGNATURE) { - sig = rpmNewSignature(); - rpmAddSignature(sig, sigtarget, RPMSIGTAG_SIZE, passPhrase); - rpmAddSignature(sig, sigtarget, RPMSIGTAG_MD5, passPhrase); - } - if (sigtype>0) { - rpmAddSignature(sig, sigtarget, sigtype, passPhrase); - } - if (rpmWriteSignature(ofd, sig)) { - fdClose(ofd); - unlink(sigtarget); - unlink(tmprpm); - xfree(sigtarget); - rpmFreeSignature(sig); - exit(EXIT_FAILURE); - } - rpmFreeSignature(sig); - - /* Append the header and archive */ - fd = fdOpen(sigtarget, O_RDONLY, 0); - while ((count = fdRead(fd, buffer, sizeof(buffer))) > 0) { - if (count == -1) { - perror(_("Couldn't read sigtarget")); - fdClose(ofd); - fdClose(fd); - unlink(sigtarget); - unlink(tmprpm); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - if (fdWrite(ofd, buffer, count) < 0) { - perror(_("Couldn't write package")); - fdClose(ofd); - fdClose(fd); - unlink(sigtarget); - unlink(tmprpm); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - } - fdClose(fd); - fdClose(ofd); - unlink(sigtarget); - xfree(sigtarget); - - /* Move it in to place */ - unlink(rpm); - rename(tmprpm, rpm); - } - - return 0; -} - -int doCheckSig(int flags, const char **argv) -{ - FD_t fd, ofd; - int res, res2, res3; - struct rpmlead lead; - const char *rpm; - char result[1024]; - const char * sigtarget; - unsigned char buffer[8192]; - unsigned char missingKeys[7164]; - unsigned char untrustedKeys[7164]; - Header sig; - HeaderIterator sigIter; - int_32 tag, type, count; - void *ptr; - - res = 0; - while (*argv) { - rpm = *argv++; - if (fdFileno(fd = fdOpen(rpm, O_RDONLY, 0644)) < 0) { - fprintf(stderr, _("%s: Open failed\n"), rpm); - res++; - continue; - } - if (readLead(fd, &lead)) { - fprintf(stderr, _("%s: readLead failed\n"), rpm); - res++; - continue; - } - if (lead.major == 1) { - fprintf(stderr, _("%s: No signature available (v1.0 RPM)\n"), rpm); - res++; - continue; - } - if (rpmReadSignature(fd, &sig, lead.signature_type)) { - fprintf(stderr, _("%s: rpmReadSignature failed\n"), rpm); - res++; - continue; - } - if (sig == NULL) { - fprintf(stderr, _("%s: No signature available\n"), rpm); - res++; - continue; - } - /* Write the rest to a temp file */ - if (makeTempFile(NULL, &sigtarget, &ofd)) - exit(EXIT_FAILURE); - while ((count = fdRead(fd, buffer, sizeof(buffer))) > 0) { - if (count == -1) { - perror(_("Couldn't read the header/archive")); - fdClose(ofd); - unlink(sigtarget); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - if (fdWrite(ofd, buffer, count) < 0) { - fprintf(stderr, _("Unable to write %s"), sigtarget); - perror(""); - fdClose(ofd); - unlink(sigtarget); - xfree(sigtarget); - exit(EXIT_FAILURE); - } - } - fdClose(fd); - fdClose(ofd); - - res2 = 0; - missingKeys[0] = '\0'; - untrustedKeys[0] = '\0'; - sprintf(buffer, "%s:%c", rpm, (rpmIsVerbose() ? '\n' : ' ') ); - - sigIter = headerInitIterator(sig); - while (headerNextIterator(sigIter, &tag, &type, &ptr, &count)) { - if ((tag == RPMSIGTAG_PGP || tag == RPMSIGTAG_PGP5) - && !(flags & CHECKSIG_PGP)) - continue; - if ((tag == RPMSIGTAG_GPG) && !(flags & CHECKSIG_GPG)) - continue; - if ((tag == RPMSIGTAG_MD5 || - tag == RPMSIGTAG_LEMD5_2 || - tag == RPMSIGTAG_LEMD5_1) - && !(flags & CHECKSIG_MD5)) - continue; - - if ((res3 = rpmVerifySignature(sigtarget, tag, ptr, count, - result))) { - if (rpmIsVerbose()) { - strcat(buffer, result); - res2 = 1; - } else { - char *tempKey; - switch (tag) { - case RPMSIGTAG_SIZE: - strcat(buffer, "SIZE "); - res2 = 1; - break; - case RPMSIGTAG_MD5: - case RPMSIGTAG_LEMD5_1: - case RPMSIGTAG_LEMD5_2: - strcat(buffer, "MD5 "); - res2 = 1; - break; - case RPMSIGTAG_PGP: - case RPMSIGTAG_PGP5: - if (res3 == RPMSIG_NOKEY || res3 == RPMSIG_NOTTRUSTED) { - /* Do not consider these a failure */ - int offset = 7; - strcat(buffer, "(PGP) "); - tempKey = strstr(result, "Key ID"); - if (tempKey == NULL) { - tempKey = strstr(result, "keyid:"); - offset = 9; - } - if (tempKey) { - if (res3 == RPMSIG_NOKEY) { - strcat(missingKeys, " PGP#"); - strncat(missingKeys, tempKey + offset, 8); - } else { - strcat(untrustedKeys, " PGP#"); - strncat(untrustedKeys, tempKey + offset, 8); - } - } - } else { - strcat(buffer, "PGP "); - res2 = 1; - } - break; - case RPMSIGTAG_GPG: - if (res3 == RPMSIG_NOKEY) { - /* Do not consider this a failure */ - strcat(buffer, "(GPG) "); - strcat(missingKeys, " GPG#"); - tempKey = strstr(result, "key ID"); - if (tempKey) - strncat(missingKeys, tempKey+7, 8); - } else { - strcat(buffer, "GPG "); - res2 = 1; - } - break; - default: - strcat(buffer, "?UnknownSignatureType? "); - res2 = 1; - } - } - } else { - if (rpmIsVerbose()) { - strcat(buffer, result); - } else { - switch (tag) { - case RPMSIGTAG_SIZE: - strcat(buffer, "size "); - break; - case RPMSIGTAG_MD5: - case RPMSIGTAG_LEMD5_1: - case RPMSIGTAG_LEMD5_2: - strcat(buffer, "md5 "); - break; - case RPMSIGTAG_PGP: - case RPMSIGTAG_PGP5: - strcat(buffer, "pgp "); - break; - case RPMSIGTAG_GPG: - strcat(buffer, "gpg "); - break; - default: - strcat(buffer, "??? "); - } - } - } - } - headerFreeIterator(sigIter); - res += res2; - unlink(sigtarget); - xfree(sigtarget); - - if (res2) { - if (rpmIsVerbose()) { - fprintf(stderr, "%s", (char *)buffer); - } else { - fprintf(stderr, "%s%s%s%s%s%s%s%s\n", (char *)buffer, - _("NOT OK"), - (missingKeys[0] != '\0') ? _(" (MISSING KEYS:") : "", - (char *)missingKeys, - (missingKeys[0] != '\0') ? _(") ") : "", - (untrustedKeys[0] != '\0') ? _(" (UNTRUSTED KEYS:") : "", - (char *)untrustedKeys, - (untrustedKeys[0] != '\0') ? _(")") : ""); - - } - } else { - if (rpmIsVerbose()) { - fprintf(stdout, "%s", (char *)buffer); - } else { - fprintf(stdout, "%s%s%s%s%s%s%s%s\n", (char *)buffer, - _("OK"), - (missingKeys[0] != '\0') ? _(" (MISSING KEYS:") : "", - (char *)missingKeys, - (missingKeys[0] != '\0') ? _(") ") : "", - (untrustedKeys[0] != '\0') ? _(" (UNTRUSTED KEYS:") : "", - (char *)untrustedKeys, - (untrustedKeys[0] != '\0') ? _(")") : ""); - } - } - } - - return res; -} diff --git a/checksig.h b/checksig.h deleted file mode 100644 index 10bba13..0000000 --- a/checksig.h +++ /dev/null @@ -1,14 +0,0 @@ -#ifndef H_CHECKSIG -#define H_CHECKSIG - -#define CHECKSIG_PGP (1 << 0) -#define CHECKSIG_MD5 (1 << 1) -#define CHECKSIG_GPG (1 << 2) - -int doCheckSig(int flags, const char **argv); -int doReSign(int add, char *passPhrase, const char **argv); - -#define ADD_SIGNATURE 1 -#define NEW_SIGNATURE 0 - -#endif diff --git a/ftp.h b/ftp.h deleted file mode 100644 index a39a08f..0000000 --- a/ftp.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef H_FTP -#define H_FTP - -const char * ftpStrerror(int ftpErrno); - -#define FTPERR_BAD_SERVER_RESPONSE -1 -#define FTPERR_SERVER_IO_ERROR -2 -#define FTPERR_SERVER_TIMEOUT -3 -#define FTPERR_BAD_HOST_ADDR -4 -#define FTPERR_BAD_HOSTNAME -5 -#define FTPERR_FAILED_CONNECT -6 -#define FTPERR_FILE_IO_ERROR -7 -#define FTPERR_PASSIVE_ERROR -8 -#define FTPERR_FAILED_DATA_CONNECT -9 -#define FTPERR_FILE_NOT_FOUND -10 -#define FTPERR_NIC_ABORT_IN_PROGRESS -11 -#define FTPERR_UNKNOWN -100 - -#ifndef IPPORT_FTP -# define IPPORT_FTP 21 -#endif - -void urlSetCallback(rpmCallbackFunction notify, void *notifyData, int notifyCount); -int httpOpen(urlinfo *u); -int ftpOpen(urlinfo *u); - -int httpGetFile(FD_t sfd, FD_t tfd); -int ftpGetFile(FD_t sfd, FD_t tfd); -int ftpGetFileDesc(FD_t); -int ftpAbort(FD_t fd); -int ftpClose(FD_t fd); - -#endif diff --git a/http.h b/http.h deleted file mode 100644 index 75038e1..0000000 --- a/http.h +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Portions - * Copyright (c) 1995-1998 The Apache Group. All rights reserved. - */ - -#ifndef H_HTTP -#define H_HTTP - - - - -int httpProxySetup(const char * url, urlinfo ** uret); -int httpCheckResponse(int fd, char ** str); -int httpSkipHeader(FD_t sfd, char *buf,int * bytesRead, char ** start); - - -#define HTTPERR_OKAY 0 -#define HTTPERR_BAD_SERVER_RESPONSE -1 -#define HTTPERR_SERVER_IO_ERROR -2 -#define HTTPERR_SERVER_TIMEOUT -3 -#define HTTPERR_BAD_HOSTNAME -4 -#define HTTPERR_UNSUPPORTED_PROTOCOL -5 -#define HTTPERR_INVALID_PORT -6 -#define HTTPERR_INVALID_SERVER_RESPONSE -7 -#define HTTPERR_UNKNOWN_ERROR -8 -#define HTTPERR_FILE_UNAVAILABLE -9 - - -/* -#define FTPERR_BAD_HOST_ADDR -4 -#define FTPERR_FAILED_CONNECT -6 -#define FTPERR_FILE_IO_ERROR -7 -#define FTPERR_PASSIVE_ERROR -8 -#define FTPERR_FAILED_DATA_CONNECT -9 -#define FTPERR_FILE_NOT_FOUND -10 -#define FTPERR_NIC_ABORT_IN_PROGRESS -11 -*/ - -#define HTTP_CONTINUE 100 -#define HTTP_SWITCHING_PROTOCOLS 101 -#define HTTP_PROCESSING 102 -#define HTTP_OK 200 -#define HTTP_CREATED 201 -#define HTTP_ACCEPTED 202 -#define HTTP_NON_AUTHORITATIVE 203 -#define HTTP_NO_CONTENT 204 -#define HTTP_RESET_CONTENT 205 -#define HTTP_PARTIAL_CONTENT 206 -#define HTTP_MULTI_STATUS 207 -#define HTTP_MULTIPLE_CHOICES 300 -#define HTTP_MOVED_PERMANENTLY 301 -#define HTTP_MOVED_TEMPORARILY 302 -#define HTTP_SEE_OTHER 303 -#define HTTP_NOT_MODIFIED 304 -#define HTTP_USE_PROXY 305 -#define HTTP_TEMPORARY_REDIRECT 307 -#define HTTP_BAD_REQUEST 400 -#define HTTP_UNAUTHORIZED 401 -#define HTTP_PAYMENT_REQUIRED 402 -#define HTTP_FORBIDDEN 403 -#define HTTP_NOT_FOUND 404 -#define HTTP_METHOD_NOT_ALLOWED 405 -#define HTTP_NOT_ACCEPTABLE 406 -#define HTTP_PROXY_AUTHENTICATION_REQUIRED 407 -#define HTTP_REQUEST_TIME_OUT 408 -#define HTTP_CONFLICT 409 -#define HTTP_GONE 410 -#define HTTP_LENGTH_REQUIRED 411 -#define HTTP_PRECONDITION_FAILED 412 -#define HTTP_REQUEST_ENTITY_TOO_LARGE 413 -#define HTTP_REQUEST_URI_TOO_LARGE 414 -#define HTTP_UNSUPPORTED_MEDIA_TYPE 415 -#define HTTP_RANGE_NOT_SATISFIABLE 416 -#define HTTP_EXPECTATION_FAILED 417 -#define HTTP_UNPROCESSABLE_ENTITY 422 -#define HTTP_LOCKED 423 -#define HTTP_INTERNAL_SERVER_ERROR 500 -#define HTTP_NOT_IMPLEMENTED 501 -#define HTTP_BAD_GATEWAY 502 -#define HTTP_SERVICE_UNAVAILABLE 503 -#define HTTP_GATEWAY_TIME_OUT 504 -#define HTTP_VERSION_NOT_SUPPORTED 505 -#define HTTP_VARIANT_ALSO_VARIES 506 -#define HTTP_NOT_EXTENDED 510 - -#endif - diff --git a/lib/Makefile.am b/lib/Makefile.am index 711e18c..887b432 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -22,9 +22,9 @@ librpm_la_SOURCES = \ formats.c fprint.c fs.c ftp.c hash.c header.c install.c \ lookup.c macro.c md5.c md5sum.c \ messages.c misc.c oldheader.c package.c problems.c query.c \ - rebuilddb.c rpmbzio.c rpmdb.c rpmerr.c rpminstall.c rpmio.c rpmlead.c \ - rpmrc.c signature.c stringbuf.c tagName.c tagtable.c transaction.c \ - tread.c uninstall.c url.c verify.c + rebuilddb.c rpmbzio.c rpmchecksig.c rpmdb.c rpmerr.c rpminstall.c \ + rpmio.c rpmlead.c rpmrc.c signature.c stringbuf.c tagName.c tagtable.c \ + transaction.c tread.c uninstall.c url.c verify.c tagtable.c: rpmlib.h @echo '#include "system.h"' > tagtable.c diff --git a/lib/rpmchecksig.c b/lib/rpmchecksig.c index facebb4..73d51e3 100644 --- a/lib/rpmchecksig.c +++ b/lib/rpmchecksig.c @@ -2,13 +2,15 @@ #include "system.h" +#ifdef DYING #include "build/rpmbuild.h" +#endif +#include -#include "checksig.h" #include "rpmlead.h" #include "signature.h" -int doReSign(int add, char *passPhrase, const char **argv) +int rpmReSign(int add, char *passPhrase, const char **argv) { FD_t fd, ofd; int count; @@ -142,7 +144,7 @@ int doReSign(int add, char *passPhrase, const char **argv) return 0; } -int doCheckSig(int flags, const char **argv) +int rpmCheckSig(int flags, const char **argv) { FD_t fd, ofd; int res, res2, res3; diff --git a/lib/rpmlib.h b/lib/rpmlib.h index 60f1503..a09a81b 100644 --- a/lib/rpmlib.h +++ b/lib/rpmlib.h @@ -676,6 +676,19 @@ void printDepFlags(FILE * f, const char * version, int flags); void printDepProblems(FILE * f, struct rpmDependencyConflict * conflicts, int numConflicts); +/* ==================================================================== */ +/* --- checksig/resign */ + +#define CHECKSIG_PGP (1 << 0) +#define CHECKSIG_MD5 (1 << 1) +#define CHECKSIG_GPG (1 << 2) + +int rpmCheckSig(int flags, const char **argv); +int rpmReSign(int add, char *passPhrase, const char **argv); + +#define ADD_SIGNATURE 1 +#define NEW_SIGNATURE 0 + #ifdef __cplusplus } #endif diff --git a/po/POTFILES.in b/po/POTFILES.in index 0207300..b29bb56 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -3,7 +3,6 @@ # Package source files build.c -checksig.c convertdb.c oldrpmdb.c rpm.c @@ -49,6 +48,7 @@ lib/problems.c lib/query.c lib/rebuilddb.c lib/rpmbzio.c +lib/rpmchecksig.c lib/rpmdb.c lib/rpmerr.c lib/rpminstall.c diff --git a/po/rpm.pot b/po/rpm.pot index 820a6fb..7177a04 100644 --- a/po/rpm.pot +++ b/po/rpm.pot @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 1999-07-14 11:36-0400\n" +"POT-Creation-Date: 1999-07-14 12:44-0400\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -89,7 +89,7 @@ msgstr "" msgid "override build root" msgstr "" -#: ../build.c:323 ../rpm.c:458 +#: ../build.c:323 ../rpm.c:457 msgid "remove build tree when done" msgstr "" @@ -109,7 +109,7 @@ msgstr "" msgid "remove specfile when done" msgstr "" -#: ../build.c:333 ../rpm.c:456 +#: ../build.c:333 ../rpm.c:455 msgid "skip straight to specified stage (only for c,i)" msgstr "" @@ -121,91 +121,6 @@ msgstr "" msgid "lookup I18N strings in specfile catalog" msgstr "" -#: ../checksig.c:27 ../checksig.c:165 -#, c-format -msgid "%s: Open failed\n" -msgstr "" - -#: ../checksig.c:31 ../checksig.c:170 -#, c-format -msgid "%s: readLead failed\n" -msgstr "" - -#: ../checksig.c:35 -#, c-format -msgid "%s: Can't sign v1.0 RPM\n" -msgstr "" - -#: ../checksig.c:39 -#, c-format -msgid "%s: Can't re-sign v2.0 RPM\n" -msgstr "" - -#: ../checksig.c:43 ../checksig.c:180 -#, c-format -msgid "%s: rpmReadSignature failed\n" -msgstr "" - -#: ../checksig.c:56 ../checksig.c:194 -msgid "Couldn't read the header/archive" -msgstr "" - -#: ../checksig.c:63 -msgid "Couldn't write header/archive to temp file" -msgstr "" - -#: ../build/pack.c:330 ../checksig.c:91 -#, c-format -msgid "Generating signature: %d\n" -msgstr "" - -#: ../checksig.c:114 -msgid "Couldn't read sigtarget" -msgstr "" - -#: ../checksig.c:123 -msgid "Couldn't write package" -msgstr "" - -#: ../checksig.c:175 -#, c-format -msgid "%s: No signature available (v1.0 RPM)\n" -msgstr "" - -#: ../checksig.c:185 -#, c-format -msgid "%s: No signature available\n" -msgstr "" - -#: ../checksig.c:201 -#, c-format -msgid "Unable to write %s" -msgstr "" - -#: ../checksig.c:327 -msgid "NOT OK" -msgstr "" - -#: ../checksig.c:328 ../checksig.c:342 -msgid " (MISSING KEYS:" -msgstr "" - -#: ../checksig.c:330 ../checksig.c:344 -msgid ") " -msgstr "" - -#: ../checksig.c:331 ../checksig.c:345 -msgid " (UNTRUSTED KEYS:" -msgstr "" - -#: ../checksig.c:333 ../checksig.c:347 -msgid ")" -msgstr "" - -#: ../checksig.c:341 -msgid "OK" -msgstr "" - #: ../convertdb.c:38 msgid "RPM database already exists" msgstr "" @@ -248,1061 +163,1061 @@ msgstr "" msgid "no copyright!\n" msgstr "" -#: ../rpm.c:160 +#: ../rpm.c:159 #, c-format msgid "rpm: %s\n" msgstr "" -#: ../rpm.c:171 +#: ../rpm.c:170 #, c-format msgid "RPM version %s\n" msgstr "" -#: ../rpm.c:175 +#: ../rpm.c:174 msgid "Copyright (C) 1998 - Red Hat Software" msgstr "" -#: ../rpm.c:176 +#: ../rpm.c:175 msgid "" "This may be freely redistributed under the terms of the GNU Public License" msgstr "" -#: ../rpm.c:185 +#: ../rpm.c:184 msgid "usage: rpm {--help}" msgstr "" -#: ../rpm.c:186 +#: ../rpm.c:185 msgid " rpm {--version}" msgstr "" -#: ../rpm.c:187 +#: ../rpm.c:186 msgid " rpm {--initdb} [--dbpath ]" msgstr "" -#: ../rpm.c:188 +#: ../rpm.c:187 msgid "" " rpm {--install -i} [-v] [--hash -h] [--percent] [--force] [--test]" msgstr "" -#: ../rpm.c:189 +#: ../rpm.c:188 msgid " [--replacepkgs] [--replacefiles] [--root ]" msgstr "" -#: ../rpm.c:190 +#: ../rpm.c:189 msgid " [--excludedocs] [--includedocs] [--noscripts]" msgstr "" -#: ../rpm.c:191 +#: ../rpm.c:190 msgid "" " [--rcfile ] [--ignorearch] [--dbpath ]" msgstr "" -#: ../rpm.c:192 +#: ../rpm.c:191 msgid "" " [--prefix ] [--ignoreos] [--nodeps] [--allfiles]" msgstr "" -#: ../rpm.c:193 +#: ../rpm.c:192 msgid "" " [--ftpproxy ] [--ftpport ] [--justdb]" msgstr "" -#: ../rpm.c:194 ../rpm.c:203 ../rpm.c:212 +#: ../rpm.c:193 ../rpm.c:202 ../rpm.c:211 msgid " [--httpproxy ] [--httpport ] " msgstr "" -#: ../rpm.c:195 ../rpm.c:205 +#: ../rpm.c:194 ../rpm.c:204 msgid " [--noorder] [--relocate oldpath=newpath]" msgstr "" -#: ../rpm.c:196 +#: ../rpm.c:195 msgid "" " [--badreloc] [--notriggers] [--excludepath ]" msgstr "" -#: ../rpm.c:197 +#: ../rpm.c:196 msgid " [--ignoresize] file1.rpm ... fileN.rpm" msgstr "" -#: ../rpm.c:198 +#: ../rpm.c:197 msgid "" " rpm {--upgrade -U} [-v] [--hash -h] [--percent] [--force] [--test]" msgstr "" -#: ../rpm.c:199 +#: ../rpm.c:198 msgid " [--oldpackage] [--root ] [--noscripts]" msgstr "" -#: ../rpm.c:200 +#: ../rpm.c:199 msgid "" " [--excludedocs] [--includedocs] [--rcfile ]" msgstr "" -#: ../rpm.c:201 +#: ../rpm.c:200 msgid "" " [--ignorearch] [--dbpath ] [--prefix ] " msgstr "" -#: ../rpm.c:202 +#: ../rpm.c:201 msgid " [--ftpproxy ] [--ftpport ]" msgstr "" -#: ../rpm.c:204 +#: ../rpm.c:203 msgid " [--ignoreos] [--nodeps] [--allfiles] [--justdb]" msgstr "" -#: ../rpm.c:206 +#: ../rpm.c:205 msgid "" " [--badreloc] [--excludepath ] [--ignoresize]" msgstr "" -#: ../rpm.c:207 +#: ../rpm.c:206 msgid " file1.rpm ... fileN.rpm" msgstr "" -#: ../rpm.c:208 +#: ../rpm.c:207 msgid " rpm {--query -q} [-afpg] [-i] [-l] [-s] [-d] [-c] [-v] [-R]" msgstr "" -#: ../rpm.c:209 +#: ../rpm.c:208 msgid " [--scripts] [--root ] [--rcfile ]" msgstr "" -#: ../rpm.c:210 +#: ../rpm.c:209 msgid " [--whatprovides] [--whatrequires] [--requires]" msgstr "" -#: ../rpm.c:211 +#: ../rpm.c:210 msgid "" " [--triggeredby] [--ftpuseport] [--ftpproxy ]" msgstr "" -#: ../rpm.c:213 +#: ../rpm.c:212 msgid "" " [--ftpport ] [--provides] [--triggers] [--dump]" msgstr "" -#: ../rpm.c:214 +#: ../rpm.c:213 msgid " [--changelog] [--dbpath ] [targets]" msgstr "" -#: ../rpm.c:215 +#: ../rpm.c:214 msgid " rpm {--verify -V -y} [-afpg] [--root ] [--rcfile ]" msgstr "" -#: ../rpm.c:216 +#: ../rpm.c:215 msgid "" " [--dbpath ] [--nodeps] [--nofiles] [--noscripts]" msgstr "" -#: ../rpm.c:217 +#: ../rpm.c:216 msgid " [--nomd5] [targets]" msgstr "" -#: ../rpm.c:218 +#: ../rpm.c:217 msgid " rpm {--setperms} [-afpg] [target]" msgstr "" -#: ../rpm.c:219 +#: ../rpm.c:218 msgid " rpm {--setugids} [-afpg] [target]" msgstr "" -#: ../rpm.c:220 +#: ../rpm.c:219 msgid " rpm {--erase -e} [--root ] [--noscripts] [--rcfile ]" msgstr "" -#: ../rpm.c:221 +#: ../rpm.c:220 msgid " [--dbpath ] [--nodeps] [--allmatches]" msgstr "" -#: ../rpm.c:222 +#: ../rpm.c:221 msgid "" " [--justdb] [--notriggers] rpackage1 ... packageN" msgstr "" -#: ../rpm.c:223 +#: ../rpm.c:222 msgid "" " rpm {-b|t}[plciba] [-v] [--short-circuit] [--clean] [--rcfile ]" msgstr "" -#: ../rpm.c:224 +#: ../rpm.c:223 msgid " [--sign] [--nobuild] [--timecheck ] ]" msgstr "" -#: ../rpm.c:225 +#: ../rpm.c:224 msgid " [--target=platform1[,platform2...]]" msgstr "" -#: ../rpm.c:226 +#: ../rpm.c:225 msgid " [--rmsource] specfile" msgstr "" -#: ../rpm.c:227 +#: ../rpm.c:226 msgid " rpm {--rmsource} [--rcfile ] [-v] specfile" msgstr "" -#: ../rpm.c:228 +#: ../rpm.c:227 msgid "" " rpm {--rebuild} [--rcfile ] [-v] source1.rpm ... sourceN.rpm" msgstr "" -#: ../rpm.c:229 +#: ../rpm.c:228 msgid "" " rpm {--recompile} [--rcfile ] [-v] source1.rpm ... sourceN.rpm" msgstr "" -#: ../rpm.c:230 +#: ../rpm.c:229 msgid " rpm {--resign} [--rcfile ] package1 package2 ... packageN" msgstr "" -#: ../rpm.c:231 +#: ../rpm.c:230 msgid " rpm {--addsign} [--rcfile ] package1 package2 ... packageN" msgstr "" -#: ../rpm.c:232 +#: ../rpm.c:231 msgid "" " rpm {--checksig -K} [--nopgp] [--nogpg] [--nomd5] [--rcfile ]" msgstr "" -#: ../rpm.c:233 +#: ../rpm.c:232 msgid " package1 ... packageN" msgstr "" -#: ../rpm.c:234 +#: ../rpm.c:233 msgid " rpm {--rebuilddb} [--rcfile ] [--dbpath ]" msgstr "" -#: ../rpm.c:235 +#: ../rpm.c:234 msgid " rpm {--querytags}" msgstr "" -#: ../rpm.c:269 +#: ../rpm.c:268 msgid "usage:" msgstr "" -#: ../rpm.c:271 +#: ../rpm.c:270 msgid "print this message" msgstr "" -#: ../rpm.c:273 +#: ../rpm.c:272 msgid "print the version of rpm being used" msgstr "" -#: ../rpm.c:274 +#: ../rpm.c:273 msgid " all modes support the following arguments:" msgstr "" -#: ../rpm.c:275 +#: ../rpm.c:274 msgid " --rcfile " msgstr "" -#: ../rpm.c:276 +#: ../rpm.c:275 msgid "use instead of /etc/rpmrc and $HOME/.rpmrc" msgstr "" -#: ../rpm.c:278 +#: ../rpm.c:277 msgid "be a little more verbose" msgstr "" -#: ../rpm.c:280 +#: ../rpm.c:279 msgid "be incredibly verbose (for debugging)" msgstr "" -#: ../rpm.c:282 +#: ../rpm.c:281 msgid "query mode" msgstr "" -#: ../rpm.c:283 ../rpm.c:345 ../rpm.c:409 ../rpm.c:437 +#: ../rpm.c:282 ../rpm.c:344 ../rpm.c:408 ../rpm.c:436 msgid " --root " msgstr "" -#: ../rpm.c:284 ../rpm.c:346 ../rpm.c:410 ../rpm.c:438 ../rpm.c:500 +#: ../rpm.c:283 ../rpm.c:345 ../rpm.c:409 ../rpm.c:437 ../rpm.c:499 msgid "use as the top level directory" msgstr "" -#: ../rpm.c:285 ../rpm.c:343 ../rpm.c:373 ../rpm.c:425 ../rpm.c:497 +#: ../rpm.c:284 ../rpm.c:342 ../rpm.c:372 ../rpm.c:424 ../rpm.c:496 msgid " --dbpath " msgstr "" -#: ../rpm.c:286 ../rpm.c:344 ../rpm.c:374 ../rpm.c:426 ../rpm.c:498 +#: ../rpm.c:285 ../rpm.c:343 ../rpm.c:373 ../rpm.c:425 ../rpm.c:497 msgid "use as the directory for the database" msgstr "" -#: ../rpm.c:287 +#: ../rpm.c:286 msgid " --queryformat " msgstr "" -#: ../rpm.c:288 +#: ../rpm.c:287 msgid "use as the header format (implies -i)" msgstr "" -#: ../rpm.c:289 +#: ../rpm.c:288 msgid "" " install, upgrade and query (with -p) allow ftp URL's to be used in place" msgstr "" -#: ../rpm.c:290 +#: ../rpm.c:289 msgid " of file names as well as the following options:" msgstr "" -#: ../rpm.c:291 +#: ../rpm.c:290 msgid " --ftpproxy " msgstr "" -#: ../rpm.c:292 +#: ../rpm.c:291 msgid "hostname or IP of ftp proxy" msgstr "" -#: ../rpm.c:293 +#: ../rpm.c:292 msgid " --ftpport " msgstr "" -#: ../rpm.c:294 +#: ../rpm.c:293 msgid "port number of ftp server (or proxy)" msgstr "" -#: ../rpm.c:295 +#: ../rpm.c:294 msgid " --httpproxy " msgstr "" -#: ../rpm.c:296 +#: ../rpm.c:295 msgid "hostname or IP of http proxy" msgstr "" -#: ../rpm.c:297 +#: ../rpm.c:296 msgid " --httpport " msgstr "" -#: ../rpm.c:298 +#: ../rpm.c:297 msgid "port number of http server (or proxy)" msgstr "" -#: ../rpm.c:299 +#: ../rpm.c:298 msgid " Package specification options:" msgstr "" -#: ../rpm.c:301 +#: ../rpm.c:300 msgid "query all packages" msgstr "" -#: ../rpm.c:302 +#: ../rpm.c:301 msgid " -f + " msgstr "" -#: ../rpm.c:303 +#: ../rpm.c:302 msgid "query package owning " msgstr "" -#: ../rpm.c:304 +#: ../rpm.c:303 msgid " -p + " msgstr "" -#: ../rpm.c:305 +#: ../rpm.c:304 msgid "query (uninstalled) package " msgstr "" -#: ../rpm.c:306 +#: ../rpm.c:305 msgid " --triggeredby " msgstr "" -#: ../rpm.c:307 +#: ../rpm.c:306 msgid "query packages triggered by " msgstr "" -#: ../rpm.c:308 +#: ../rpm.c:307 msgid " --whatprovides " msgstr "" -#: ../rpm.c:309 +#: ../rpm.c:308 msgid "query packages which provide capability" msgstr "" -#: ../rpm.c:310 +#: ../rpm.c:309 msgid " --whatrequires " msgstr "" -#: ../rpm.c:311 +#: ../rpm.c:310 msgid "query packages which require capability" msgstr "" -#: ../rpm.c:312 +#: ../rpm.c:311 msgid " Information selection options:" msgstr "" -#: ../rpm.c:314 +#: ../rpm.c:313 msgid "display package information" msgstr "" -#: ../rpm.c:316 +#: ../rpm.c:315 msgid "display the package's change log" msgstr "" -#: ../rpm.c:318 +#: ../rpm.c:317 msgid "display package file list" msgstr "" -#: ../rpm.c:320 +#: ../rpm.c:319 msgid "show file states (implies -l)" msgstr "" -#: ../rpm.c:322 +#: ../rpm.c:321 msgid "list only documentation files (implies -l)" msgstr "" -#: ../rpm.c:324 +#: ../rpm.c:323 msgid "list only configuration files (implies -l)" msgstr "" -#: ../rpm.c:326 +#: ../rpm.c:325 msgid "" "show all verifiable information for each file (must be used with -l, -c, or " "-d)" msgstr "" -#: ../rpm.c:328 +#: ../rpm.c:327 msgid "list capabilities package provides" msgstr "" -#: ../rpm.c:329 +#: ../rpm.c:328 msgid " --requires" msgstr "" -#: ../rpm.c:331 +#: ../rpm.c:330 msgid "list package dependencies" msgstr "" -#: ../rpm.c:333 +#: ../rpm.c:332 msgid "print the various [un]install scripts" msgstr "" -#: ../rpm.c:335 +#: ../rpm.c:334 msgid "show the trigger scripts contained in the package" msgstr "" -#: ../rpm.c:339 +#: ../rpm.c:338 msgid " --pipe " msgstr "" -#: ../rpm.c:340 +#: ../rpm.c:339 msgid "send stdout to " msgstr "" -#: ../rpm.c:342 +#: ../rpm.c:341 msgid "" "verify a package installation using the same same package specification " "options as -q" msgstr "" -#: ../rpm.c:348 ../rpm.c:396 ../rpm.c:430 +#: ../rpm.c:347 ../rpm.c:395 ../rpm.c:429 msgid "do not verify package dependencies" msgstr "" -#: ../rpm.c:350 +#: ../rpm.c:349 msgid "do not verify file md5 checksums" msgstr "" -#: ../rpm.c:352 +#: ../rpm.c:351 msgid "do not verify file attributes" msgstr "" -#: ../rpm.c:355 +#: ../rpm.c:354 msgid "" "set the file permissions to those in the package database using the same " "package specification options as -q" msgstr "" -#: ../rpm.c:358 +#: ../rpm.c:357 msgid "" "set the file owner and group to those in the package database using the same " "package specification options as -q" msgstr "" -#: ../rpm.c:362 +#: ../rpm.c:361 msgid " --install " msgstr "" -#: ../rpm.c:363 +#: ../rpm.c:362 msgid " -i " msgstr "" -#: ../rpm.c:364 +#: ../rpm.c:363 msgid "install package" msgstr "" -#: ../rpm.c:365 +#: ../rpm.c:364 msgid " --excludepath " msgstr "" -#: ../rpm.c:366 +#: ../rpm.c:365 msgid "skip files in path " msgstr "" -#: ../rpm.c:367 +#: ../rpm.c:366 msgid " --relocate =" msgstr "" -#: ../rpm.c:368 +#: ../rpm.c:367 msgid "relocate files from to " msgstr "" -#: ../rpm.c:370 +#: ../rpm.c:369 msgid "relocate files even though the package doesn't allow it" msgstr "" -#: ../rpm.c:371 +#: ../rpm.c:370 msgid " --prefix " msgstr "" -#: ../rpm.c:372 +#: ../rpm.c:371 msgid "relocate the package to , if relocatable" msgstr "" -#: ../rpm.c:376 +#: ../rpm.c:375 msgid "do not install documentation" msgstr "" -#: ../rpm.c:378 +#: ../rpm.c:377 msgid "short hand for --replacepkgs --replacefiles" msgstr "" -#: ../rpm.c:381 +#: ../rpm.c:380 msgid "print hash marks as package installs (good with -v)" msgstr "" -#: ../rpm.c:383 +#: ../rpm.c:382 msgid "install all files, even configurations which might otherwise be skipped" msgstr "" -#: ../rpm.c:386 +#: ../rpm.c:385 msgid "don't verify package architecture" msgstr "" -#: ../rpm.c:388 +#: ../rpm.c:387 msgid "don't check disk space before installing" msgstr "" -#: ../rpm.c:390 +#: ../rpm.c:389 msgid "don't verify package operating system" msgstr "" -#: ../rpm.c:392 +#: ../rpm.c:391 msgid "install documentation" msgstr "" -#: ../rpm.c:394 ../rpm.c:428 +#: ../rpm.c:393 ../rpm.c:427 msgid "update the database, but do not modify the filesystem" msgstr "" -#: ../rpm.c:398 ../rpm.c:432 +#: ../rpm.c:397 ../rpm.c:431 msgid "do not reorder package installation to satisfy dependencies" msgstr "" -#: ../rpm.c:400 +#: ../rpm.c:399 msgid "don't execute any installation scripts" msgstr "" -#: ../rpm.c:402 ../rpm.c:436 +#: ../rpm.c:401 ../rpm.c:435 msgid "don't execute any scripts triggered by this package" msgstr "" -#: ../rpm.c:404 +#: ../rpm.c:403 msgid "print percentages as package installs" msgstr "" -#: ../rpm.c:406 +#: ../rpm.c:405 msgid "install even if the package replaces installed files" msgstr "" -#: ../rpm.c:408 +#: ../rpm.c:407 msgid "reinstall if the package is already present" msgstr "" -#: ../rpm.c:412 +#: ../rpm.c:411 msgid "don't install, but tell if it would work or not" msgstr "" -#: ../rpm.c:414 +#: ../rpm.c:413 msgid " --upgrade " msgstr "" -#: ../rpm.c:415 +#: ../rpm.c:414 msgid " -U " msgstr "" -#: ../rpm.c:416 +#: ../rpm.c:415 msgid "upgrade package (same options as --install, plus)" msgstr "" -#: ../rpm.c:418 +#: ../rpm.c:417 msgid "" "upgrade to an old version of the package (--force on upgrades does this " "automatically)" msgstr "" -#: ../rpm.c:420 +#: ../rpm.c:419 msgid " --erase " msgstr "" -#: ../rpm.c:422 +#: ../rpm.c:421 msgid "erase (uninstall) package" msgstr "" -#: ../rpm.c:424 +#: ../rpm.c:423 msgid "" "remove all packages which match (normally an error is generated if " " specified multiple packages)" msgstr "" -#: ../rpm.c:434 +#: ../rpm.c:433 msgid "do not execute any package specific scripts" msgstr "" -#: ../rpm.c:440 +#: ../rpm.c:439 msgid " -b " msgstr "" -#: ../rpm.c:441 +#: ../rpm.c:440 msgid " -t " msgstr "" -#: ../rpm.c:442 +#: ../rpm.c:441 msgid "build package, where is one of:" msgstr "" -#: ../rpm.c:444 +#: ../rpm.c:443 msgid "prep (unpack sources and apply patches)" msgstr "" -#: ../rpm.c:446 +#: ../rpm.c:445 #, c-format msgid "list check (do some cursory checks on %files)" msgstr "" -#: ../rpm.c:448 +#: ../rpm.c:447 msgid "compile (prep and compile)" msgstr "" -#: ../rpm.c:450 +#: ../rpm.c:449 msgid "install (prep, compile, install)" msgstr "" -#: ../rpm.c:452 +#: ../rpm.c:451 msgid "binary package (prep, compile, install, package)" msgstr "" -#: ../rpm.c:454 +#: ../rpm.c:453 msgid "bin/src package (prep, compile, install, package)" msgstr "" -#: ../rpm.c:460 +#: ../rpm.c:459 msgid "remove sources and spec file when done" msgstr "" -#: ../rpm.c:462 +#: ../rpm.c:461 msgid "generate PGP/GPG signature" msgstr "" -#: ../rpm.c:463 +#: ../rpm.c:462 msgid " --buildroot " msgstr "" -#: ../rpm.c:464 +#: ../rpm.c:463 msgid "use as the build root" msgstr "" -#: ../rpm.c:465 +#: ../rpm.c:464 msgid " --target=+" msgstr "" -#: ../rpm.c:466 +#: ../rpm.c:465 msgid "build the packages for the build targets platform1...platformN." msgstr "" -#: ../rpm.c:468 +#: ../rpm.c:467 msgid "do not execute any stages" msgstr "" -#: ../rpm.c:469 +#: ../rpm.c:468 msgid " --timecheck " msgstr "" -#: ../rpm.c:470 +#: ../rpm.c:469 msgid "set the time check to seconds (0 disables)" msgstr "" -#: ../rpm.c:472 +#: ../rpm.c:471 msgid " --rebuild " msgstr "" -#: ../rpm.c:473 +#: ../rpm.c:472 msgid "" "install source package, build binary package and remove spec file, sources, " "patches, and icons." msgstr "" -#: ../rpm.c:474 +#: ../rpm.c:473 msgid " --rmsource " msgstr "" -#: ../rpm.c:475 +#: ../rpm.c:474 msgid "remove sources and spec file" msgstr "" -#: ../rpm.c:476 +#: ../rpm.c:475 msgid " --recompile " msgstr "" -#: ../rpm.c:477 +#: ../rpm.c:476 msgid "like --rebuild, but don't build any package" msgstr "" -#: ../rpm.c:478 +#: ../rpm.c:477 msgid " --resign + " msgstr "" -#: ../rpm.c:479 +#: ../rpm.c:478 msgid "sign a package (discard current signature)" msgstr "" -#: ../rpm.c:480 +#: ../rpm.c:479 msgid " --addsign + " msgstr "" -#: ../rpm.c:481 +#: ../rpm.c:480 msgid "add a signature to a package" msgstr "" -#: ../rpm.c:483 +#: ../rpm.c:482 msgid " --checksig + " msgstr "" -#: ../rpm.c:484 +#: ../rpm.c:483 msgid "verify package signature" msgstr "" -#: ../rpm.c:486 +#: ../rpm.c:485 msgid "skip any PGP signatures" msgstr "" -#: ../rpm.c:488 +#: ../rpm.c:487 msgid "skip any GPG signatures" msgstr "" -#: ../rpm.c:490 +#: ../rpm.c:489 msgid "skip any MD5 signatures" msgstr "" -#: ../rpm.c:492 +#: ../rpm.c:491 msgid "list the tags that can be used in a query format" msgstr "" -#: ../rpm.c:494 +#: ../rpm.c:493 msgid "make sure a valid database exists" msgstr "" -#: ../rpm.c:496 +#: ../rpm.c:495 msgid "rebuild database from existing database" msgstr "" -#: ../rpm.c:635 ../rpm.c:641 ../rpm.c:648 ../rpm.c:654 ../rpm.c:663 -#: ../rpm.c:670 ../rpm.c:717 ../rpm.c:723 ../rpm.c:757 ../rpm.c:763 -#: ../rpm.c:769 ../rpm.c:777 ../rpm.c:812 ../rpm.c:867 ../rpm.c:874 +#: ../rpm.c:634 ../rpm.c:640 ../rpm.c:647 ../rpm.c:653 ../rpm.c:662 +#: ../rpm.c:669 ../rpm.c:716 ../rpm.c:722 ../rpm.c:756 ../rpm.c:762 +#: ../rpm.c:768 ../rpm.c:776 ../rpm.c:811 ../rpm.c:866 ../rpm.c:873 msgid "only one major mode may be specified" msgstr "" -#: ../rpm.c:656 +#: ../rpm.c:655 msgid "-u and --uninstall are deprecated and no longer work.\n" msgstr "" -#: ../rpm.c:658 +#: ../rpm.c:657 msgid "Use -e or --erase instead.\n" msgstr "" -#: ../rpm.c:674 +#: ../rpm.c:673 msgid "--build (-b) requires one of a,b,i,c,p,l as its sole argument" msgstr "" -#: ../rpm.c:678 +#: ../rpm.c:677 msgid "--tarbuild (-t) requires one of a,b,i,c,p,l as its sole argument" msgstr "" -#: ../rpm.c:730 ../rpm.c:736 ../rpm.c:743 ../rpm.c:750 ../rpm.c:881 +#: ../rpm.c:729 ../rpm.c:735 ../rpm.c:742 ../rpm.c:749 ../rpm.c:880 msgid "one type of query/verify may be performed at a time" msgstr "" -#: ../rpm.c:785 +#: ../rpm.c:784 msgid "arguments to --dbpath must begin with a /" msgstr "" -#: ../rpm.c:818 +#: ../rpm.c:817 msgid "relocations must begin with a /" msgstr "" -#: ../rpm.c:820 +#: ../rpm.c:819 msgid "relocations must contain a =" msgstr "" -#: ../rpm.c:823 +#: ../rpm.c:822 msgid "relocations must have a / following the =" msgstr "" -#: ../rpm.c:832 +#: ../rpm.c:831 msgid "exclude paths must begin with a /" msgstr "" -#: ../rpm.c:841 +#: ../rpm.c:840 #, c-format msgid "Internal error in argument processing (%d) :-(\n" msgstr "" -#: ../rpm.c:894 +#: ../rpm.c:893 msgid "--dbpath given for operation that does not use a database" msgstr "" -#: ../rpm.c:899 +#: ../rpm.c:898 msgid "--timecheck may only be used during package builds" msgstr "" -#: ../rpm.c:902 +#: ../rpm.c:901 msgid "unexpected query flags" msgstr "" -#: ../rpm.c:905 +#: ../rpm.c:904 msgid "unexpected query format" msgstr "" -#: ../rpm.c:909 +#: ../rpm.c:908 msgid "unexpected query source" msgstr "" -#: ../rpm.c:915 +#: ../rpm.c:914 msgid "only installation, upgrading, rmsource and rmspec may be forced" msgstr "" -#: ../rpm.c:918 +#: ../rpm.c:917 msgid "files may only be relocated during package installation" msgstr "" -#: ../rpm.c:921 +#: ../rpm.c:920 msgid "only one of --prefix or --relocate may be used" msgstr "" -#: ../rpm.c:924 +#: ../rpm.c:923 msgid "" "--relocate and --excludepath may only be used when installing new packages" msgstr "" -#: ../rpm.c:927 +#: ../rpm.c:926 msgid "--prefix may only be used when installing new packages" msgstr "" -#: ../rpm.c:930 +#: ../rpm.c:929 msgid "arguments to --prefix must begin with a /" msgstr "" -#: ../rpm.c:933 +#: ../rpm.c:932 msgid "--hash (-h) may only be specified during package installation" msgstr "" -#: ../rpm.c:937 +#: ../rpm.c:936 msgid "--percent may only be specified during package installation" msgstr "" -#: ../rpm.c:941 +#: ../rpm.c:940 msgid "--replacefiles may only be specified during package installation" msgstr "" -#: ../rpm.c:945 +#: ../rpm.c:944 msgid "--replacepkgs may only be specified during package installation" msgstr "" -#: ../rpm.c:949 +#: ../rpm.c:948 msgid "--excludedocs may only be specified during package installation" msgstr "" -#: ../rpm.c:953 +#: ../rpm.c:952 msgid "--includedocs may only be specified during package installation" msgstr "" -#: ../rpm.c:957 +#: ../rpm.c:956 msgid "only one of --excludedocs and --includedocs may be specified" msgstr "" -#: ../rpm.c:961 +#: ../rpm.c:960 msgid "--ignorearch may only be specified during package installation" msgstr "" -#: ../rpm.c:965 +#: ../rpm.c:964 msgid "--ignoreos may only be specified during package installation" msgstr "" -#: ../rpm.c:969 +#: ../rpm.c:968 msgid "--ignoresize may only be specified during package installation" msgstr "" -#: ../rpm.c:973 +#: ../rpm.c:972 msgid "--allmatches may only be specified during package erasure" msgstr "" -#: ../rpm.c:977 +#: ../rpm.c:976 msgid "--allfiles may only be specified during package installation" msgstr "" -#: ../rpm.c:981 +#: ../rpm.c:980 msgid "--justdb may only be specified during package installation and erasure" msgstr "" -#: ../rpm.c:986 +#: ../rpm.c:985 msgid "" "--noscripts may only be specified during package installation, erasure, and " "verification" msgstr "" -#: ../rpm.c:990 +#: ../rpm.c:989 msgid "" "--notriggers may only be specified during package installation, erasure, and " "verification" msgstr "" -#: ../rpm.c:996 +#: ../rpm.c:995 msgid "" "--nodeps may only be specified during package building, installation, " "erasure, and verification" msgstr "" -#: ../rpm.c:1001 +#: ../rpm.c:1000 msgid "" "--test may only be specified during package installation, erasure, and " "building" msgstr "" -#: ../rpm.c:1006 +#: ../rpm.c:1005 msgid "" "--root (-r) may only be specified during installation, erasure, querying, " "and database rebuilds" msgstr "" -#: ../rpm.c:1011 +#: ../rpm.c:1010 msgid "arguments to --root (-r) must begin with a /" msgstr "" -#: ../rpm.c:1014 +#: ../rpm.c:1013 msgid "--oldpackage may only be used during upgrades" msgstr "" -#: ../rpm.c:1019 +#: ../rpm.c:1018 msgid "" "ftp options can only be used during package queries, installs, and upgrades" msgstr "" -#: ../rpm.c:1025 +#: ../rpm.c:1024 msgid "" "http options can only be used during package queries, installs, and upgrades" msgstr "" -#: ../rpm.c:1029 +#: ../rpm.c:1028 msgid "--nopgp may only be used during signature checking" msgstr "" -#: ../rpm.c:1032 +#: ../rpm.c:1031 msgid "--nogpg may only be used during signature checking" msgstr "" -#: ../rpm.c:1035 +#: ../rpm.c:1034 msgid "" "--nomd5 may only be used during signature checking and package verification" msgstr "" -#: ../rpm.c:1061 +#: ../rpm.c:1060 #, c-format msgid "cannot access file %s\n" msgstr "" -#: ../rpm.c:1078 +#: ../rpm.c:1077 msgid "pgp not found: " msgstr "" -#: ../rpm.c:1081 +#: ../rpm.c:1080 msgid "Use `%%_signature pgp5' instead of `%%_signature pgp' in macro file.\n" msgstr "" -#: ../rpm.c:1088 +#: ../rpm.c:1087 msgid "pgp version 5 not found: " msgstr "" -#: ../rpm.c:1091 +#: ../rpm.c:1090 msgid "Use `%%_signature pgp' instead of `%%_signature pgp5' in macro file.\n" msgstr "" -#: ../rpm.c:1097 +#: ../rpm.c:1096 msgid "Enter pass phrase: " msgstr "" -#: ../rpm.c:1098 +#: ../rpm.c:1097 msgid "Pass phrase check failed\n" msgstr "" -#: ../rpm.c:1101 +#: ../rpm.c:1100 msgid "Pass phrase is good.\n" msgstr "" -#: ../rpm.c:1108 +#: ../rpm.c:1107 msgid "Invalid %%_signature spec in macro file.\n" msgstr "" -#: ../rpm.c:1113 +#: ../rpm.c:1112 msgid "--sign may only be used during package building" msgstr "" -#: ../rpm.c:1130 +#: ../rpm.c:1129 msgid "exec failed\n" msgstr "" -#: ../rpm.c:1149 +#: ../rpm.c:1148 msgid "unexpected arguments to --querytags " msgstr "" -#: ../rpm.c:1160 +#: ../rpm.c:1159 msgid "no packages given for signature check" msgstr "" -#: ../rpm.c:1172 +#: ../rpm.c:1171 msgid "no packages given for signing" msgstr "" -#: ../rpm.c:1185 +#: ../rpm.c:1184 msgid "no packages files given for rebuild" msgstr "" -#: ../rpm.c:1242 +#: ../rpm.c:1241 msgid "no spec files given for build" msgstr "" -#: ../rpm.c:1244 +#: ../rpm.c:1243 msgid "no tar files given for build" msgstr "" -#: ../rpm.c:1256 +#: ../rpm.c:1255 msgid "no packages given for uninstall" msgstr "" -#: ../rpm.c:1305 +#: ../rpm.c:1304 msgid "no packages given for install" msgstr "" -#: ../rpm.c:1328 +#: ../rpm.c:1327 msgid "extra arguments given for query of all packages" msgstr "" -#: ../rpm.c:1333 +#: ../rpm.c:1332 msgid "no arguments given for query" msgstr "" -#: ../rpm.c:1350 +#: ../rpm.c:1349 msgid "extra arguments given for verify of all packages" msgstr "" -#: ../rpm.c:1354 +#: ../rpm.c:1353 msgid "no arguments given for verify" msgstr "" @@ -1598,6 +1513,11 @@ msgstr "" msgid "Unable to write package: %s" msgstr "" +#: ../build/pack.c:330 ../lib/rpmchecksig.c:93 +#, c-format +msgid "Generating signature: %d\n" +msgstr "" + #: ../build/pack.c:347 #, c-format msgid "Unable to read sigtarget: %s" @@ -2799,6 +2719,86 @@ msgstr "" msgid "failed to remove directory %s: %s\n" msgstr "" +#: ../lib/rpmchecksig.c:29 ../lib/rpmchecksig.c:167 +#, c-format +msgid "%s: Open failed\n" +msgstr "" + +#: ../lib/rpmchecksig.c:33 ../lib/rpmchecksig.c:172 +#, c-format +msgid "%s: readLead failed\n" +msgstr "" + +#: ../lib/rpmchecksig.c:37 +#, c-format +msgid "%s: Can't sign v1.0 RPM\n" +msgstr "" + +#: ../lib/rpmchecksig.c:41 +#, c-format +msgid "%s: Can't re-sign v2.0 RPM\n" +msgstr "" + +#: ../lib/rpmchecksig.c:45 ../lib/rpmchecksig.c:182 +#, c-format +msgid "%s: rpmReadSignature failed\n" +msgstr "" + +#: ../lib/rpmchecksig.c:58 ../lib/rpmchecksig.c:196 +msgid "Couldn't read the header/archive" +msgstr "" + +#: ../lib/rpmchecksig.c:65 +msgid "Couldn't write header/archive to temp file" +msgstr "" + +#: ../lib/rpmchecksig.c:116 +msgid "Couldn't read sigtarget" +msgstr "" + +#: ../lib/rpmchecksig.c:125 +msgid "Couldn't write package" +msgstr "" + +#: ../lib/rpmchecksig.c:177 +#, c-format +msgid "%s: No signature available (v1.0 RPM)\n" +msgstr "" + +#: ../lib/rpmchecksig.c:187 +#, c-format +msgid "%s: No signature available\n" +msgstr "" + +#: ../lib/rpmchecksig.c:203 +#, c-format +msgid "Unable to write %s" +msgstr "" + +#: ../lib/rpmchecksig.c:329 +msgid "NOT OK" +msgstr "" + +#: ../lib/rpmchecksig.c:330 ../lib/rpmchecksig.c:344 +msgid " (MISSING KEYS:" +msgstr "" + +#: ../lib/rpmchecksig.c:332 ../lib/rpmchecksig.c:346 +msgid ") " +msgstr "" + +#: ../lib/rpmchecksig.c:333 ../lib/rpmchecksig.c:347 +msgid " (UNTRUSTED KEYS:" +msgstr "" + +#: ../lib/rpmchecksig.c:335 ../lib/rpmchecksig.c:349 +msgid ")" +msgstr "" + +#: ../lib/rpmchecksig.c:343 +msgid "OK" +msgstr "" + #: ../lib/rpmdb.c:164 #, c-format msgid "opening database mode 0x%x in %s\n" diff --git a/rpm.c b/rpm.c index d5c6cc4..44dfec9 100755 --- a/rpm.c +++ b/rpm.c @@ -3,7 +3,6 @@ #include "build/rpmbuild.h" #include "build.h" -#include "checksig.h" #include "install.h" #include "lib/signature.h" #include "popt/popt.h" @@ -1161,7 +1160,7 @@ int main(int argc, char ** argv) if (!noPgp) checksigFlags |= CHECKSIG_PGP; if (!noGpg) checksigFlags |= CHECKSIG_GPG; if (!noMd5) checksigFlags |= CHECKSIG_MD5; - ec = doCheckSig(checksigFlags, poptGetArgs(optCon)); + ec = rpmCheckSig(checksigFlags, poptGetArgs(optCon)); /* XXX don't overflow single byte exit status */ if (ec > 255) ec = 255; exit(ec); @@ -1170,7 +1169,7 @@ int main(int argc, char ** argv) case MODE_RESIGN: if (!poptPeekArg(optCon)) argerror(_("no packages given for signing")); - ec = doReSign(addSign, passPhrase, poptGetArgs(optCon)); + ec = rpmReSign(addSign, passPhrase, poptGetArgs(optCon)); /* XXX don't overflow single byte exit status */ if (ec > 255) ec = 255; exit(ec); diff --git a/url.h b/url.h deleted file mode 100644 index 6a91155..0000000 --- a/url.h +++ /dev/null @@ -1,53 +0,0 @@ -#ifndef H_URL -#define H_URL - -typedef enum { - URL_IS_UNKNOWN = 0, - URL_IS_DASH = 1, - URL_IS_PATH = 2, - URL_IS_FTP = 3, - URL_IS_HTTP = 4 -} urltype; - -typedef struct urlinfo { - const char *url; /* copy of original url */ - const char *service; - const char *user; - const char *password; - const char *host; - const char *portstr; - const char *path; - const char *proxyu; /* FTP: proxy user */ - const char *proxyh; /* FTP/HTTP: proxy host */ - int proxyp; /* FTP/HTTP: proxy port */ - int port; - int ftpControl; - int ftpGetFileDoneNeeded; - int openError; /* Type of open failure */ -} urlinfo; - -#ifndef IPPORT_HTTP -#define IPPORT_HTTP 80 -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -urltype urlIsURL(const char * url); -int urlSplit(const char *url, urlinfo **u); -urlinfo *newUrlinfo(void); -void freeUrlinfo(urlinfo *u); - -FD_t ufdOpen(const char * pathname, int flags, mode_t mode); -int ufdClose(FD_t fd); -const char *urlStrerror(const char *url); - -int urlGetFile(const char * url, const char * dest); -void urlInvalidateCache(const char * url); - -#ifdef __cplusplus -} -#endif - -#endif -- 2.7.4