<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gpgme/src/cJSON.c, branch gpgme-1.24.2</title>
<subtitle>GnuPG Made Easy.</subtitle>
<id>http://git.bktus.com/gpgfrontend/gpgme/atom?h=gpgme-1.24.2</id>
<link rel='self' href='http://git.bktus.com/gpgfrontend/gpgme/atom?h=gpgme-1.24.2'/>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/'/>
<updated>2021-06-14T17:51:28Z</updated>
<entry>
<title>core: New data flags "io-buffer-size" and "sensitive".</title>
<updated>2021-06-14T17:51:28Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2021-06-14T17:51:28Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=fde20940b5ca6986dc12215209e8858601bb0c2e'/>
<id>urn:sha1:fde20940b5ca6986dc12215209e8858601bb0c2e</id>
<content type='text'>
* src/data.c (_gpgme_data_release): Free buffers.
(gpgme_data_seek): Adjust from renamed fields.
(gpgme_data_set_flag): Implement new flags.
(_gpgme_data_inbound_handler): Allow the use of a malloced buffer.
(_gpgme_data_outbound_handler): Ditto.
* src/data.h (BUFFER_SIZE): Move out of the struct definition.
(struct gpgme_data): Remove pending filed and introduce inbound and
outbound fields.

* src/conversion.c (_gpgme_wipememory): New.  Taken from GnuPG.
* src/cJSON.c (wipememory): Use this here too.

* tests/run-decrypt.c (main): Add options "--large-buffers" and
"--sensitive".
--

GnuPG-bug-id: 5478
Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>Require at least libgpg-error 1.36</title>
<updated>2020-11-09T10:50:46Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2020-11-09T10:48:42Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=eb99e8c483a70764408868602ef322602e9e72ce'/>
<id>urn:sha1:eb99e8c483a70764408868602ef322602e9e72ce</id>
<content type='text'>
* configure.ac (NEED_GPG_ERROR_VERSION): Require 1.36.
* src/cJSON.c: Remove code for older version.
* src/engine.c (gpgme_get_engine_info): Ditto.
* src/gpgme-json.c: Ditto.
* src/op-support.c: Ditto.
* src/util.h: Ditto.
--

Libgpg-error 1.36 has been released more than 18 months ago so it is
time to avoid hacks and require this verion.  This will for example
help Kleopatra to support PIV cards and improves the gpgme-json.

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>json: Print "nan", "-inf", "inf" if needed.</title>
<updated>2019-06-04T08:56:48Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2019-06-04T08:56:48Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=f56c996318dfa1c9f0d10582b18c2fce10d24668'/>
<id>urn:sha1:f56c996318dfa1c9f0d10582b18c2fce10d24668</id>
<content type='text'>
* src/cJSON.c (print_number): Print NaN and INF.
--

GnuPG-bug-id: 4328
Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>json: Improve handling of large exponents in the JSON parsor.</title>
<updated>2019-06-04T08:42:40Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2019-06-04T08:42:40Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=fabe96126b4ed9c5e07b713813d7db26a02e5e5f'/>
<id>urn:sha1:fabe96126b4ed9c5e07b713813d7db26a02e5e5f</id>
<content type='text'>
* src/cJSON.c: Include stdint.h.
(parse_number): Avoid overflob in SUBSCALE and cap integer values.
--

GnuPG-bug-id: 4330
Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>json: Limit recursion depth</title>
<updated>2019-02-27T13:27:47Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@gnupg.org</email>
</author>
<published>2019-02-27T13:27:47Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=4a117859e7a512458ab78cfedfae0372805196b1'/>
<id>urn:sha1:4a117859e7a512458ab78cfedfae0372805196b1</id>
<content type='text'>
* src/cJSON.c (MAX_DEPTH): New. Maximum recursion depth.
(parse_value, parse_array, parse_object): Carry and check
depth argument.
(cJSON_ParseWithOpts): Initialize depth.

--
This fixes a stack overflow if we get weird recursive
json data.

GnuPG-Bug-Id: T4331
</content>
</entry>
<entry>
<title>core: Silence newer compiler warnings.</title>
<updated>2018-12-17T15:47:27Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2018-12-17T15:47:06Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=8b41fb08f00f01fe0dd8b2b5455d3422d97ddc60'/>
<id>urn:sha1:8b41fb08f00f01fe0dd8b2b5455d3422d97ddc60</id>
<content type='text'>
* configure.ac: Add -Wno-format-truncation and
  -Wno-sizeof-pointer-div.
* src/b64dec.c (_gpgme_b64dec_proc): Add fallthrough annotation.
* src/cJSON.c (parse_string): Ditto.
* src/gpgme-json.c (main): Ditto.
--

gcc 8 enables a couple of new warnings.  Some of them are useless for
us.  In particular:

  util.h:42:26: warning: division 'sizeof (char *) / sizeof (char)'
  does not compute the number of array elements [-Wsizeof-pointer-div]
  #define DIM(v) (sizeof(v)/sizeof((v)[0])) ^

  trustlist.c:101:22: note:
  in expansion of macro 'DIM' if (strlen (p) == DIM(item-&gt;keyid) - 1)

Which is a real standard way to use DIM, here the right hand side is
equivalent to sizeof but nevertheless it is correct.  Yes sir, we know
C.

The format string warnings I have seen were assuming that the time
structure returns valued out of scope - but if the system is that
broken, the s_n_printf catches this.

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>json: Wipe memory in cJSON_Delete</title>
<updated>2018-08-08T12:27:24Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2018-08-08T12:27:24Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=4dd1d0abd34a382d1cd67cabb737950a39cb3fdc'/>
<id>urn:sha1:4dd1d0abd34a382d1cd67cabb737950a39cb3fdc</id>
<content type='text'>
* src/cJSON.c (cJSON_Delete): Wipe memory on deletion.
</content>
</entry>
<entry>
<title>json: Only use calloc instead of malloc</title>
<updated>2018-08-08T12:25:28Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2018-08-08T12:25:28Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=fdc07b3ddc2f68e6fcb33703ea41126d0a841290'/>
<id>urn:sha1:fdc07b3ddc2f68e6fcb33703ea41126d0a841290</id>
<content type='text'>
* src/cJSON.c, src/gpgme-json.c (CALLOC_ONLY): New define
to change xmalloc / xtrymalloc to use calloc.

--
Some people consider malloc dangerous as it might allow an
information leak.
</content>
</entry>
<entry>
<title>json: Add checks when skipping byte</title>
<updated>2018-08-08T11:30:01Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2018-08-08T11:30:01Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=974a95db04f9cdea02867f0246445b4679517ba0'/>
<id>urn:sha1:974a95db04f9cdea02867f0246445b4679517ba0</id>
<content type='text'>
* src/cJSON.c (parse_string, cJSON_Minify): Check for
terminating NULL byte when skipping the byte after a an escaped
quote.
</content>
</entry>
<entry>
<title>json: Minor cleanups in cJSON.c</title>
<updated>2018-07-16T12:42:30Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2018-07-16T12:42:30Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=1933f5b8056b2671301379106cca4504c4187795'/>
<id>urn:sha1:1933f5b8056b2671301379106cca4504c4187795</id>
<content type='text'>
* src/cJSON.c: Add comments on the origin of the code.
(parse_string): Allocate an extra byte for safeness.
(cJSON_AddItemToArray): Allo ARRAY to be NULL.

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
</feed>
