RPM Package Manager, CVS Repository
  http://rpm5.org/cvs/
  ____________________________________________________________________________

  Server: rpm5.org                         Name:   Jeff Johnson
  Root:   /v/rpm/cvs                       Email:  j...@rpm5.org
  Module: rpm                              Date:   15-Apr-2016 20:09:59
  Branch: rpm-5_4                          Handle: 2016041518095900

  Modified files:           (Branch: rpm-5_4)
    rpm/rpmio               rpmhkp.c

  Log:
    - rpmpgp: fix: handle packet underruns.

  Summary:
    Revision    Changes     Path
    2.20.2.15   +3  -3      rpm/rpmio/rpmhkp.c
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: rpm/rpmio/rpmhkp.c
  ============================================================================
  $ cvs diff -u -r2.20.2.14 -r2.20.2.15 rpmhkp.c
  --- rpm/rpmio/rpmhkp.c        10 Apr 2016 22:19:57 -0000      2.20.2.14
  +++ rpm/rpmio/rpmhkp.c        15 Apr 2016 18:09:59 -0000      2.20.2.15
  @@ -184,15 +184,15 @@
       const rpmuint8_t * p = h;
       const rpmuint8_t * pend = h + hlen;
       unsigned plen = 0;
  -    unsigned len;
  +    unsigned lenlen;
       rpmuint8_t stag;
   
       if (tlenp)
        *tlenp = 0;
   
       while (p < pend) {
  -     len = pgpLen(p, &plen);
  -     p += len;
  +     lenlen = pgpLen(p, (pend-p), &plen);
  +     p += lenlen;
   
        stag = (*p & ~PGPSUBTYPE_CRITICAL);
   
  @@ .
______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
CVS Sources Repository                                rpm-cvs@rpm5.org

Reply via email to