Max Bruckner
3b0d37faf3
Change name from Configuration to Context
2018-02-03 16:45:10 +01:00
Max Bruckner
a0aa2df75a
cJSON_ConfigurationChangeParseEnd -> cJSON_ConfigurationGetParseEnd
...
This is probably a better approach than potentially having a pointer
that points to garbage on the stack and gets written to by cJSON.
2018-02-03 16:42:58 +01:00
Max Bruckner
ba81437601
cJSON_CreateConfig: Don't allow configuration, always use default
2018-02-03 16:42:58 +01:00
Max Bruckner
0474d4d85f
cJSON_ConfigurationChangeParseEnd
...
Add a pointer to an end position of parsing to the cJSON_Configuration
object. (Essentially like return_parse_end, but as offset instead of
pointer).
2018-02-03 16:42:56 +01:00
Max Bruckner
440ba84d08
Add cJSON_Allocators new style allocator struct
2018-02-03 16:42:56 +01:00
Max Bruckner
69f8bb7778
default_configuration: Macro for the internal_configuration defaults
2018-02-03 16:40:49 +01:00
Max Bruckner
99ad8cc64b
internal_configuration: Add case_sensitive
2018-02-03 16:40:49 +01:00
Max Bruckner
47f4337604
cJSON_ParseWithOpts: Extract pasrse with internal_configuration
...
Also introduces a allow_data_after_json property in the internal
configuration.
2018-02-03 16:40:49 +01:00
Max Bruckner
04137f4ed1
Put buffer_size into internal_configuration
2018-02-03 16:40:48 +01:00
Max Bruckner
479909d0a6
Put format into internal_configuration
2018-02-03 16:40:48 +01:00
Max Bruckner
b277cd6a24
Rename internal_hooks -> internal_configuration, cJSON_New_item -> create_item
2018-02-03 16:40:48 +01:00
Max Bruckner
deca87b071
is_nan and is_infinity macros
2018-01-20 15:45:21 +01:00
Max Bruckner
11844dd5a6
Add cJSON_Create{Array,Object}Reference
2017-11-28 03:06:02 +01:00
Max Bruckner
eaa90a6b74
Add cJSON_CreateStringReference
2017-11-28 02:02:55 +01:00
Max Bruckner
b2afbd3c9f
cJSON_GetStringValue
2017-11-15 18:47:49 +01:00
Max Bruckner
97d7347a6e
Merge branch 'develop'
2017-10-08 22:05:02 +02:00
Max Bruckner
954d61e5e7
Fix #189 , ensure returns an invalid pointer
...
If realloc returns NULL, ensure didn't abort but returned
printbuffer.offset instead. If an attacker can control
printbuffer.offset and also make realloc fail at just the right moment,
this would make cJSON potentially write at an arbitrary memory address.
2017-07-12 23:02:31 +02:00
Max Bruckner
5baa77f86c
cJSON_Parse{,WithOpts}: Skip UTF-8 (Byte Order Marks)
2017-07-03 22:28:04 +02:00
Max Bruckner
bdd5ff7ad6
misc_tests: Call all functions with NULL pointers
2017-06-28 14:22:42 +02:00
Max Bruckner
9ecc96878f
fix #174 : cJSON_ReplaceItemInObject doesn't copy name
2017-05-22 22:55:05 +02:00
Max Bruckner
8b953d1202
Add cJSON_ReplaceItemViaPointer
2017-05-02 01:18:55 +02:00
Max Bruckner
c24c3e0285
Add cJSON_DetachItemViaPointer
2017-05-01 23:58:04 +02:00
Max Bruckner
28570ad095
Add test for cJSON_SetNumberHelper
2017-04-28 14:41:24 +02:00
Max Bruckner
e0d3a8a265
Limit nesting depth to 1000 and make it configurable.
2017-04-27 01:57:45 +02:00
Max Bruckner
c45dc12fd7
Tests for typecheck functions
2017-02-26 21:54:01 +01:00
Max Bruckner
56b819bfbc
tests: test cJSON_GetObjectItem and cJSON_GetObjectItemCaseSensitive
2017-02-21 11:17:08 +01:00
Max Bruckner
cbbcc91498
tests: cJSON_ArrayForEach
2017-02-21 09:17:49 +01:00