platform/framework/web/download-provider.git
3 weeks agoFix BAD_CHECK_OF_WAIT_COND in cache agent 53/308553/3 accepted/tizen_unified accepted/tizen_unified_x tizen accepted/tizen/unified/20240328.123416 accepted/tizen/unified/x/20240401.142512
Jaehyun Kim [Wed, 27 Mar 2024 09:51:53 +0000 (18:51 +0900)]
Fix BAD_CHECK_OF_WAIT_COND in cache agent

Change-Id: Ic7db1689563b71d885b9607b7268db93757f09b7
Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
3 weeks agoFix BAD_CHECK_OF_WAIT_COND 43/308543/1
Seonah Moon [Wed, 27 Mar 2024 07:44:06 +0000 (16:44 +0900)]
Fix BAD_CHECK_OF_WAIT_COND

Change-Id: Ic51fa5b8cd1db7f122bb126c1cb4c78e339e9ab7

5 weeks agoFix calling of g_string_free_and_steal() 17/307917/1 accepted/tizen/unified/20240318.071216 accepted/tizen/unified/20240322.174345 accepted/tizen/unified/x/20240319.055546
JinWang An [Thu, 14 Mar 2024 07:18:58 +0000 (16:18 +0900)]
Fix calling of g_string_free_and_steal()

Change-Id: Ibce062f6601eeb470c65c16ad9dc144779e65f50
Signed-off-by: JinWang An <jinwang.an@samsung.com>
5 weeks agoUse g_string_free_and_steal() if glib is greater than 2.76.0 03/307803/2 accepted/tizen/unified/20240315.032940 accepted/tizen/unified/x/20240318.021728
Seonah Moon [Wed, 13 Mar 2024 08:27:19 +0000 (17:27 +0900)]
Use g_string_free_and_steal() if glib is greater than 2.76.0

Change-Id: I11d2a944fbde6040700c21ac4bfe8caf41eb5472

8 weeks agoDo not use POST method 21/306421/1 accepted/tizen_unified_toolchain accepted/tizen/unified/20240222.163401 accepted/tizen/unified/toolchain/20240311.064843 accepted/tizen/unified/x/20240225.131833
Seonah Moon [Wed, 21 Feb 2024 07:13:14 +0000 (16:13 +0900)]
Do not use POST method

Change-Id: Ia193d9b79b810c1066582fab8f14aac4a5ae9327

8 weeks agoModify CURLOPT_HTTPPOST to CURLOPT_MIMEPOST 47/306347/1 accepted/tizen/unified/20240221.062940 accepted/tizen/unified/x/20240220.150105
wchang kim [Tue, 20 Feb 2024 11:04:00 +0000 (20:04 +0900)]
Modify CURLOPT_HTTPPOST to CURLOPT_MIMEPOST

Since CURLOPT_HTTPPOST is deprecated option in libcurl, build error
occured in Tizen-Unified-X environment.
According to the documentation of libcurl, CURLOPT_HTTPPOST is replaced
by CURLOPT_MIMEPOST.

Change-Id: I9717a27967c171dc6609e55fcc6470e4c9c21400

3 months ago[CID-1745069] Fix data race condition 11/304111/1 accepted/tizen_unified_riscv accepted/tizen/unified/20240111.161412 accepted/tizen/unified/riscv/20240115.113655
chaehee.hong [Wed, 10 Jan 2024 07:27:09 +0000 (16:27 +0900)]
[CID-1745069] Fix data race condition

Change-Id: Ib4024a3d165b6c576dd147329f0485396ca9eecd

9 months agoRemove some lines related to openssl 17/296117/1 accepted/tizen_8.0_unified tizen_8.0 accepted/tizen/8.0/unified/20231005.094352 accepted/tizen/unified/20230920.161435 tizen_8.0_m2_release
hyunsube.lee [Thu, 20 Jul 2023 05:09:18 +0000 (14:09 +0900)]
Remove some lines related to openssl

Change-Id: I7d65482d306cc90742e435a115adaa9184932db8

11 months agoRemove notstrip file 02/292702/1 accepted/tizen/unified/20230528.171024
Seonah Moon [Thu, 11 May 2023 10:23:06 +0000 (19:23 +0900)]
Remove notstrip file

notstrip file is no longer used.

Change-Id: I0c5737946ed7033a50a3f090a33b6501f06f417d

12 months agoAdd cache support 41/291341/4 accepted/tizen/unified/20230420.041540
Jaehyun Kim [Thu, 13 Apr 2023 13:56:04 +0000 (22:56 +0900)]
Add cache support

Cache Agent and related DBs have been added to support cache
and logic using them has been implemented.

Change-Id: Ieaa8773959d9c3c6b0b0b2c8c90da243452a677d
Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
12 months agoCheck if temp_id is overflowed 93/290393/1 accepted/tizen/unified/20230325.044638
cheoleun moon [Fri, 24 Mar 2023 02:11:19 +0000 (11:11 +0900)]
Check if temp_id is overflowed

Change-Id: I1d1aad6ea6b2c46ba037afd5fa224c391614e3d5

12 months agoCheck if parsed_url is null check before using it 78/290378/1
cheoleun moon [Fri, 24 Mar 2023 00:52:49 +0000 (09:52 +0900)]
Check if parsed_url is null check before using it

Change-Id: I45b13728b1b73c0cd06f317c1e4e8dd9f8dd575b

13 months agoFix for svace issue 518382 03/290103/1 accepted/tizen/unified/20230322.080542
Hyunsub [Mon, 20 Mar 2023 07:37:26 +0000 (16:37 +0900)]
Fix for svace issue 518382

Change-Id: I22239fec80cae6799529cc3627091beaefcdcaa1

13 months agoCheck both CURLINFO_RESPONSE_CODE and CURLINFO_HTTP_CONNECTCODE for HTTP status code 20/289720/1
Anjali Nijhara [Tue, 14 Mar 2023 03:48:21 +0000 (09:18 +0530)]
Check both CURLINFO_RESPONSE_CODE and CURLINFO_HTTP_CONNECTCODE for HTTP status code

Change-Id: I1e1f7186d743d2bc8da4b33834d3f67e5698e3ec

13 months agoMerge "Accept spaces in URL" into tizen
seonah moon [Tue, 14 Mar 2023 02:28:35 +0000 (02:28 +0000)]
Merge "Accept spaces in URL" into tizen

13 months agoMerge "Check a exception proxy list before transmitting HTTP request" into tizen
seonah moon [Tue, 14 Mar 2023 02:28:14 +0000 (02:28 +0000)]
Merge "Check a exception proxy list before transmitting HTTP request" into tizen

13 months agoResolve probable infinite loop issue due to integer overflow. 16/288916/4 accepted/tizen/unified/20230314.093346
Akash Kumar [Fri, 24 Feb 2023 09:24:48 +0000 (14:54 +0530)]
Resolve probable infinite loop issue due to integer overflow.

Change-Id: I7ad2bc1d6ef28510ed6f17fb004425dca4637a56
Signed-off-by: Akash Kumar <akash1.kumar@samsung.com>
13 months agoAccept spaces in URL 36/289536/2
Seonah Moon [Thu, 9 Mar 2023 08:14:00 +0000 (17:14 +0900)]
Accept spaces in URL

Change-Id: I1a9023e77596c04b736ce56b21eb1e4a6c70a30f

13 months agoMerge "Reset sockfd after close" into tizen
seonah moon [Wed, 22 Feb 2023 10:26:56 +0000 (10:26 +0000)]
Merge "Reset sockfd after close" into tizen

14 months agoCheck a exception proxy list before transmitting HTTP request 75/287875/7
Seonah Moon [Tue, 7 Feb 2023 14:03:53 +0000 (23:03 +0900)]
Check a exception proxy list before transmitting HTTP request

Change-Id: I3e54200a9dcb34001ae8e7d6f9a188fabafe3b11
Signed-off-by: pyun <dh79.pyun@samsung.com>
14 months agoDo not use CURLAUTH_ANY 84/287984/2 accepted/tizen/unified/20230213.170716
Seonah Moon [Wed, 8 Feb 2023 13:41:41 +0000 (22:41 +0900)]
Do not use CURLAUTH_ANY

Curl known issue.
https://curl.se/docs/knownbugs.html#libcurl_can_fail_to_try_alternat

6.6 libcurl can fail to try alternatives with --proxy-any
https://github.com/curl/curl/issues/876

Change-Id: I31ce09e8bb3c8286804224df23e4fbfdba663aa5

14 months agobug fix: handle empty proxy address 04/287904/2
Seonah Moon [Tue, 7 Feb 2023 11:34:00 +0000 (20:34 +0900)]
bug fix: handle empty proxy address

1. Revert e09e63a4a974ec9e6f2c094d7562bc89cb3452f8
2. Exception handling for empty proxy address

Change-Id: I012edb83c505cc8c17d6078dfdaa75c291164112

14 months agoFix the download fail issue on the normal environment 63/287863/1
pyun [Tue, 7 Feb 2023 05:55:14 +0000 (14:55 +0900)]
Fix the download fail issue on the normal environment

Change-Id: Ib6ddcbe831dad72e5188f44a598cb3bd5d847bd8
Signed-off-by: Dohyun Pyun <dh79.pyun@samsung.com>
14 months agoGet status code using CURLINFO_HTTP_CONNECTCODE when using proxy 18/287618/1
Anjali Nijhara [Wed, 1 Feb 2023 06:58:50 +0000 (12:28 +0530)]
Get status code using CURLINFO_HTTP_CONNECTCODE when using proxy

Change-Id: I93309e8c3ba38e0e7c70b389ac8c6e6caa80b258

14 months agoReset sockfd after close 55/287355/1
cheoleun moon [Fri, 27 Jan 2023 06:43:49 +0000 (15:43 +0900)]
Reset sockfd after close

Change-Id: I31301b6646c36143f4c4c3583c119bb35e50bc37
Signed-off-by: cheoleun moon <chleun.moon@samsung.com>
15 months agoUse the same type to compare values 32/286132/1
cheoleun moon [Wed, 28 Dec 2022 10:20:08 +0000 (19:20 +0900)]
Use the same type to compare values

Change-Id: I98c2c1bb5ee85fe15de100340c19a00530d7f3cd
Signed-off-by: cheoleun moon <chleun.moon@samsung.com>
17 months agoFix svace issues 36/283236/2 accepted/tizen/unified/20221107.173040
Seonah Moon [Thu, 20 Oct 2022 13:09:43 +0000 (22:09 +0900)]
Fix svace issues

- SEC_DO_NOT_USE_INT_IN_FOR_LOOP
- SEC_DO_NOT_CAST_LONG_TO_DOUBLE

Change-Id: I0b0fb1f1ccdd00f0281cc404c153cf35e58a7d7a

2 years agoChange the naming rule for duplicate files 55/273055/1 accepted/tizen_7.0_unified_hotfix tizen_7.0_hotfix accepted/tizen/7.0/unified/hotfix/20221116.110308 accepted/tizen/unified/20220608.140030 submit/tizen/20220607.061719 tizen_7.0_m2_release
Seonah Moon [Wed, 30 Mar 2022 06:03:35 +0000 (15:03 +0900)]
Change the naming rule for duplicate files

Change-Id: I25a3010f7e3b8f76deccbfa44ac08966b9fc8441

2 years agoIncrease max header length to 4096 bytes 78/272978/1 submit/tizen/20220329.031515
Seonah Moon [Tue, 29 Mar 2022 01:58:16 +0000 (10:58 +0900)]
Increase max header length to 4096 bytes

Change-Id: I1427ebddbd1f564eef1879ba922b39af96ad5608

2 years agoRetry read() when getting EAGAIN 33/270633/1 accepted/tizen/unified/20220210.105947 submit/tizen/20220208.033954 submit/tizen/20220210.054535
Seonah Moon [Mon, 7 Feb 2022 05:50:25 +0000 (14:50 +0900)]
Retry read() when getting EAGAIN

When download is requested from new client, client DB including several tables is created.
This often takes long time on RPI4 and makes IPC error(EAGAIN) in the end.

Change-Id: Ib28dcc22e929d11fe61e5f1690f7da64ee5465b8

2 years agoDo not change a permission of files stored in external storage 65/269065/1 accepted/tizen/unified/20220110.135912 submit/tizen/20220107.075936
Seonah Moon [Fri, 7 Jan 2022 06:26:54 +0000 (15:26 +0900)]
Do not change a permission of files stored in external storage

Change-Id: I1971284beff321a28d50b2e4769cdcf72a441eab

2 years agoChange ownership of downloaded file to client's uid 95/267095/1 accepted/tizen/unified/20211129.035311 submit/tizen/20211126.065740
Seonah Moon [Thu, 25 Nov 2021 08:47:55 +0000 (17:47 +0900)]
Change ownership of downloaded file to client's uid

Increase version to 2.3.0 for Tizen 7.0

Change-Id: Ib4c79ee3b20404546a0e459d8964635f143de755

2 years agoFix NULL pointer dereference 74/262374/1 accepted/tizen/6.5/unified/20211028.114609 accepted/tizen/unified/20210819.123206 submit/tizen/20210817.044257 submit/tizen/20210818.091234 submit/tizen_6.5/20211028.163201 tizen_6.5.m2_release
Seonah Moon [Mon, 9 Aug 2021 10:03:36 +0000 (19:03 +0900)]
Fix NULL pointer dereference

Change-Id: I9d2cf34fc9e924da5dec01d5229c4b7532b35f48

2 years agoRetry read() when getting EINTR 91/260891/1 accepted/tizen/unified/20210707.130433 submit/tizen/20210707.023406
Seonah Moon [Tue, 6 Jul 2021 08:54:39 +0000 (17:54 +0900)]
Retry read() when getting EINTR

Change-Id: I476b3db2a3dfb6519d885c67c052914201eeca4c

2 years agoRemove stale data from a client DB when client is terminated 56/258856/1 accepted/tizen/unified/20210603.130735 submit/tizen/20210531.043319
Seonah Moon [Thu, 27 May 2021 02:34:32 +0000 (11:34 +0900)]
Remove stale data from a client DB when client is terminated

[Problem]
a client DB size is increased unlimitedly when a client is terminated by
itself or a crash.

[Cause]
a client DB is cleaned only if a client is live and has no response
during 2 minutes.

Change-Id: Ib164be4cf446bd6c30b0bc89b50d902b0cc5955f

2 years agoRemove an error code to be overwritten 51/258451/2
Cheoleun Moon [Tue, 18 May 2021 04:25:27 +0000 (13:25 +0900)]
Remove an error code to be overwritten

Change-Id: I4f582c81220d42dcf8fb7945b168a439fdcf59f2
Signed-off-by: Cheoleun Moon <chleun.moon@samsung.com>
2 years agoAdd missed unlock 50/258450/1
Cheoleun Moon [Tue, 18 May 2021 04:18:56 +0000 (13:18 +0900)]
Add missed unlock

Change-Id: I9ad8f4f9525e2f9c8f5b43ec7994469a6c68cd4f
Signed-off-by: Cheoleun Moon <chleun.moon@samsung.com>
3 years agoAvoid to use stat() function 44/255944/1 accepted/tizen/unified/20210511.072805 submit/tizen/20210510.015709
Seonah Moon [Thu, 25 Mar 2021 07:54:27 +0000 (16:54 +0900)]
Avoid to use stat() function

Doing something after checking of the state of a file has a potential
race condition bug. It is more effiecient that just using execption
handling instead of checking to prevent TOCTOU.

Change-Id: I2a2560d9d49ed9d52008557f0d2f89fa04bb130d

3 years agosnprintf(): use sizeof() for size factor 55/255355/1 accepted/tizen/unified/20210318.162602 submit/tizen/20210318.044124
Seonah Moon [Wed, 17 Mar 2021 09:14:43 +0000 (18:14 +0900)]
snprintf(): use sizeof() for size factor

Change-Id: I9a94e6c82b1bd40f06d66e8e2bec13a860ce5f20

3 years agoChange systemd-devel package name 94/252894/1 accepted/tizen/unified/20210309.140746 submit/tizen/20210209.023736 submit/tizen/20210303.074750
INSUN PYO [Wed, 3 Feb 2021 04:24:57 +0000 (13:24 +0900)]
Change systemd-devel package name

Change-Id: I90d548f1f86be4df188fff33d291b6122edbe939

3 years agoChange the type of some log messages from DEBUG to INFO 28/246228/2 accepted/tizen/unified/20201028.123915 submit/tizen/20201027.073130
Seonah Moon [Tue, 27 Oct 2020 06:54:39 +0000 (15:54 +0900)]
Change the type of some log messages from DEBUG to INFO

TV image doesn't show DEBUG message.

Change-Id: I6febbb33c936bbb7f3d9440faf8e01681b842179

3 years agoLimits concurrent downloads to 15 on TV 42/245742/2
Seonah Moon [Thu, 8 Oct 2020 03:25:27 +0000 (12:25 +0900)]
Limits concurrent downloads to 15 on TV

Change-Id: Ib70042cd7c9e6f875e7c32cef76e434ec7d6e77a

3 years agoDo not free http_info in client request thread 90/244290/1
Seonah Moon [Thu, 17 Sep 2020 01:47:58 +0000 (10:47 +0900)]
Do not free http_info in client request thread

http_info is used in download thread and it is freed if download is
finished.

However, in pause state, client request thread releases http_info if
client requests 'cancel'.
This makes a crash occasionally during download thread is terminating.

So, download thread should have ownership of http_info and this thread
should free it only.

Change-Id: Ia3ec64d1ce64e2aee49e260b901686a4ae6d4d76

3 years agoFix heap-use-after-free 92/244192/1 accepted/tizen_6.0_unified_hotfix tizen_6.0_hotfix accepted/tizen/6.0/unified/20201030.104928 accepted/tizen/6.0/unified/hotfix/20201103.000716 accepted/tizen/unified/20200917.055723 submit/tizen/20200917.013404 submit/tizen_6.0/20201029.205501 submit/tizen_6.0_hotfix/20201102.192901 submit/tizen_6.0_hotfix/20201103.115101 tizen_6.0.m2_release
Seonah Moon [Wed, 16 Sep 2020 01:29:33 +0000 (10:29 +0900)]
Fix heap-use-after-free

In case of below scenario, da_info is freed immediately after cancel
request.

[client request thread]      [http thread]
1. download start
                           2. network doesn't work temporary
                           3. wait for auto retry (pthread_cond_timedwait(cond_http))
4. request cancel
                           5. pthread_cond_signal(cond_http)
                           6. free da_info
7. access to da_info for
   debugging message
   (fault)

Change-Id: I3bf0002e643af77dac17f69c543d29570c1f3cde

3 years agoWait for download thread before destroying da_info 66/240966/5 accepted/tizen/unified/20200818.130009 submit/tizen/20200814.045951
Seonah Moon [Thu, 13 Aug 2020 08:37:48 +0000 (17:37 +0900)]
Wait for download thread before destroying da_info

A cancel request doesn't take effect immediately. (__http_gotheaders_cb)
So, below scenario can occur.

1. client-request thread requests cancel a download for a number of reasons. (ex. zombie client)
2. client-request thread is terminated.
3. queue-manager deallocates da_info_list for terminating.
4. download is canceled and then a http thread accesses to da_info for notifying download terminated.
5. heap-use-after-free occurs.

Change-Id: I47a7ef4c4d7ddda5f4594ee30885e3af230c6116

3 years agoFix invalid data type of parameter 39/240439/1 accepted/tizen/unified/20200807.141018 submit/tizen/20200807.012059
Seonah Moon [Thu, 6 Aug 2020 08:41:05 +0000 (17:41 +0900)]
Fix invalid data type of parameter

Change-Id: I0e64b2fea19ca48dac78e53c2ffa3cf2bbc6106b

3 years agoFree proxy_uri 05/237905/1 accepted/tizen/unified/20200713.132959 submit/tizen/20200707.014520
Cheoleun Moon [Mon, 6 Jul 2020 09:32:43 +0000 (18:32 +0900)]
Free proxy_uri

In condition that proxy_uri is "0.0.0.0", proxy_uri is not freed.

Change-Id: Ifd3759c1a7b416cd69fc134eb653b0a5802a7a73

3 years agoReturn error when status code isn't 2XX or 3XX 39/237639/2 accepted/tizen/unified/20200706.033247 submit/tizen/20200703.062459
Seonah Moon [Thu, 2 Jul 2020 05:34:15 +0000 (14:34 +0900)]
Return error when status code isn't 2XX or 3XX

Change-Id: Ie2a85db0c87060f9f275a0f86b075eefde284136

3 years agoSAM: remove Global Variable violations 16/237416/1
Seonah Moon [Tue, 30 Jun 2020 08:04:41 +0000 (17:04 +0900)]
SAM: remove Global Variable violations

Change-Id: Ib3b4b47aa62517df80ea446ba405fd3f5caa5d33

3 years agoDo not unload agent symbol file 08/235308/1 accepted/tizen/unified/20200609.153648 submit/tizen/20200604.114541 submit/tizen/20200608.074227
Seonah Moon [Wed, 3 Jun 2020 11:45:04 +0000 (20:45 +0900)]
Do not unload agent symbol file

If symbol file is unload before terminating program, segfault can occur
when access to static variable. (ex. mutex_da_info_list)

Change-Id: I9e6c61f2d45264682755d5717d85943e5b5c44a3

3 years agoRevert "Do not unload agent symbol file"
Seonah Moon [Wed, 3 Jun 2020 11:50:10 +0000 (20:50 +0900)]
Revert "Do not unload agent symbol file"

This reverts commit 37808dc1789f8a3cdb99ce698ac38ec3a917a047.

3 years agoDo not unload agent symbol file
Seonah Moon [Wed, 3 Jun 2020 11:45:04 +0000 (20:45 +0900)]
Do not unload agent symbol file

If symbol file is unload before terminating program, segfault can occur
when access to static variable. (ex. mutex_da_info_list)

Change-Id: I9e6c61f2d45264682755d5717d85943e5b5c44a3

3 years agoMerge changes I780f6179,I29223a72,I4e5182dd into tizen accepted/tizen/unified/20200601.051730 submit/tizen/20200422.053529 submit/tizen/20200428.032248 submit/tizen/20200429.055725 submit/tizen/20200529.030937
cheoleun moon [Wed, 22 Apr 2020 05:30:09 +0000 (05:30 +0000)]
Merge changes I780f6179,I29223a72,I4e5182dd into tizen

* changes:
  Refine __dp_client_new()
  Add a function to handle init request
  Use additional functions in dp_client_manager()

4 years agoAllow cancel request when download state is paused 97/231097/1 submit/tizen/20200421.072931
Seonah Moon [Fri, 17 Apr 2020 07:11:35 +0000 (16:11 +0900)]
Allow cancel request when download state is paused

download-provider cannot be terminated in case of below scenario.

1. application requests a pause.
2. download-provider pauses the download request.
3. application requests a cancel.
4. the download request couldn't be canceled because a state is paused.
5. http thread is alive constantly.

Change-Id: I7b2566bce98b3e563e2b5980c908a92140ffdcd9

4 years agoRefine __dp_client_new() 75/231075/1
Cheoleun Moon [Fri, 17 Apr 2020 06:21:22 +0000 (15:21 +0900)]
Refine __dp_client_new()

Change-Id: I780f6179436819d471b4e99f2cc2387bc432d025
Signed-off-by: Cheoleun Moon <chleun.moon@samsung.com>
4 years agoAdd some functions to check request status 98/230998/2
Seonah Moon [Thu, 16 Apr 2020 11:33:40 +0000 (20:33 +0900)]
Add some functions to check request status

Change-Id: I76583efe22dd4ff7bd0d7151d8ab6f9de02bb3ae

4 years agoAdd a function to handle init request 94/230994/1
Cheoleun Moon [Thu, 16 Apr 2020 11:14:05 +0000 (20:14 +0900)]
Add a function to handle init request

Change-Id: I29223a721e50b0b06a19a329bfdcffaf436bbbbf
Signed-off-by: Cheoleun Moon <chleun.moon@samsung.com>
4 years agoUse additional functions in dp_client_manager() 89/230989/2
Cheoleun Moon [Thu, 16 Apr 2020 10:38:49 +0000 (19:38 +0900)]
Use additional functions in dp_client_manager()

Change-Id: I4e5182ddae71600264cfe10e4ac69d88efa3c11d
Signed-off-by: Cheoleun Moon <chleun.moon@samsung.com>
4 years agoRemove unnecessary predefined preprocessor 30/214830/4
Seonah Moon [Thu, 16 Apr 2020 09:59:24 +0000 (18:59 +0900)]
Remove unnecessary predefined preprocessor

Change-Id: I376d831575e9c22e03691faa7ba0e3d76f682e63

4 years agoChange HTTP state properly 84/229484/2 accepted/tizen/unified/20200416.080136 submit/tizen/20200414.081814
Seonah Moon [Wed, 1 Apr 2020 08:54:59 +0000 (17:54 +0900)]
Change HTTP state properly

Sometimes HTTP thread works abnormally because HTTP state isn't changed
properly.

Change-Id: I5462b6497bd5a7bd64c5b600a00aa7cf3e1954ff

4 years agotv: do not use thread locking function 22/226622/1 accepted/tizen/unified/20200312.234445 submit/tizen/20200305.012611
Seonah Moon [Wed, 4 Mar 2020 07:21:08 +0000 (16:21 +0900)]
tv: do not use thread locking function

libcurl has used openssl 1.1 since tizen 6.0.

Change-Id: Ie5b4db0bb7f3f85028373b985f02b3cff1c29db6

4 years agoDeprecate pubkey-pinning 56/226356/2 accepted/tizen/unified/20200304.123854 submit/tizen/20200304.015236
Sangwan Kwon [Mon, 2 Mar 2020 03:56:22 +0000 (12:56 +0900)]
Deprecate pubkey-pinning

Pubkey pinning is not supported from tizen-6.0.

Change-Id: Ie3541d9780e70de55d2355e2e2544961a142aa80
Signed-off-by: Sangwan Kwon <sangwan.kwon@samsung.com>
4 years agoImplement internal API for host verification 19/225319/3
Seonah Moon [Wed, 19 Feb 2020 05:25:36 +0000 (14:25 +0900)]
Implement internal API for host verification

Change-Id: I0362a6263d177363580ecb95cf6223b611a1b896

4 years agoMerge "Change CA certificate bundle and path for TV" into tizen
seonah moon [Tue, 18 Feb 2020 09:53:33 +0000 (09:53 +0000)]
Merge "Change CA certificate bundle and path for TV" into tizen

4 years agoAccept legacy app path to keep backwards compatibility 71/225171/1
Seonah Moon [Tue, 18 Feb 2020 03:49:21 +0000 (12:49 +0900)]
Accept legacy app path to keep backwards compatibility

Change-Id: I6164dd62f8a2c0a55732539a0bd5a73eb772d051
Signed-off-by: Seonah Moon <seonah1.moon@samsung.com>
4 years agoChange CA certificate bundle and path for TV 29/225129/1
Seonah Moon [Mon, 17 Feb 2020 08:50:11 +0000 (17:50 +0900)]
Change CA certificate bundle and path for TV

Change-Id: I2029019f151df781ed589646e0b9ed69077f80fa

4 years agoReplace app_context API with app_info API for getting package ID 06/222906/3 accepted/tizen/unified/20200203.125817 submit/tizen/20200131.043421
Seonah Moon [Tue, 21 Jan 2020 09:03:07 +0000 (18:03 +0900)]
Replace app_context API with app_info API for getting package ID

P200120-04045

Change-Id: Id21ffee103b37ec9374e0f5655e3fe73ea7557e2

4 years ago[CID-1103253] Fix bad bit shift operation 69/222769/1
Seonah Moon [Mon, 20 Jan 2020 02:09:44 +0000 (11:09 +0900)]
[CID-1103253] Fix bad bit shift operation

Change-Id: I91a989c5e6cac89bd64b97bf8ef835c0ac55fdce

4 years agobug fix: add error handling for preventing duplicate file 89/222689/1 submit/tizen/20200120.023604
Seonah Moon [Fri, 17 Jan 2020 07:30:56 +0000 (16:30 +0900)]
bug fix: add error handling for preventing duplicate file

Change-Id: If3a00019e8b6d6ad586c5e2d5c38b0989c0fa966

4 years agoFix build warnings for gcc9 44/221044/1 accepted/tizen/unified/20191230.120929 submit/tizen/20191230.112257
Seonah Moon [Thu, 26 Dec 2019 12:38:59 +0000 (21:38 +0900)]
Fix build warnings for gcc9

Change-Id: I57f8c411c130d0b48b9979d5eb0eaa859f239335

4 years agoSupport proxy authentication 16/219916/1 accepted/tizen/unified/20191217.123000 submit/tizen/20191212.014813
Seonah Moon [Tue, 12 Nov 2019 11:39:34 +0000 (20:39 +0900)]
Support proxy authentication

Change-Id: I66b65fe2417db65bb2b0973ca950de2abd7dfea8

4 years agoAdd ssl thread locking function for openssl 1.0 54/217254/1 accepted/tizen/unified/20191113.123549 submit/tizen/20191107.131533
Seonah Moon [Fri, 8 Nov 2019 04:21:47 +0000 (13:21 +0900)]
Add ssl thread locking function for openssl 1.0

TV profile doesn't use openssl 1.1 yet.
So, this patch defines thread locking function for TV profile temporaly.
It will be removed or disabled after openssl 1.1 is applied to TV.

Change-Id: Ia7a029b898d85cd84552e0fffe0966e1e14dac8f

4 years agoReduce cyclomatic complexity #1 52/208652/4 submit/tizen/20191002.143405 submit/tizen/20191010.115910 submit/tizen/20191029.112455
Seonah Moon [Thu, 27 Jun 2019 05:10:34 +0000 (14:10 +0900)]
Reduce cyclomatic complexity #1

provider/download-provider-client.c: __dp_request_get_info()

Change-Id: I4332b1611c23e2c521ce23ef0f9822dd858b87c7

4 years agoFix potential thread cancel issue 07/213707/2
Seonah Moon [Tue, 10 Sep 2019 09:04:23 +0000 (18:04 +0900)]
Fix potential thread cancel issue

Change-Id: Id6f37948bfa6b7c3dd61cf2fdc9a585b1f3ec35e

4 years agoMigrate to openssl 1.1 66/211066/2 submit/tizen/20190829.105349 submit/tizen/20190905.080725 submit/tizen/20190909.061136
Dariusz Michaluk [Mon, 29 Jul 2019 13:45:11 +0000 (15:45 +0200)]
Migrate to openssl 1.1

Locking mechanism is not needed anymore

Change-Id: If11be650c3366084c7bd28da90b5463348b1c880

4 years agoMerge "Remove download-provider.service form graphical.target.wants" into tizen accepted/tizen_5.5_unified_mobile_hotfix tizen_5.5_mobile_hotfix accepted/tizen/5.5/unified/20191031.010402 accepted/tizen/5.5/unified/mobile/hotfix/20201027.063539 accepted/tizen/unified/20190816.112429 submit/tizen/20190730.092835 submit/tizen/20190813.084312 submit/tizen_5.5/20191031.000006 submit/tizen_5.5_mobile_hotfix/20201026.185106 tizen_5.5.m2_release
cheoleun moon [Tue, 30 Jul 2019 09:26:38 +0000 (09:26 +0000)]
Merge "Remove download-provider.service form graphical.target.wants" into tizen

4 years agoRemove unused file 53/210953/1 submit/tizen/20190730.005315
Seonah Moon [Fri, 26 Jul 2019 08:04:56 +0000 (17:04 +0900)]
Remove unused file

Change-Id: Ic42ed980a559da1fe466392c3015111e5506cd1d

4 years agoRemove download-provider.service form graphical.target.wants 85/210685/3
INSUN PYO [Tue, 23 Jul 2019 23:54:59 +0000 (08:54 +0900)]
Remove download-provider.service form graphical.target.wants

Download-provider.service is enabled by socket activation called download-provider.socket.
So, we don't need to execute donwload-provider.service on booting time.

Change-Id: I75df0aa3275174bb053806fede64d1ec77ab9f21

4 years agoRemove unnecessary log 54/209854/1 accepted/tizen/unified/20190712.115302 submit/tizen/20190712.014525
Seonah Moon [Fri, 12 Jul 2019 01:23:02 +0000 (10:23 +0900)]
Remove unnecessary log

Change-Id: I8c54fdbd37fe712c66a798adb4b5a02e5923f22c

4 years agoMerge "Change FILE_OFFSET_BITS to 64 bits to support a large file" into tizen submit/tizen/20190710.230039
cheoleun moon [Wed, 10 Jul 2019 22:52:57 +0000 (22:52 +0000)]
Merge "Change FILE_OFFSET_BITS to 64 bits to support a large file" into tizen

4 years agoLimit g_dp_sock size for buffer overflow 79/209579/2 accepted/tizen/unified/20190710.103439 submit/tizen/20190709.045603
Seonah Moon [Tue, 9 Jul 2019 04:34:02 +0000 (13:34 +0900)]
Limit g_dp_sock size for buffer overflow

[WID-3498058] Buffer 'rset.__fds_bits' of size 32
accessed at dp_client_manager() can overflow,
since its index 'g_dp_sock / 32' can have value 50331680
that is out of range, as indicated by preceding conditional expression.

Change-Id: I6c9c51903faa1df6c207670ab4b63b01038bcb70

4 years agoChange FILE_OFFSET_BITS to 64 bits to support a large file 32/209432/2
Seonah Moon [Fri, 5 Jul 2019 08:03:07 +0000 (17:03 +0900)]
Change FILE_OFFSET_BITS to 64 bits to support a large file

Change-Id: I034da2578c1355a93758fc960431410c7d2edf80

4 years agoRemove unnecessary settings on download-provider.socket 84/208384/2 accepted/tizen/unified/20190627.115235 submit/tizen/20190627.055720
INSUN PYO [Mon, 24 Jun 2019 02:42:25 +0000 (11:42 +0900)]
Remove unnecessary settings on download-provider.socket

Change-Id: Ib12324afbd6ad4ed99025ce4005988674eb8eaea

4 years agoAdd build macro to avoid conflict with spin 66/208466/1 accepted/tizen/unified/20190627.014824 submit/tizen/20190625.013432
Seonah Moon [Tue, 25 Jun 2019 00:40:35 +0000 (09:40 +0900)]
Add build macro to avoid conflict with spin

Change-Id: I64918d5f22a4d475b56d056a7eb3a2ce20044929

4 years agoFix merge conflict 19/208419/3 accepted/tizen/unified/20190624.115329 submit/tizen/20190624.074820
Seonah Moon [Mon, 24 Jun 2019 06:49:05 +0000 (15:49 +0900)]
Fix merge conflict

Change-Id: Ib014b55edb95b0eafde42b3e39d17ff5929bf1ce

4 years agoExpose new API to set/get http proxy from apps. 07/208107/2
sowmya.b1 [Thu, 6 Apr 2017 13:12:28 +0000 (18:42 +0530)]
Expose new API to set/get http proxy from apps.

Need an API in download provider to set http proxy from app side.
There was no API defined in download provider interface for setting proxy.
Added new API dp_interface_{set,get}_proxy()

Change-Id: Ie79d34cebd4c27f372c7e50a42a0a809f88ca165
Signed-off-by: Sowmya B <sowmya.b1@samsung.com>
4 years agoChanging download provider notification as in Dowload Manager's notification. 99/208099/3
Raveendra Karu [Wed, 10 May 2017 05:08:38 +0000 (10:38 +0530)]
Changing download provider notification as in Dowload Manager's notification.

Download provider notification does not display URL information.
Added changes to show URL information in notification.
Also added changes to handle EBUSY case while releasing the acquired lock
on mutex.

Change-Id: I27bfff0495fb7da65fc0fb5deb7bd63b79d7a1a5
Signed-off-by: Sowmya B <sowmya.b1@samsung.com>
4 years agoSync with spin git 97/208097/3
Seonah Moon [Tue, 18 Jun 2019 07:38:11 +0000 (16:38 +0900)]
Sync with spin git

Change-Id: Iee53b7172a0076ac80ed457704a01a2edd839ba5

4 years ago[DF190411-00679] do not handle empty file in case of redirection 07/206107/3 accepted/tizen/unified/20190605.215711 submit/tizen/20190530.012509
Seonah Moon [Tue, 14 May 2019 08:38:16 +0000 (17:38 +0900)]
[DF190411-00679] do not handle empty file in case of redirection

Each time content size is 0, empty file is created even if status code means redirection.
(https://review.tizen.org/gerrit/#/c/platform/framework/web/download-provider/+/188428/)

Change-Id: I01e2755e912ae32e1c43c6f182356c05702c3d2d

4 years ago[WGID-372659] reassign fd after using close() 95/205595/2 accepted/tizen/unified/20190508.234033 submit/tizen/20190508.040407
Seonah Moon [Wed, 8 May 2019 01:45:10 +0000 (10:45 +0900)]
[WGID-372659] reassign fd after using close()

Change-Id: I45081480991bf144dac2a2945e3e898e0b0856fa

4 years agoRemove unnecessary files 04/205504/1
Seonah Moon [Tue, 7 May 2019 04:05:42 +0000 (13:05 +0900)]
Remove unnecessary files

Change-Id: I6739a6797dd86383d23e1bfb79e3e949c55ed6ba

4 years ago[CID-835380] Access shared data with holding a mutex lock 70/204370/1 accepted/tizen/unified/20190424.112540 submit/tizen/20190423.131710
Seonah Moon [Tue, 23 Apr 2019 09:46:29 +0000 (18:46 +0900)]
[CID-835380] Access shared data with holding a mutex lock

Change-Id: I4cf8077e4c31c6df5f994b890f389c681a9dabd8

5 years ago[DF190403-00436] Allow shared directory as destination path 98/202998/1 accepted/tizen/unified/20190410.002145 submit/tizen/20190408.225946
Seonah Moon [Mon, 8 Apr 2019 12:34:28 +0000 (21:34 +0900)]
[DF190403-00436] Allow shared directory as destination path

Change-Id: Iade2ccfb783fe1475aae2d5b78b4443a9d2ddf2f

5 years agoFix memory leak 39/201639/2 accepted/tizen/unified/20190320.082310 submit/tizen/20190319.071352
Seonah Moon [Mon, 18 Mar 2019 09:09:13 +0000 (18:09 +0900)]
Fix memory leak

Change-Id: I4c16e3d4db431e0b24359bb21694c56403fd1c36

5 years agoDo not call pthread_cancel to terminate an event manager thread 15/201415/2 accepted/tizen/unified/20190315.061251 submit/tizen/20190314.070440
Seonah Moon [Tue, 12 Mar 2019 08:54:14 +0000 (17:54 +0900)]
Do not call pthread_cancel to terminate an event manager thread

Change-Id: I05d840b25ccd59f1bcc30408a86504bc28709f86

5 years ago[Security vulnerability] Prevent null pointer dereference 67/201167/1 accepted/tizen/unified/20190312.113009 submit/tizen/20190312.062500
Seonah Moon [Fri, 8 Mar 2019 07:04:39 +0000 (16:04 +0900)]
[Security vulnerability] Prevent null pointer dereference

Change-Id: I24e3eab7d754cd5c3794a5eff412270ada9b352d

5 years agoGet temp path from download daemon 66/201166/1
Seonah Moon [Fri, 8 Mar 2019 05:06:56 +0000 (14:06 +0900)]
Get temp path from download daemon

Even if app doesn't set temp path,
temp path is updated when download is started.

Change-Id: Ifd624581ca42dc1fac5c5aa6b96ea3874297e736

5 years agoConvert relative path to absolute path 65/201165/1
Seonah Moon [Wed, 6 Mar 2019 08:23:29 +0000 (17:23 +0900)]
Convert relative path to absolute path

Even if relative path is passed from user,
absolute path will be delivered to daemon.

Change-Id: I7616eb27f728bda81de4af6bc97aa5ec3b642f5b

5 years ago[Security vulnerability] Replace strncmp() with strcmp() 49/200849/2
Seonah Moon [Mon, 4 Mar 2019 08:39:05 +0000 (17:39 +0900)]
[Security vulnerability] Replace strncmp() with strcmp()

In case comparing whole string, use strcmp().

Change-Id: Iacb667cacece5eb8a964c8dc2219ff0d17908bf3

5 years ago[Security vulnerability] Access to a symbolic link 48/200848/4
Seonah Moon [Mon, 4 Mar 2019 09:05:02 +0000 (18:05 +0900)]
[Security vulnerability] Access to a symbolic link

Change-Id: I2207dbe4a72d87cd6665fd27dfc97a30b4617b49