aboutsummaryrefslogtreecommitdiffhomepage
path: root/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus
diff options
context:
space:
mode:
Diffstat (limited to 'Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus')
-rwxr-xr-xFirestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/ConvertTextToBinary.sh61
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/arr-strings-0116
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-0123
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-0247
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-0391
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-0115
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-0215
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0115
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0215
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0315
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0415
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0515
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0615
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0715
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0815
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-0915
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0115
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0215
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0315
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0415
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0515
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0615
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-0715
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-0120
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-0224
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-0115
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-0215
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-0315
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-0415
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-0515
-rw-r--r--Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-0615
31 files changed, 642 insertions, 0 deletions
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/ConvertTextToBinary.sh b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/ConvertTextToBinary.sh
new file mode 100755
index 0000000..772e858
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/ConvertTextToBinary.sh
@@ -0,0 +1,61 @@
+#!/bin/bash
+
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Converts text protos to binary protos. Text protos are retrieved from the
+# folder defined by SCRIPT_INPUT_FILE_0 and the generated binary protos are
+# stored in the folder defined by SCRIPT_OUTPUT_FILE_0. Both SCRIPT_INPUT_FILE_0
+# and SCRIPT_OUTPUT_FILE_0 are defined in the Run Script Build Phase of the
+# XCode build target Firestore_FuzzTests_iOS that executes this script. XCode
+# defines these environment variables and makes them available to the script.
+
+# Directory that contains the text protos to convert to binary protos.
+text_protos_dir="${SCRIPT_INPUT_FILE_0}"
+
+# Create a folder to write binary protos to. This is our corpus.
+binary_protos_dir="${SCRIPT_OUTPUT_FILE_0}"
+mkdir -p "${binary_protos_dir}"
+
+echo "Converting text proto files in directory: $text_protos_dir"
+echo "Writing binary proto files to directory: $binary_protos_dir"
+
+# Run proto conversion command for each file content.
+for text_proto_file in "${text_protos_dir}"/*; do
+ file_name="$(basename -- "${text_proto_file}")"
+ file_content="$(cat "${text_proto_file}")"
+
+ # Choose an appropriate message type depending on the prefix of the file.
+ message_type="Value"
+ if [[ "${file_name}" == doc-* ]]; then
+ message_type="Document"
+ elif [[ "${file_name}" == fv-* ]]; then
+ message_type="Value"
+ elif [[ "${file_name}" == arr-* ]]; then
+ message_type="ArrayValue"
+ elif [[ "${file_name}" == map-* ]]; then
+ message_type="MapValue"
+ fi
+
+ # Run the conversion.
+ # TODO(minafarid): This conversion relies on protoc as built by the cmake
+ # build. Switch this to using a pod dependency of protoc.
+ echo "Converting file: ${file_name} (type: ${message_type})"
+ echo "${file_content}" \
+ | "${SRCROOT}/../../build/external/protobuf/src/protobuf-build/src/protoc" \
+ -I"${SRCROOT}/../../Firestore/Protos/protos" \
+ -I"${SRCROOT}/../../build/external/protobuf/src/protobuf/src" \
+ --encode=google.firestore.v1beta1."${message_type}" \
+ google/firestore/v1beta1/document.proto > "${binary_protos_dir}/${file_name}"
+done
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/arr-strings-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/arr-strings-01
new file mode 100644
index 0000000..f67b8c6
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/arr-strings-01
@@ -0,0 +1,16 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+values: { string_value: "hi" }
+values: { string_value: "hello" }
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-01
new file mode 100644
index 0000000..0255568
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-01
@@ -0,0 +1,23 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+name: "doc-01"
+fields: {
+ key: "a",
+ value: { string_value: "a_value" }
+}
+fields: {
+ key: "b"
+ value: { boolean_value: true }
+}
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-02 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-02
new file mode 100644
index 0000000..3177c9a
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-02
@@ -0,0 +1,47 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+name: "doc-02"
+fields: {
+ key: "a",
+ value: { integer_value: 99882 }
+}
+fields: {
+ key: "b"
+ value: { boolean_value: false }
+}
+fields: {
+ key: "c"
+ value: { double_value: 92.22 }
+}
+fields: {
+ key: "d"
+ value: { string_value: "92.22" }
+}
+fields: {
+ key: "e"
+ value: { array_value: {
+ values: { string_value: "hi" }
+ values: { string_value: "hello" }
+ }
+ }
+}
+fields: {
+ key: "f"
+ value: { array_value: {
+ values: { integer_value: 10 }
+ values: { integer_value: 11 }
+ }
+ }
+}
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-03 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-03
new file mode 100644
index 0000000..cac02ca
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/doc-03
@@ -0,0 +1,91 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+name: "doc-03 has a long name with spaces"
+fields: {
+ key: "a1",
+ value: { integer_value: 100000000 }
+}
+fields: {
+ key: "a2",
+ value: { integer_value: 31432432 }
+}
+fields: {
+ key: "a3",
+ value: { double_value: -123123.913 }
+}
+fields: {
+ key: "a4",
+ value: { integer_value: 454365464 }
+}
+fields: {
+ key: "a5",
+ value: { double_value: 123.54536 }
+}
+fields: {
+ key: "b1"
+ value: { boolean_value: false }
+}
+fields: {
+ key: "b2"
+ value: { boolean_value: true }
+}
+fields: {
+ key: "c"
+ value: { reference_value: "some reference string with spaces" }
+}
+fields: {
+ key: "d"
+ value: { string_value: "92.22" }
+}
+fields: {
+ key: "e1"
+ value: { array_value: {
+ values: { string_value: "hi" }
+ values: { string_value: "hello" }
+ }
+ }
+}
+fields: {
+ key: "e1"
+ value: { array_value: {
+ values: { string_value: "hello" }
+ values: { string_value: "world" }
+ values: { string_value: "!" }
+ }
+ }
+}
+fields: {
+ key: "e2-mixed"
+ value: { array_value: {
+ values: { integer_value: 1 }
+ values: { double_value: 10.234 }
+ values: { string_value: "world" }
+ }
+ }
+}
+fields: {
+ key: "f1-map"
+ value: { map_value: {
+ fields {
+ key: "key_for_boolean"
+ value: { boolean_value: true }
+ }
+ fields {
+ key: "key_int"
+ value: { integer_value: 2344 }
+ }
+ }
+ }
+}
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-01
new file mode 100644
index 0000000..68f38e0
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-01
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+boolean_value: true
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-02 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-02
new file mode 100644
index 0000000..ff41ba0
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-boolean-02
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+boolean_value: false
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-01
new file mode 100644
index 0000000..05e5f36
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-01
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: 0.0
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-02 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-02
new file mode 100644
index 0000000..e96b15f
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-02
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: 0.1
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-03 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-03
new file mode 100644
index 0000000..4c383af
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-03
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: -0.1
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-04 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-04
new file mode 100644
index 0000000..fe125a7
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-04
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: 1.0
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-05 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-05
new file mode 100644
index 0000000..7ddaff1
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-05
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: -1.0
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-06 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-06
new file mode 100644
index 0000000..c5c520f
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-06
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: 100.5010203
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-07 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-07
new file mode 100644
index 0000000..5030860
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-07
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: -100.5010203
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-08 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-08
new file mode 100644
index 0000000..9fdbc34
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-08
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: 1321241987
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-09 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-09
new file mode 100644
index 0000000..a9642b7
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-double-09
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+double_value: -1321241987
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-01
new file mode 100644
index 0000000..2f7663b
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-01
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: 0
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-02 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-02
new file mode 100644
index 0000000..3bd5cec
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-02
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: 1
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-03 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-03
new file mode 100644
index 0000000..01fe651
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-03
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: -1
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-04 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-04
new file mode 100644
index 0000000..3bd5cec
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-04
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: 1
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-05 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-05
new file mode 100644
index 0000000..b1d090d
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-05
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: -1000000
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-06 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-06
new file mode 100644
index 0000000..4bc30db
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-06
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: 2147483647
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-07 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-07
new file mode 100644
index 0000000..53b69f5
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-int-07
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+integer_value: -2147483647
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-01
new file mode 100644
index 0000000..084e925
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-01
@@ -0,0 +1,20 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+map_value: {
+ fields: {
+ key: "a",
+ value: {string_value: "value for key a"}
+ }
+}
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-02 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-02
new file mode 100644
index 0000000..8d07094
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-map-02
@@ -0,0 +1,24 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+map_value: {
+ fields: {
+ key: "a-duplicate",
+ value: {integer_value: 123}
+ }
+ fields: {
+ key: "a-duplicate",
+ value: {integer_value: 324}
+ }
+}
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-01 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-01
new file mode 100644
index 0000000..0531a8f
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-01
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+string_value: "Hello"
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-02 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-02
new file mode 100644
index 0000000..d69f9e2
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-02
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+string_value: "a"
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-03 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-03
new file mode 100644
index 0000000..2e4135f
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-03
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+string_value: ""
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-04 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-04
new file mode 100644
index 0000000..f14d8eb
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-04
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+string_value: "this is a looooooooooooooong string"
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-05 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-05
new file mode 100644
index 0000000..49d42eb
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-05
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+string_value: "this is a loooooooooooooooooooooooooonger string that has no meaningful information."
diff --git a/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-06 b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-06
new file mode 100644
index 0000000..a2c858f
--- /dev/null
+++ b/Firestore/Example/FuzzTests/FuzzingResources/Serializer/Corpus/TextProtos/fv-string-06
@@ -0,0 +1,15 @@
+# Copyright 2018 Google
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+string_value: "Super long. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sit amet dictum sit amet justo donec. Vitae sapien pellentesque habitant morbi tristique senectus. Turpis egestas maecenas pharetra convallis posuere morbi. Id semper risus in hendrerit gravida rutrum. Quis auctor elit sed vulputate mi sit amet mauris commodo. At varius vel pharetra vel. Lobortis feugiat vivamus at augue eget arcu dictum varius. Et tortor at risus viverra adipiscing at in tellus. Tortor aliquam nulla facilisi cras fermentum odio."