1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-22 10:19:57 +01:00
Werner Koch 35db798c2d
common: Make openpgp_oid_to_str more robust.
* common/openpgp-oid.c (openpgp_oid_to_str): Take care of
gcry_mpi_get_opaque returning NULL.  Remove useless condition !BUF.
--

It is possible that an opaque MPI stores just a NULL pointer.  Take
care of that before incrementing the pointer.  We return an error in
this case because at least a length byte is required.

Found due to hint from stack 0.3:

  bug: anti-simplify
  model: |
    %tobool15 = icmp ne i8* %incdec.ptr, null, !dbg !567
    -->  true
  stack:
    - /home/wk/s/gnupg/common/openpgp-oid.c:220:0
  ncore: 1
  core:
    - /home/wk/s/gnupg/common/openpgp-oid.c:212:0
      - pointer overflow

Signed-off-by: Werner Koch <wk@gnupg.org>
2015-03-15 12:07:21 +01:00
..
2015-02-03 09:12:45 +01:00
2007-07-04 19:49:40 +00:00
2013-11-18 14:09:47 +01:00
2014-12-08 17:12:23 +01:00
2011-02-04 12:57:53 +01:00
2007-07-04 19:49:40 +00:00
2015-02-26 18:15:10 +01:00
2013-01-30 18:51:56 +01:00
2014-11-11 15:14:31 +01:00
2014-11-11 15:14:31 +01:00
2014-11-11 15:14:31 +01:00
2014-11-11 10:13:10 +01:00
2014-05-02 11:19:25 +02:00
2014-01-29 17:45:05 +01:00
2013-07-31 16:25:41 +02:00
2015-02-03 09:12:45 +01:00
2011-02-04 12:57:53 +01:00
2014-04-17 21:09:10 +02:00

Stuff used by several modules of GnuPG.

These directories use it:

gpg
sm
agent

These directories don't use it:

kbx