Re: [Rpm-maint] [rpm-software-management/rpm] Rpm spits informative garbage to stdout instead of stderr (#962)

2021-10-11 Thread Demi Marie Obenour
> Exit code sanity come to mind as a related thing. Does that include exiting with a non-zero status if an I/O error occurs? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub:

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Demi Marie Obenour
@DemiMarie requested changes on this pull request. At a minimum, there needs to be a check for signature type in the code that verifies package signatures, now that such signatures will no longer be automatically rejected. > +return rc; +} + +static int pgpVerifySelf(pgpDigParams key,

Re: [Rpm-maint] [rpm-software-management/rpm] Print that package is not installed into stderr (#1794)

2021-10-11 Thread mikhailnov
I don't think that many things parse output of rpm -q, because it gives a correct exit code, but maybe I am too optimistic -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub:

Re: [Rpm-maint] [rpm-software-management/rpm] Require package names to be valid provides (#1778)

2021-10-11 Thread ニール・ゴンパ
@Conan-Kudo approved this pull request. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1778#pullrequestreview-776065643___

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > + (pkt->blen >> 24), + (pkt->blen >> 16), + (pkt->blen >> 8), + (pkt->blen ), +}; +rpmDigestUpdate(hash, head, 5); +rpmDigestUpdate(hash, pkt->body, pkt->blen); +} + +static int pgpVerifySelf(pgpDigParams key,

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai pushed 3 commits. 46c45e9a25fe151e8f7dee055356d398e163fb69 Process MPI's from all kinds of signatures 26424121e1aee51d7acf25ade18caeb1c976f364 Refactor pgpDigParams construction to helper function 1dcfa3c00f61594763418da701bea194972f3fac Validate self-signatures and require subkey

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Michael Schroeder
@mlschroe commented on this pull request. > } } - if (pgpPrtPkt(, digp)) + if (digp->tag == PGPTAG_PUBLIC_KEY && pkt->tag == PGPTAG_SIGNATURE) + selfsig = pgpDigParamsNew(pkt->tag); Maybe it's me ;) My point is that selfsig will also be set for

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > } } - if (pgpPrtPkt(, digp)) + if (digp->tag == PGPTAG_PUBLIC_KEY && pkt->tag == PGPTAG_SIGNATURE) + selfsig = pgpDigParamsNew(pkt->tag); I may be Monday dense here, but I fail to see the problem. -- You

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > + (pkt->blen >> 24), + (pkt->blen >> 16), + (pkt->blen >> 8), + (pkt->blen ), +}; +rpmDigestUpdate(hash, head, 5); +rpmDigestUpdate(hash, pkt->body, pkt->blen); +} + +static int pgpVerifySelf(pgpDigParams key,

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Michael Schroeder
@mlschroe commented on this pull request. > + (pkt->blen >> 24), + (pkt->blen >> 16), + (pkt->blen >> 8), + (pkt->blen ), +}; +rpmDigestUpdate(hash, head, 5); +rpmDigestUpdate(hash, pkt->body, pkt->blen); +} + +static int pgpVerifySelf(pgpDigParams key,

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Michael Schroeder
@mlschroe commented on this pull request. > } } - if (pgpPrtPkt(, digp)) + if (digp->tag == PGPTAG_PUBLIC_KEY && pkt->tag == PGPTAG_SIGNATURE) + selfsig = pgpDigParamsNew(pkt->tag); Sure, but that's a problem as the signature checking code below is

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > + (pkt->blen >> 24), + (pkt->blen >> 16), + (pkt->blen >> 8), + (pkt->blen ), +}; +rpmDigestUpdate(hash, head, 5); +rpmDigestUpdate(hash, pkt->body, pkt->blen); +} + +static int pgpVerifySelf(pgpDigParams key,

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > if (pkttype == PGPTAG_SIGNATURE) break; + + if (alloced < i) { :facepalm: Thanks for spotting, the '<' is a remnant from a different version where it was the right thing, but wrong here of course. -- You are receiving this

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > break; + if (pkt->tag == PGPTAG_PUBLIC_SUBKEY) + expect = PGPTAG_SIGNATURE; It'd be good to differentiate between verified and non-verified somehow though. -- You are receiving this because you are subscribed to this

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > break; + if (pkt->tag == PGPTAG_PUBLIC_SUBKEY) + expect = PGPTAG_SIGNATURE; I considered that, but it'd be against the spec: > Immediately following each User ID packet, there are zero or more Signature > packets. --

Re: [Rpm-maint] [rpm-software-management/rpm] Validate self-signatures and require subkey bindings on PGP public keys (#1788)

2021-10-11 Thread Panu Matilainen
@pmatilai commented on this pull request. > } } - if (pgpPrtPkt(, digp)) + if (digp->tag == PGPTAG_PUBLIC_KEY && pkt->tag == PGPTAG_SIGNATURE) + selfsig = pgpDigParamsNew(pkt->tag); https://datatracker.ietf.org/doc/html/rfc4880#section-11.1 says: >

Re: [Rpm-maint] [rpm-software-management/rpm] Print that package is not installed into stderr (#1794)

2021-10-11 Thread Panu Matilainen
NAK, package not being installed is not an error, it's just a state. The actual problem is that rpm outputs all these "helpful" and "informative" messages to stdout instead of stderr and changing this is much harder than it should be, see #962. -- You are receiving this because you are

Re: [Rpm-maint] [rpm-software-management/rpm] Print that package is not installed into stderr (#1794)

2021-10-11 Thread Panu Matilainen
Closed #1794. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/pull/1794#event-5441119429___ Rpm-maint mailing list