Home
last modified time | relevance | path

Searched refs:data (Results 1 – 25 of 40) sorted by relevance

12

/nanopb-3.4.0/tests/fixed_count/
Dfixed_count_unittests.c22 msg_a.data[0] = 1; in main()
23 msg_a.data[0] = 2; in main()
24 msg_a.data[0] = 3; in main()
48 TEST(msg.data[0] == 0 && msg.data[1] == 1 && msg.data[2] == 2); in main()
70 msg_a.data[0].data[0] = 1; in main()
71 msg_a.data[0].data[1] = 2; in main()
72 msg_a.data[0].data[2] = 3; in main()
73 msg_a.data[1].data[0] = 4; in main()
74 msg_a.data[1].data[1] = 5; in main()
75 msg_a.data[1].data[2] = 6; in main()
[all …]
Dfixed_count.proto9 repeated int32 data = 1 [(nanopb).max_count = 3, (nanopb).fixed_count = true]; field
14 repeated Message1 data = 1 [(nanopb).max_count = 2, (nanopb).fixed_count = true]; field
/nanopb-3.4.0/tests/common/
Dunittestproto.proto6 repeated int32 data = 1 [(nanopb).max_count = 10]; field
10 repeated float data = 1 [(nanopb).max_count = 10]; field
14 required string data = 1 [(nanopb).max_length = 10]; field
18 required bytes data = 1 [(nanopb).max_size = 16]; field
23 // Nanopb does not care about the actual defined data type for callback
25 repeated int32 data = 1; field
/nanopb-3.4.0/tests/package_name/
DSConscript7 data = open(str(src)).read()
9 assert placeholder in data
10 data = data.replace(placeholder, 'package %s;' % pkgname)
11 open(str(dst), 'w').write(data)
23 data = open(str(source[0]), 'r').read()
27 data = data.replace(name, 'test_package_' + name)
29 open(str(target[0]), 'w').write(data)
/nanopb-3.4.0/tests/regression/issue_647/
Drepro.c7 const uint8_t data[] = {0x08, 0x08, 0x2d}; in main() local
11 pb_istream_t stream = pb_istream_from_buffer(data, sizeof(data)); in main()
/nanopb-3.4.0/tests/package_name_nanopb/
DSConscript7 data = open(str(src)).read()
9 assert placeholder in data
10 data = data.replace(placeholder, 'package foopkg;\n' +
13 open(str(dst), 'w').write(data)
25 data = open(str(source[0]), 'r').read()
29 data = data.replace(name, 'test_package_' + name)
31 open(str(target[0]), 'w').write(data)
/nanopb-3.4.0/tests/regression/issue_376/
Dtest_fixarray.c19 msg.submsg.data[0] = 0; in main()
20 msg.submsg.data[4] = 5; in main()
34 TEST(msg.submsg.data[0] == 0); in main()
35 TEST(msg.submsg.data[4] == 5); in main()
Dfixed_array.options1 SubMessage.data fixed_count:true,max_count:8
Dfixed_array.proto8 repeated int32 data = 1; field
/nanopb-3.4.0/tests/inline/
Dinline.expected1 pb_byte_t data\[32\];
3 pb_byte_t data\[64\];
Dinline.proto11 required bytes data = 1 [(nanopb).type = FT_INLINE, (nanopb).max_size = 32]; field
16 optional bytes data = 1 [(nanopb).type = FT_INLINE, (nanopb).max_size = 64]; field
Dinline_unittests.c16 TEST(sizeof(msg1.data) == 32); in main()
27 msg1.data[i] = i; in main()
48 msg2.data[i] = i; in main()
/nanopb-3.4.0/tests/fuzztest/
Dfuzztest.c51 static uint32_t xor32_checksum(const void *data, size_t len) in xor32_checksum() argument
53 const uint8_t *buf = (const uint8_t*)data; in xor32_checksum()
289 void do_roundtrips(const uint8_t *data, size_t size, bool expect_valid) in do_roundtrips() argument
295 …if (do_decode(data, size, sizeof(alltypes_static_AllTypes), alltypes_static_AllTypes_fields, 0, ex… in do_roundtrips()
297 do_roundtrip(data, size, sizeof(alltypes_static_AllTypes), alltypes_static_AllTypes_fields); in do_roundtrips()
298 …do_stream_decode(data, size, SIZE_MAX, sizeof(alltypes_static_AllTypes), alltypes_static_AllTypes_… in do_roundtrips()
299 do_callback_decode(data, size, true); in do_roundtrips()
304 …if (do_decode(data, size, sizeof(alltypes_proto3_static_AllTypes), alltypes_proto3_static_AllTypes… in do_roundtrips()
306 …do_roundtrip(data, size, sizeof(alltypes_proto3_static_AllTypes), alltypes_proto3_static_AllTypes_… in do_roundtrips()
307 …do_stream_decode(data, size, SIZE_MAX, sizeof(alltypes_proto3_static_AllTypes), alltypes_proto3_st… in do_roundtrips()
[all …]
DSConscript1 # Run a fuzz test to verify robustness against corrupted/malicious data.
12 data = open(str(src)).read()
14 assert placeholder in data
15 data = data.replace(placeholder, 'package %s;' % pkgname)
16 open(str(dst), 'w').write(data)
/nanopb-3.4.0/tests/regression/issue_569/
Da.proto6 string data = 1; field
10 oneof data { oneof
Db.proto8 oneof data { oneof
15 oneof data { oneof
/nanopb-3.4.0/tests/decode_unittests/
Ddecode_unittests.c309 && dest.data_count == 2 && dest.data[0] == 1 && dest.data[1] == 2)) in main()
311 … TEST(pb_decode(&s, IntegerArray_fields, &dest) && dest.data_count == 10 && dest.data[9] == 10) in main()
324 && dest.data_count == 1 && dest.data[0] == 1)) in main()
326 && dest.data_count == 10 && dest.data[0] == 1 && dest.data[9] == 10)) in main()
340 && dest.data_count == 1 && dest.data[0] == 1)) in main()
342 && dest.data_count == 1 && dest.data[0] == 1)) in main()
344 && dest.data_count == 1 && dest.data[0] == 1)) in main()
347 && dest.data_count == 1 && dest.data[0] == 1)) in main()
354 dest.data.funcs.decode = &callback_check; in main()
355 dest.data.arg = &ref; in main()
[all …]
/nanopb-3.4.0/docs/
Dsecurity.md7 decoding untrusted data. Naturally, if the attacker can modify the
17 Division of trusted and untrusted data
20 The following data is regarded as **trusted**. It must be under the
21 control of the application writer. Malicious data in these structures
34 The following data is regarded as **untrusted**. Invalid/malicious data
39 1. All data read from `pb_istream_t`.
49 untrusted data has been maliciously crafted:
64 - pointer fields will be either `NULL` or point to valid data
67 write incorrect data.)
83 carefully checked if they are used with untrusted data.
/nanopb-3.4.0/tests/regression/issue_172/submessage/
Dsubmessage.options1 submessage.data max_size: 16
Dsubmessage.proto3 required bytes data = 1; field
/nanopb-3.4.0/tests/site_scons/platforms/stm32/
Dstm32_ram.ld126 .data :
130 *(.data*)
133 /* preinit data */
139 /* init data */
147 /* finit data */
155 /* All data end */
192 /* Check if data + heap + stack exceeds RAM limit */
/nanopb-3.4.0/tests/message_sizes/
Dmessages2.proto8 required bytes data = 2 [(nanopb).max_size = 128]; field
/nanopb-3.4.0/tests/any_type/
Danytest.proto8 // The type_url field identifies the type of message, and the message data
15 // This does result in unnecessarily copying the data around, so for larger
/nanopb-3.4.0/tests/regression/issue_631/
Dsubmsg_callback.proto16 oneof data { oneof
/nanopb-3.4.0/tests/regression/issue_522/
Duenum.proto34 repeated Reading data = 3; field

12