Increase max header length to 4096 bytes 78/272978/1 submit/tizen/20220329.031515
authorSeonah Moon <seonah1.moon@samsung.com>
Tue, 29 Mar 2022 01:58:16 +0000 (10:58 +0900)
committerSeonah Moon <seonah1.moon@samsung.com>
Tue, 29 Mar 2022 03:12:31 +0000 (12:12 +0900)
Change-Id: I1427ebddbd1f564eef1879ba922b39af96ad5608

packaging/download-provider.spec
provider-interface/download-provider-interface.c
provider/include/download-provider.h

index cda69170b8e3b454340971e8d5353ea0fbb3ede7..e000cd0f29126c5c0d0a27af6550f405fdaa81a2 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       download-provider
 Summary:    Download the contents in background
-Version:    2.3.2
+Version:    2.3.3
 Release:    0
 Group:      Development/Libraries
 License:    Apache-2.0
index 5844c32b73df4cb23ea0c00e76cc64411a183ba1..dfb15e8e9b73ed95903b62356b625c8dd7a183c4 100755 (executable)
@@ -1502,7 +1502,7 @@ int dp_interface_add_http_header_field(const int id, const char *field,
                return DOWNLOAD_ADAPTOR_ERROR_INVALID_PARAMETER;
        }
        if (value == NULL || (value_length = strlen(value)) <= 0 ||
-                       value_length > DP_MAX_STR_LEN) {
+                       value_length > DP_MAX_HEADER_LEN) {
                TRACE_ERROR("check value (%zd:%s)", value_length, value);
                return DOWNLOAD_ADAPTOR_ERROR_INVALID_PARAMETER;
        }
index 41c12ead576d8e31a97ffc9e87116cc068d89d5c..879c80c8b49fdd47e1dbba7fe3e8fd247b656ed7 100755 (executable)
@@ -94,6 +94,7 @@ typedef enum {
 
 #define MAX_DOWNLOAD_HANDLE 32
 #define DP_MAX_STR_LEN 2048
+#define DP_MAX_HEADER_LEN 4096
 #define DP_DEFAULT_BUFFER_SIZE 1024
 
 // string to check invalid characters in path before using open() and fopen() API's