Merge github.com:grpc/grpc into optionalize_roundrobin

pull/6000/head
Craig Tiller 9 years ago
commit 5dd4118308
  1. 152
      Makefile
  2. 82
      build.yaml
  3. 38
      src/core/ext/transport/chttp2/transport/hpack_parser.c
  4. 24
      src/core/ext/transport/chttp2/transport/hpack_table.c
  5. 16
      src/core/lib/http/parser.c
  6. 7
      src/core/lib/json/json_reader.c
  7. 5
      templates/Makefile.template
  8. 4
      templates/tools/dockerfile/clang_update.include
  9. 43
      templates/tools/dockerfile/test/fuzzer/Dockerfile.template
  10. 44
      templates/tools/fuzzer/runners.template
  11. 2
      templates/vsprojects/buildtests_c.sln.template
  12. 2
      templates/vsprojects/grpc.sln.template
  13. 2
      templates/vsprojects/vcxproj.template
  14. 1
      test/core/client_config/uri_corpus/042dc4512fa3d391c5170cf3aa61e6a638f84342
  15. 1
      test/core/client_config/uri_corpus/0e9bbe975f2027e8c39c89f85f667530368e7d11
  16. 1
      test/core/client_config/uri_corpus/14b57bcbf1e17b1db1de491ef2ba3768f704b7dc
  17. 2
      test/core/client_config/uri_corpus/1794310671a060eead6e5ee66ac978a18ec7e84f
  18. 1
      test/core/client_config/uri_corpus/1d30b2a79afbaf2828ff42b9a9647e942ba1ab80
  19. 3
      test/core/client_config/uri_corpus/1fcf5d9c333b70596cf5ba04d1f7affdf445b971
  20. 1
      test/core/client_config/uri_corpus/23162c8a8936e20b195404c21337ee734d02a6bc
  21. 1
      test/core/client_config/uri_corpus/23f3198b815ca60bdadcaae682b9f965dda387f1
  22. 2
      test/core/client_config/uri_corpus/2ef3893b43f1f60b77b59ce06a6bce9815d78eaf
  23. 1
      test/core/client_config/uri_corpus/356c3c129e203b5c74550b4209764d74b9caefce
  24. 4
      test/core/client_config/uri_corpus/3b58860f3451d3e7aad99690a8d39782ca5116fc
  25. 1
      test/core/client_config/uri_corpus/47b5228404451fc9d4071fa69192514bb4ce33c1
  26. 4
      test/core/client_config/uri_corpus/636c5606fc23713a1bae88c8899c0541cfad4fd8
  27. 1
      test/core/client_config/uri_corpus/63fe493b270b17426d77a27cbf3abac5b2c2794a
  28. 1
      test/core/client_config/uri_corpus/655300a902b62662296a8e46bfb04fbcb07182cb
  29. 1
      test/core/client_config/uri_corpus/6b70979a70a038ff6607d6cf85485ee95baf58e6
  30. 2
      test/core/client_config/uri_corpus/7314ab3545a7535a26e0e8aad67caea5534d68b1
  31. 1
      test/core/client_config/uri_corpus/884dcaee2908ffe5f12b65b8eba81016099c4266
  32. 2
      test/core/client_config/uri_corpus/96c8d266b7dc037288ef305c996608270f72e7fb
  33. 1
      test/core/client_config/uri_corpus/975536c71ade4800415a7e9c2f1b45c35a6d5ea8
  34. 1
      test/core/client_config/uri_corpus/99750aa67d30beaea8af565c829d4999aa8cb91b
  35. 1
      test/core/client_config/uri_corpus/a1f0f9b75bb354eb063d7cba4fcfa2d0b88d63de
  36. 1
      test/core/client_config/uri_corpus/a296eb3d1d436ed7df7195b10aa3c4de3896f98d
  37. 1
      test/core/client_config/uri_corpus/a8b8e66050b424f1b8c07d46f868199fb7f60e38
  38. 1
      test/core/client_config/uri_corpus/af55baf8c8855e563befdf1eefbcbd46c5ddb8d2
  39. 1
      test/core/client_config/uri_corpus/b3c0bf66c2bf5d24ef1daf4cc5a9d6d5bd0e8bfd
  40. 1
      test/core/client_config/uri_corpus/ceb4e2264ba7a8d5be47d276b37ec09489e00245
  41. 1
      test/core/client_config/uri_corpus/cf4395958f5bfb46fd6f535a39657d016c75114c
  42. 1
      test/core/client_config/uri_corpus/d46668372b7e20154a89409a7430a28e642afdca
  43. 1
      test/core/client_config/uri_corpus/d6fe7412a0a1d1c733160246f3fa425f4f97682a
  44. 1
      test/core/client_config/uri_corpus/dns.txt
  45. 4
      test/core/client_config/uri_corpus/ea02d9fea9bad5b89cf353a0169238f584177e71
  46. 1
      test/core/client_config/uri_corpus/ec4731dddf94ed3ea92ae4d5a71f145ab6e3f6ee
  47. 1
      test/core/client_config/uri_corpus/ed2f78646f19fc47dd85ff0877c232b71913ece2
  48. 2
      test/core/client_config/uri_corpus/f6889f4a6350fea1596a3adea5cdac02bd5d1ff3
  49. 1
      test/core/client_config/uri_corpus/f6f3bd030f0d321efe7c51ca3f057de23509af67
  50. 2
      test/core/client_config/uri_corpus/f97598cff03306af3c70400608fec47268b5075d
  51. 1
      test/core/client_config/uri_corpus/f9e1ec1fc642b575bc9955618b7065747f56b101
  52. 1
      test/core/client_config/uri_corpus/fe0630a3aeed2ec6f474f362e4c839478290d5c4
  53. 1
      test/core/client_config/uri_corpus/ipv4.txt
  54. 1
      test/core/client_config/uri_corpus/ipv6.txt
  55. 1
      test/core/client_config/uri_corpus/unix.txt
  56. 52
      test/core/client_config/uri_fuzzer_test.c
  57. 2
      test/core/http/corpus/0299ca2580e4398d170c4a336e0c33eb2cd9d427
  58. 2
      test/core/http/corpus/05e613853d64a9669ea3cf41b0de777dc24931ba
  59. 2
      test/core/http/corpus/069352518a1d1baa05f317c677d275cefda2ac97
  60. 2
      test/core/http/corpus/0925527c9358b1e10ec0f0387cd99f35204d9a34
  61. 4
      test/core/http/corpus/0c5b7c2569410b526605e308309a7f36574e530d
  62. 3
      test/core/http/corpus/0ef3d0a84360bb5ad66274f1226f5cb273ecdbcf
  63. 3
      test/core/http/corpus/1e1273f90187fdf5df3625764245610f86af6aa4
  64. 3
      test/core/http/corpus/1fbc57d118f3733287e9a9d808bb8947b3260e55
  65. 2
      test/core/http/corpus/24756c396bc72894fd720092bb6f9c03e66b469f
  66. 2
      test/core/http/corpus/276def41311933421ae7a9ee42e906c85b6a4d3f
  67. 2
      test/core/http/corpus/29daa75432381937fd005cb25e314e328de6e9f9
  68. 2
      test/core/http/corpus/2a75204bc492084ad853682f8de3fb137d5907bc
  69. 2
      test/core/http/corpus/2d34ba249b755a880525cf53c665633a5e359305
  70. 2
      test/core/http/corpus/33f4ea0c7ea27c37d8f95cfa64d282370efdafd2
  71. 4
      test/core/http/corpus/35554617ea6418bd43161fe9a2c337ed82d7ec5b
  72. 2
      test/core/http/corpus/35f0c561297cfc840ddaeebb9fc61091f4eadece
  73. 3
      test/core/http/corpus/3953688866ccb3b4f371f1a858570d6afdb6452d
  74. 2
      test/core/http/corpus/39b19c41ba537f37511eff7727733715db432e76
  75. 3
      test/core/http/corpus/3e3c4756d5e40b5aa250954cbac86b826e70a7ac
  76. 2
      test/core/http/corpus/3f03265921120c6ffa61b944e213e062a5538d4b
  77. 2
      test/core/http/corpus/3fb034e66ee5494a67acae1b4e6ff64ba92a2046
  78. 4
      test/core/http/corpus/466059ed07a0d55d6ad5e522c7d367cbf278eaf9
  79. 2
      test/core/http/corpus/487725eb38511c79a9340bf4560a1411061fa6fa
  80. 2
      test/core/http/corpus/48b9b205cae8ac21512a3f26f49fd53e21ee13c5
  81. 2
      test/core/http/corpus/4b1f1f79a0bfa3f942479dd5f8edb59a7c257c55
  82. 3
      test/core/http/corpus/5028c56a5116a186b7343ff59567b47347a0796d
  83. 4
      test/core/http/corpus/533f62b3f495ce704babf3ee8d840f196a714dff
  84. 2
      test/core/http/corpus/5892cbb284771fc9761caae37b19cd6e27dbc104
  85. 2
      test/core/http/corpus/5aeab6e4f7c2a1c09d4ac0dbdb3beac4893607ee
  86. 2
      test/core/http/corpus/5b6292bdf009b0daecbc90b85cca30a88c36eec5
  87. 2
      test/core/http/corpus/5c1659b77678b41faa4fa13df7772dae3238d1c0
  88. 2
      test/core/http/corpus/5c81f61621e29ec9c6a64ac3af9b3b216141618e
  89. 3
      test/core/http/corpus/657368df512ca6294b9df16adf935a3f374a8be2
  90. 5
      test/core/http/corpus/7fc4520094902ce2c760d70eaad5b674d2817337
  91. 2
      test/core/http/corpus/81f59a12b458ec3604035cb962165c604d1355e6
  92. 4
      test/core/http/corpus/8f41c50e88ee8c17ecad3d41d63d38fb12aca0b9
  93. 2
      test/core/http/corpus/97c16de7fe3c390a2e6c09ff5c28f17d5c67542c
  94. 3
      test/core/http/corpus/97e4499d450c95660de86747f527e670f2012548
  95. 2
      test/core/http/corpus/9a996857196e0998a1278994a9bab3d35526e7f1
  96. 3
      test/core/http/corpus/9b7e00049ec356ecd84b1747e4e1941140139ae8
  97. 5
      test/core/http/corpus/9f0c38ec455cc363369b3674a2d32bc21c206de1
  98. 3
      test/core/http/corpus/a1dc7bc235e46eb21d91084d7b52d5ff9f45df85
  99. 2
      test/core/http/corpus/aa3bbb876eafa8ad8ca4ff2eabc6dd94341d2441
  100. 2
      test/core/http/corpus/b04fea5c041c707db0ad9c09a81672557b52cc47
  101. Some files were not shown because too many files have changed in this diff Show More

@ -95,6 +95,16 @@ LDXX_opt = $(DEFAULT_CXX)
CPPFLAGS_opt = -O2
DEFINES_opt = NDEBUG
VALID_CONFIG_asan-trace-cmp = 1
REQUIRE_CUSTOM_LIBRARIES_asan-trace-cmp = 1
CC_asan-trace-cmp = clang
CXX_asan-trace-cmp = clang++
LD_asan-trace-cmp = clang
LDXX_asan-trace-cmp = clang++
CPPFLAGS_asan-trace-cmp = -O0 -fsanitize-coverage=edge -fsanitize-coverage=trace-cmp -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
LDFLAGS_asan-trace-cmp = -fsanitize=address
DEFINES_asan-trace-cmp += GRPC_TEST_SLOWDOWN_BUILD_FACTOR=3
VALID_CONFIG_dbg = 1
CC_dbg = $(DEFAULT_CC)
CXX_dbg = $(DEFAULT_CXX)
@ -109,7 +119,7 @@ CC_easan = clang
CXX_easan = clang++
LD_easan = clang
LDXX_easan = clang++
CPPFLAGS_easan = -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS_easan = -O0 -fsanitize-coverage=edge -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
LDFLAGS_easan = -fsanitize=address
DEFINES_easan = _DEBUG DEBUG GRPC_EXECUTION_CONTEXT_SANITIZER
DEFINES_easan += GRPC_TEST_SLOWDOWN_BUILD_FACTOR=3
@ -120,7 +130,7 @@ CC_asan = clang
CXX_asan = clang++
LD_asan = clang
LDXX_asan = clang++
CPPFLAGS_asan = -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS_asan = -O0 -fsanitize-coverage=edge -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
LDFLAGS_asan = -fsanitize=address
DEFINES_asan += GRPC_TEST_SLOWDOWN_BUILD_FACTOR=3
@ -130,7 +140,7 @@ CC_msan = clang
CXX_msan = clang++
LD_msan = clang
LDXX_msan = clang++
CPPFLAGS_msan = -O0 -fsanitize=memory -fsanitize-memory-track-origins -fno-omit-frame-pointer -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_USE_OWN_TR1_TUPLE=1 -Wno-unused-command-line-argument -fPIE -pie -DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS_msan = -O0 -fsanitize-coverage=edge -fsanitize=memory -fsanitize-memory-track-origins -fno-omit-frame-pointer -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_USE_OWN_TR1_TUPLE=1 -Wno-unused-command-line-argument -fPIE -pie -DGPR_NO_DIRECT_SYSCALLS
LDFLAGS_msan = -fsanitize=memory -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_USE_OWN_TR1_TUPLE=1 -fPIE -pie $(if $(JENKINS_BUILD),-Wl$(comma)-Ttext-segment=0x7e0000000000,)
DEFINES_msan = NDEBUG
DEFINES_msan += GRPC_TEST_SLOWDOWN_BUILD_FACTOR=4
@ -159,7 +169,7 @@ CC_asan-noleaks = clang
CXX_asan-noleaks = clang++
LD_asan-noleaks = clang
LDXX_asan-noleaks = clang++
CPPFLAGS_asan-noleaks = -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS_asan-noleaks = -O0 -fsanitize-coverage=edge -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
LDFLAGS_asan-noleaks = -fsanitize=address
DEFINES_asan-noleaks += GRPC_TEST_SLOWDOWN_BUILD_FACTOR=3
@ -177,7 +187,7 @@ CC_ubsan = clang
CXX_ubsan = clang++
LD_ubsan = clang
LDXX_ubsan = clang++
CPPFLAGS_ubsan = -O1 -fsanitize=undefined -fno-omit-frame-pointer -Wno-unused-command-line-argument
CPPFLAGS_ubsan = -O1 -fsanitize-coverage=edge -fsanitize=undefined -fno-omit-frame-pointer -Wno-unused-command-line-argument
LDFLAGS_ubsan = -fsanitize=undefined
DEFINES_ubsan = NDEBUG
DEFINES_ubsan += GRPC_TEST_SLOWDOWN_BUILD_FACTOR=1.5
@ -925,14 +935,17 @@ grpc_jwt_verifier_test: $(BINDIR)/$(CONFIG)/grpc_jwt_verifier_test
grpc_print_google_default_creds_token: $(BINDIR)/$(CONFIG)/grpc_print_google_default_creds_token
grpc_security_connector_test: $(BINDIR)/$(CONFIG)/grpc_security_connector_test
grpc_verify_jwt: $(BINDIR)/$(CONFIG)/grpc_verify_jwt
hpack_parser_fuzzer_test: $(BINDIR)/$(CONFIG)/hpack_parser_fuzzer_test
hpack_parser_test: $(BINDIR)/$(CONFIG)/hpack_parser_test
hpack_table_test: $(BINDIR)/$(CONFIG)/hpack_table_test
http_fuzzer_test: $(BINDIR)/$(CONFIG)/http_fuzzer_test
http_parser_test: $(BINDIR)/$(CONFIG)/http_parser_test
httpcli_format_request_test: $(BINDIR)/$(CONFIG)/httpcli_format_request_test
httpcli_test: $(BINDIR)/$(CONFIG)/httpcli_test
httpscli_test: $(BINDIR)/$(CONFIG)/httpscli_test
init_test: $(BINDIR)/$(CONFIG)/init_test
invalid_call_argument_test: $(BINDIR)/$(CONFIG)/invalid_call_argument_test
json_fuzzer_test: $(BINDIR)/$(CONFIG)/json_fuzzer_test
json_rewrite: $(BINDIR)/$(CONFIG)/json_rewrite
json_rewrite_test: $(BINDIR)/$(CONFIG)/json_rewrite_test
json_stream_error_test: $(BINDIR)/$(CONFIG)/json_stream_error_test
@ -966,6 +979,7 @@ transport_connectivity_state_test: $(BINDIR)/$(CONFIG)/transport_connectivity_st
transport_metadata_test: $(BINDIR)/$(CONFIG)/transport_metadata_test
transport_security_test: $(BINDIR)/$(CONFIG)/transport_security_test
udp_server_test: $(BINDIR)/$(CONFIG)/udp_server_test
uri_fuzzer_test: $(BINDIR)/$(CONFIG)/uri_fuzzer_test
uri_parser_test: $(BINDIR)/$(CONFIG)/uri_parser_test
workqueue_test: $(BINDIR)/$(CONFIG)/workqueue_test
alarm_cpp_test: $(BINDIR)/$(CONFIG)/alarm_cpp_test
@ -7788,6 +7802,38 @@ endif
endif
HPACK_PARSER_FUZZER_TEST_SRC = \
test/core/transport/chttp2/hpack_parser_fuzzer_test.c \
HPACK_PARSER_FUZZER_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(HPACK_PARSER_FUZZER_TEST_SRC))))
ifeq ($(NO_SECURE),true)
# You can't build secure targets if you don't have OpenSSL.
$(BINDIR)/$(CONFIG)/hpack_parser_fuzzer_test: openssl_dep_error
else
$(BINDIR)/$(CONFIG)/hpack_parser_fuzzer_test: $(HPACK_PARSER_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
$(E) "[LD] Linking $@"
$(Q) mkdir -p `dirname $@`
$(Q) $(LDXX) $(LDFLAGS) $(HPACK_PARSER_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -lFuzzer -o $(BINDIR)/$(CONFIG)/hpack_parser_fuzzer_test
endif
$(OBJDIR)/$(CONFIG)/test/core/transport/chttp2/hpack_parser_fuzzer_test.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
deps_hpack_parser_fuzzer_test: $(HPACK_PARSER_FUZZER_TEST_OBJS:.o=.dep)
ifneq ($(NO_SECURE),true)
ifneq ($(NO_DEPS),true)
-include $(HPACK_PARSER_FUZZER_TEST_OBJS:.o=.dep)
endif
endif
HPACK_PARSER_TEST_SRC = \
test/core/transport/chttp2/hpack_parser_test.c \
@ -7852,6 +7898,38 @@ endif
endif
HTTP_FUZZER_TEST_SRC = \
test/core/http/fuzzer.c \
HTTP_FUZZER_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(HTTP_FUZZER_TEST_SRC))))
ifeq ($(NO_SECURE),true)
# You can't build secure targets if you don't have OpenSSL.
$(BINDIR)/$(CONFIG)/http_fuzzer_test: openssl_dep_error
else
$(BINDIR)/$(CONFIG)/http_fuzzer_test: $(HTTP_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
$(E) "[LD] Linking $@"
$(Q) mkdir -p `dirname $@`
$(Q) $(LDXX) $(LDFLAGS) $(HTTP_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -lFuzzer -o $(BINDIR)/$(CONFIG)/http_fuzzer_test
endif
$(OBJDIR)/$(CONFIG)/test/core/http/fuzzer.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
deps_http_fuzzer_test: $(HTTP_FUZZER_TEST_OBJS:.o=.dep)
ifneq ($(NO_SECURE),true)
ifneq ($(NO_DEPS),true)
-include $(HTTP_FUZZER_TEST_OBJS:.o=.dep)
endif
endif
HTTP_PARSER_TEST_SRC = \
test/core/http/parser_test.c \
@ -8044,6 +8122,38 @@ endif
endif
JSON_FUZZER_TEST_SRC = \
test/core/json/fuzzer.c \
JSON_FUZZER_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(JSON_FUZZER_TEST_SRC))))
ifeq ($(NO_SECURE),true)
# You can't build secure targets if you don't have OpenSSL.
$(BINDIR)/$(CONFIG)/json_fuzzer_test: openssl_dep_error
else
$(BINDIR)/$(CONFIG)/json_fuzzer_test: $(JSON_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
$(E) "[LD] Linking $@"
$(Q) mkdir -p `dirname $@`
$(Q) $(LDXX) $(LDFLAGS) $(JSON_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -lFuzzer -o $(BINDIR)/$(CONFIG)/json_fuzzer_test
endif
$(OBJDIR)/$(CONFIG)/test/core/json/fuzzer.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
deps_json_fuzzer_test: $(JSON_FUZZER_TEST_OBJS:.o=.dep)
ifneq ($(NO_SECURE),true)
ifneq ($(NO_DEPS),true)
-include $(JSON_FUZZER_TEST_OBJS:.o=.dep)
endif
endif
JSON_REWRITE_SRC = \
test/core/json/json_rewrite.c \
@ -9100,6 +9210,38 @@ endif
endif
URI_FUZZER_TEST_SRC = \
test/core/client_config/uri_fuzzer_test.c \
URI_FUZZER_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(URI_FUZZER_TEST_SRC))))
ifeq ($(NO_SECURE),true)
# You can't build secure targets if you don't have OpenSSL.
$(BINDIR)/$(CONFIG)/uri_fuzzer_test: openssl_dep_error
else
$(BINDIR)/$(CONFIG)/uri_fuzzer_test: $(URI_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
$(E) "[LD] Linking $@"
$(Q) mkdir -p `dirname $@`
$(Q) $(LDXX) $(LDFLAGS) $(URI_FUZZER_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -lFuzzer -o $(BINDIR)/$(CONFIG)/uri_fuzzer_test
endif
$(OBJDIR)/$(CONFIG)/test/core/client_config/uri_fuzzer_test.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
deps_uri_fuzzer_test: $(URI_FUZZER_TEST_OBJS:.o=.dep)
ifneq ($(NO_SECURE),true)
ifneq ($(NO_DEPS),true)
-include $(URI_FUZZER_TEST_OBJS:.o=.dep)
endif
endif
URI_PARSER_TEST_SRC = \
test/core/client_config/uri_parser_test.c \

@ -1595,6 +1595,18 @@ targets:
- grpc
- gpr_test_util
- gpr
- name: hpack_parser_fuzzer_test
build: fuzzer
language: c
src:
- test/core/transport/chttp2/hpack_parser_fuzzer_test.c
deps:
- grpc_test_util
- grpc
- gpr_test_util
- gpr
corpus_dirs:
- test/core/transport/chttp2/hpack_parser_corpus
- name: hpack_parser_test
build: test
language: c
@ -1615,6 +1627,18 @@ targets:
- grpc
- gpr_test_util
- gpr
- name: http_fuzzer_test
build: fuzzer
language: c
src:
- test/core/http/fuzzer.c
deps:
- grpc_test_util
- grpc
- gpr_test_util
- gpr
corpus_dirs:
- test/core/http/corpus
- name: http_parser_test
build: test
language: c
@ -1683,6 +1707,18 @@ targets:
- grpc
- gpr_test_util
- gpr
- name: json_fuzzer_test
build: fuzzer
language: c
src:
- test/core/json/fuzzer.c
deps:
- grpc_test_util
- grpc
- gpr_test_util
- gpr
corpus_dirs:
- test/core/json/corpus
- name: json_rewrite
build: test
run: false
@ -2046,6 +2082,18 @@ targets:
- mac
- linux
- posix
- name: uri_fuzzer_test
build: fuzzer
language: c
src:
- test/core/client_config/uri_fuzzer_test.c
deps:
- grpc_test_util
- grpc
- gpr_test_util
- gpr
corpus_dirs:
- test/core/client_config/uri_corpus
- name: uri_parser_test
build: test
language: c
@ -2827,8 +2875,8 @@ vspackages:
configs:
asan:
CC: clang
CPPFLAGS: -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument
-DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS: -O0 -fsanitize-coverage=edge -fsanitize=address -fno-omit-frame-pointer
-Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CXX: clang++
LD: clang
LDFLAGS: -fsanitize=address
@ -2840,8 +2888,8 @@ configs:
timeout_multiplier: 3
asan-noleaks:
CC: clang
CPPFLAGS: -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument
-DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS: -O0 -fsanitize-coverage=edge -fsanitize=address -fno-omit-frame-pointer
-Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CXX: clang++
LD: clang
LDFLAGS: -fsanitize=address
@ -2850,6 +2898,19 @@ configs:
test_environ:
ASAN_OPTIONS: detect_leaks=0:color=always
timeout_multiplier: 3
asan-trace-cmp:
CC: clang
CPPFLAGS: -O0 -fsanitize-coverage=edge -fsanitize-coverage=trace-cmp -fsanitize=address
-fno-omit-frame-pointer -Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CXX: clang++
LD: clang
LDFLAGS: -fsanitize=address
LDXX: clang++
compile_the_world: true
test_environ:
ASAN_OPTIONS: detect_leaks=1:color=always
LSAN_OPTIONS: suppressions=tools/lsan_suppressions.txt:report_objects=1
timeout_multiplier: 3
basicprof:
CPPFLAGS: -O2 -DGRPC_BASIC_PROFILER -DGRPC_TIMERS_RDTSC
DEFINES: NDEBUG
@ -2858,8 +2919,8 @@ configs:
DEFINES: _DEBUG DEBUG
easan:
CC: clang
CPPFLAGS: -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-unused-command-line-argument
-DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS: -O0 -fsanitize-coverage=edge -fsanitize=address -fno-omit-frame-pointer
-Wno-unused-command-line-argument -DGPR_NO_DIRECT_SYSCALLS
CXX: clang++
DEFINES: _DEBUG DEBUG GRPC_EXECUTION_CONTEXT_SANITIZER
LD: clang
@ -2908,9 +2969,9 @@ configs:
valgrind: --tool=memcheck --leak-check=full
msan:
CC: clang
CPPFLAGS: -O0 -fsanitize=memory -fsanitize-memory-track-origins -fno-omit-frame-pointer
-DGTEST_HAS_TR1_TUPLE=0 -DGTEST_USE_OWN_TR1_TUPLE=1 -Wno-unused-command-line-argument
-fPIE -pie -DGPR_NO_DIRECT_SYSCALLS
CPPFLAGS: -O0 -fsanitize-coverage=edge -fsanitize=memory -fsanitize-memory-track-origins
-fno-omit-frame-pointer -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_USE_OWN_TR1_TUPLE=1
-Wno-unused-command-line-argument -fPIE -pie -DGPR_NO_DIRECT_SYSCALLS
CXX: clang++
DEFINES: NDEBUG
LD: clang
@ -2943,7 +3004,8 @@ configs:
timeout_multiplier: 5
ubsan:
CC: clang
CPPFLAGS: -O1 -fsanitize=undefined -fno-omit-frame-pointer -Wno-unused-command-line-argument
CPPFLAGS: -O1 -fsanitize-coverage=edge -fsanitize=undefined -fno-omit-frame-pointer
-Wno-unused-command-line-argument
CXX: clang++
DEFINES: NDEBUG
LD: clang

@ -52,6 +52,8 @@
#include "src/core/lib/profiling/timers.h"
#include "src/core/lib/support/string.h"
extern int grpc_http_trace;
typedef enum {
NOT_BINARY,
B64_BYTE0,
@ -723,7 +725,9 @@ static int finish_indexed_field(grpc_chttp2_hpack_parser *p, const uint8_t *cur,
const uint8_t *end) {
grpc_mdelem *md = grpc_chttp2_hptbl_lookup(&p->table, p->index);
if (md == NULL) {
gpr_log(GPR_ERROR, "Invalid HPACK index received: %d", p->index);
if (grpc_http_trace) {
gpr_log(GPR_ERROR, "Invalid HPACK index received: %d", p->index);
}
return 0;
}
GRPC_MDELEM_REF(md);
@ -919,7 +923,9 @@ static int parse_lithdr_nvridx_v(grpc_chttp2_hpack_parser *p,
/* finish parsing a max table size change */
static int finish_max_tbl_size(grpc_chttp2_hpack_parser *p, const uint8_t *cur,
const uint8_t *end) {
gpr_log(GPR_INFO, "MAX TABLE SIZE: %d", p->index);
if (grpc_http_trace) {
gpr_log(GPR_INFO, "MAX TABLE SIZE: %d", p->index);
}
return grpc_chttp2_hptbl_set_current_table_size(&p->table, p->index) &&
parse_begin(p, cur, end);
}
@ -960,7 +966,9 @@ static int parse_error(grpc_chttp2_hpack_parser *p, const uint8_t *cur,
static int parse_illegal_op(grpc_chttp2_hpack_parser *p, const uint8_t *cur,
const uint8_t *end) {
GPR_ASSERT(cur != end);
gpr_log(GPR_DEBUG, "Illegal hpack op code %d", *cur);
if (grpc_http_trace) {
gpr_log(GPR_DEBUG, "Illegal hpack op code %d", *cur);
}
return parse_error(p, cur, end);
}
@ -1069,10 +1077,12 @@ static int parse_value4(grpc_chttp2_hpack_parser *p, const uint8_t *cur,
}
error:
gpr_log(GPR_ERROR,
"integer overflow in hpack integer decoding: have 0x%08x, "
"got byte 0x%02x on byte 5",
*p->parsing.value, *cur);
if (grpc_http_trace) {
gpr_log(GPR_ERROR,
"integer overflow in hpack integer decoding: have 0x%08x, "
"got byte 0x%02x on byte 5",
*p->parsing.value, *cur);
}
return parse_error(p, cur, end);
}
@ -1094,10 +1104,12 @@ static int parse_value5up(grpc_chttp2_hpack_parser *p, const uint8_t *cur,
return parse_next(p, cur + 1, end);
}
gpr_log(GPR_ERROR,
"integer overflow in hpack integer decoding: have 0x%08x, "
"got byte 0x%02x sometime after byte 5",
*p->parsing.value, *cur);
if (grpc_http_trace) {
gpr_log(GPR_ERROR,
"integer overflow in hpack integer decoding: have 0x%08x, "
"got byte 0x%02x sometime after byte 5",
*p->parsing.value, *cur);
}
return parse_error(p, cur, end);
}
@ -1329,7 +1341,9 @@ static is_binary_header is_binary_literal_header(grpc_chttp2_hpack_parser *p) {
static is_binary_header is_binary_indexed_header(grpc_chttp2_hpack_parser *p) {
grpc_mdelem *elem = grpc_chttp2_hptbl_lookup(&p->table, p->index);
if (!elem) {
gpr_log(GPR_ERROR, "Invalid HPACK index received: %d", p->index);
if (grpc_http_trace) {
gpr_log(GPR_ERROR, "Invalid HPACK index received: %d", p->index);
}
return ERROR_HEADER;
}
return grpc_is_binary_header(

@ -41,6 +41,8 @@
#include "src/core/lib/support/murmur_hash.h"
extern int grpc_http_trace;
static struct {
const char *key;
const char *value;
@ -264,12 +266,16 @@ int grpc_chttp2_hptbl_set_current_table_size(grpc_chttp2_hptbl *tbl,
return 1;
}
if (bytes > tbl->max_bytes) {
gpr_log(GPR_ERROR,
"Attempt to make hpack table %d bytes when max is %d bytes", bytes,
tbl->max_bytes);
if (grpc_http_trace) {
gpr_log(GPR_ERROR,
"Attempt to make hpack table %d bytes when max is %d bytes",
bytes, tbl->max_bytes);
}
return 0;
}
gpr_log(GPR_DEBUG, "Update hpack parser table size to %d", bytes);
if (grpc_http_trace) {
gpr_log(GPR_DEBUG, "Update hpack parser table size to %d", bytes);
}
while (tbl->mem_used > bytes) {
evict1(tbl);
}
@ -293,10 +299,12 @@ int grpc_chttp2_hptbl_add(grpc_chttp2_hptbl *tbl, grpc_mdelem *md) {
GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD;
if (tbl->current_table_bytes > tbl->max_bytes) {
gpr_log(GPR_ERROR,
"HPACK max table size reduced to %d but not reflected by hpack "
"stream (still at %d)",
tbl->max_bytes, tbl->current_table_bytes);
if (grpc_http_trace) {
gpr_log(GPR_ERROR,
"HPACK max table size reduced to %d but not reflected by hpack "
"stream (still at %d)",
tbl->max_bytes, tbl->current_table_bytes);
}
return 0;
}

@ -39,6 +39,8 @@
#include <grpc/support/log.h>
#include <grpc/support/useful.h>
extern int grpc_http_trace;
static char *buf2str(void *buffer, size_t length) {
char *out = gpr_malloc(length + 1);
memcpy(out, buffer, length);
@ -72,7 +74,7 @@ static int handle_response_line(grpc_http_parser *parser) {
return 1;
error:
gpr_log(GPR_ERROR, "Failed parsing response line");
if (grpc_http_trace) gpr_log(GPR_ERROR, "Failed parsing response line");
return 0;
}
@ -125,7 +127,7 @@ static int handle_request_line(grpc_http_parser *parser) {
return 1;
error:
gpr_log(GPR_ERROR, "Failed parsing request line");
if (grpc_http_trace) gpr_log(GPR_ERROR, "Failed parsing request line");
return 0;
}
@ -150,7 +152,8 @@ static int add_header(grpc_http_parser *parser) {
GPR_ASSERT(cur != end);
if (*cur == ' ' || *cur == '\t') {
gpr_log(GPR_ERROR, "Continued header lines not supported yet");
if (grpc_http_trace)
gpr_log(GPR_ERROR, "Continued header lines not supported yet");
goto error;
}
@ -158,7 +161,7 @@ static int add_header(grpc_http_parser *parser) {
cur++;
}
if (cur == end) {
gpr_log(GPR_ERROR, "Didn't find ':' in header string");
if (grpc_http_trace) gpr_log(GPR_ERROR, "Didn't find ':' in header string");
goto error;
}
GPR_ASSERT(cur >= beg);
@ -249,8 +252,9 @@ static int addbyte(grpc_http_parser *parser, uint8_t byte) {
case GRPC_HTTP_FIRST_LINE:
case GRPC_HTTP_HEADERS:
if (parser->cur_line_length >= GRPC_HTTP_PARSER_MAX_HEADER_LENGTH) {
gpr_log(GPR_ERROR, "HTTP client max line length (%d) exceeded",
GRPC_HTTP_PARSER_MAX_HEADER_LENGTH);
if (grpc_http_trace)
gpr_log(GPR_ERROR, "HTTP client max line length (%d) exceeded",
GRPC_HTTP_PARSER_MAX_HEADER_LENGTH);
return 0;
}
parser->cur_line[parser->cur_line_length] = byte;

@ -280,13 +280,14 @@ grpc_json_reader_status grpc_json_reader_run(grpc_json_reader *reader) {
break;
case GRPC_JSON_STATE_OBJECT_KEY_STRING:
GPR_ASSERT(reader->unicode_high_surrogate == 0);
if (reader->unicode_high_surrogate != 0)
return GRPC_JSON_PARSE_ERROR;
if (c == '"') {
reader->state = GRPC_JSON_STATE_OBJECT_KEY_END;
json_reader_set_key(reader);
json_reader_string_clear(reader);
} else {
if (c <= 0x001f) return GRPC_JSON_PARSE_ERROR;
if (c < 32) return GRPC_JSON_PARSE_ERROR;
json_reader_string_add_char(reader, c);
}
break;
@ -362,6 +363,8 @@ grpc_json_reader_status grpc_json_reader_run(grpc_json_reader *reader) {
reader->in_object = 0;
reader->in_array = 1;
break;
default:
return GRPC_JSON_PARSE_ERROR;
}
break;

@ -1737,7 +1737,7 @@
$(LIBDIR)/$(CONFIG)/lib${dep}.a\
% endfor
% if tgt.language == "c++" or tgt.boringssl:
% if tgt.language == "c++" or tgt.boringssl or tgt.build == 'fuzzer':
## C++ targets specificies.
% if tgt.build == 'protoc':
$(E) "[HOSTLD] Linking $@"
@ -1790,6 +1790,9 @@
$(GTEST_LIB)\
% elif tgt.language == 'c++' and tgt.build == 'benchmark':
$(GTEST_LIB)\
% endif
% if tgt.build == 'fuzzer':
-lFuzzer\
% endif
-o $(BINDIR)/$(CONFIG)/${tgt.name}
% if tgt.build == 'protoc' or tgt.language == 'c++':

@ -1,5 +1,5 @@
#=================
# Update clang to a version with improved tsan
# Update clang to a version with improved tsan and fuzzing capabilities
RUN apt-get update && apt-get -y install python cmake && apt-get clean
@ -29,4 +29,4 @@ RUN cd llvm-build && cmake ${'\\'}
-DCMAKE_INSTALL_PREFIX:STRING=/usr ${'\\'}
-DLLVM_TARGETS_TO_BUILD:STRING=X86 ${'\\'}
../llvm
RUN make -C llvm-build && make -C llvm-build install && rm -rf llvm-build
RUN make -C llvm-build -j 12 && make -C llvm-build install && rm -rf llvm-build

@ -0,0 +1,43 @@
%YAML 1.2
--- |
# Copyright 2015-2016, Google Inc.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following disclaimer
# in the documentation and/or other materials provided with the
# distribution.
# * Neither the name of Google Inc. nor the names of its
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
FROM debian:jessie
<%include file="../../apt_get_basic.include"/>
<%include file="../../cxx_deps.include"/>
<%include file="../../clang_update.include"/>
<%include file="../../run_tests_addons.include"/>
RUN clang++ -c -g -O2 -std=c++11 llvm/lib/Fuzzer/*.cpp -IFuzzer
RUN ar ruv libFuzzer.a Fuzzer*.o
RUN mv libFuzzer.a /usr/lib
RUN rm -f Fuzzer*.o
# Define the default command.
CMD ["bash"]

@ -0,0 +1,44 @@
%YAML 1.2
---
foreach: targets
cond: selected.build == 'fuzzer'
output_name: ${selected.name}.sh
template: |
#!/bin/bash
# Copyright 2016, Google Inc.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following disclaimer
# in the documentation and/or other materials provided with the
# distribution.
# * Neither the name of Google Inc. nor the names of its
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
flags="-max_total_time=3600 -jobs=20 -workers=20"
if [ "$config" == "asan-trace-cmp" ]
then
flags="-use_traces=1 $flags"
fi
bins/$config/${selected.name} $flags fuzzer_output ${' '.join(selected.corpus_dirs)}

@ -2,6 +2,6 @@
--- |
<%namespace file="sln_defs.include" import="gen_solution"/>\
<%
solution_projects = [p for p in vsprojects if p.build != 'protoc' and p.language == 'c' and not p.boringssl and not p.zlib]
solution_projects = [p for p in vsprojects if p.build not in ['protoc', 'fuzzer'] and p.language == 'c' and not p.boringssl and not p.zlib]
%>\
${gen_solution(solution_projects, use_dlls='yes')}

@ -2,6 +2,6 @@
--- |
<%namespace file="sln_defs.include" import="gen_solution"/>\
<%
solution_projects = [p for p in vsprojects if p.build not in ['protoc', 'test'] and p.language in ['c', 'c++'] and p.vs_proj_dir == '.' and not (p.build == 'private' and p.language == 'c++')]
solution_projects = [p for p in vsprojects if p.build not in ['protoc', 'test', 'fuzzer'] and p.language in ['c', 'c++'] and p.vs_proj_dir == '.' and not (p.build == 'private' and p.language == 'c++')]
%>\
${gen_solution(solution_projects, use_dlls='yes')}

@ -2,12 +2,14 @@
---
foreach: vsprojects
output_name: ${selected.vs_proj_dir}/${selected.name}/${selected.name}.vcxproj
cond: selected.build not in ['fuzzer']
template: |
<%namespace file="vcxproj_defs.include" import="gen_project"/>\
${gen_project(selected.name, vsprojects)}
---
foreach: vsprojects
output_name: ${selected.vs_proj_dir}/${selected.name}/${selected.name}.vcxproj.filters
cond: selected.build not in ['fuzzer']
template: |
<%namespace file="vcxproj.filters_defs.include" import="gen_filters"/>\
${gen_filters(selected.name, vsprojects)}

@ -0,0 +1,52 @@
/*
*
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
#include <stdint.h>
#include <string.h>
#include <grpc/support/alloc.h>
#include "src/core/lib/client_config/uri_parser.h"
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
char *s = gpr_malloc(size + 1);
memcpy(s, data, size);
s[size] = 0;
grpc_uri *x;
if ((x = grpc_uri_parse(s, 1))) {
grpc_uri_destroy(x);
}
gpr_free(s);
return 0;
}

@ -0,0 +1,2 @@
„HTT/21. 200 HT!TP/1OKH.1HTTP 200 OKH
tHT//1T0P.1y 2001.

@ -0,0 +1,3 @@
HTTP/1.1 200 OKH
tHTTP/01.021 Oes,H
tes

@ -0,0 +1,3 @@
HTTP/1.1 200 OKHHTTP‰/1.200 OKH
tHTHTTP/0 20T:tes/01.

@ -0,0 +1,3 @@
JHTT/21. 2è0 HTTP/1.1 200 OKHHTTP‰/1.200 OKH
tHTHTHTJHTTPT

@ -0,0 +1,2 @@
JHTT/21. 200œHTT/0OKH.1 HTTP/200 OKH
tH1.T

@ -0,0 +1,2 @@
ITTP/11 …20O HTTP/11 2*0 OKH
HTDP/01.021 : OesHK ,H

@ -0,0 +1,2 @@
JHTT¹21. 200HTT/0OKH1 HTTP/100 OKH
tH1.T

@ -0,0 +1,2 @@
ITTP/11 …20O HTTP/22 2*0 OKH
HTDP/01.021 : OesHK ,H

@ -0,0 +1,4 @@
JHTT/21. 200 HTTP/0OKH.1 200 OKH
tHTTP/01.021 Oes,H
t
t

@ -0,0 +1,3 @@
žHTTP/1.1 200 HH
OK TDP/01.021 : Oe:,H
tes

@ -0,0 +1,3 @@
HTTP/1.1 200 OKH
tHTTP/01.021 : Oes,H
tes

@ -0,0 +1,4 @@
JHTTP/1.1 +00 HTTP/1.1 200 OKHHTTPOKH <EFBFBD>/1.
200 OKtH
tHTH

@ -0,0 +1,3 @@
HTTP/1.1 200 OKH
HTDP/01.021 : Oes,H
tes

@ -0,0 +1,4 @@
JHTT/21. 200 HTTP/1OKH.1 200 OKH
tHTTP/01.021 Oes,H
t
t

@ -0,0 +1,2 @@
JĎHTTP‰/1.200:OKHHTă/21. 2č0 HTTP/
1.1 200 OKHHTtTP‰

@ -0,0 +1,2 @@
ITTP/11 …20O HTTP/11 2*0 OKH
HTDP/01.021 : OesHK ,H

@ -0,0 +1,2 @@
@TTP/1.1y 00'JHTTP/1.1 +00ÿOïH HTTP/
ve1.1 200s

@ -0,0 +1,2 @@
ITTP/11 …20O HTTP/1.1 200 OKH
HTDP/01.021 : OesHK ,H

@ -0,0 +1,4 @@
HTTP/1.1 200 OKH
tHTHTTP/1. 20TP/01.020(: Oes,H0 OKH
tteses

@ -0,0 +1,2 @@
ITTp/11 …20O HTTP/*1.1 200 OKH
HTDP/02.021 : OesHK ,H

@ -0,0 +1,3 @@
„HTT/21. 200 HTTP/1.1 HT!TP/1OKH.1HTTP 200 OKH
tHT/:/80 OKH
1

@ -0,0 +1,3 @@
„HTT/21. 200 HTTP/1.1 HT!TP/1OKH.1HTTP 200 OKH
tHT//80) OKH
1

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save