2 * Copyright (c) 2012 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #ifndef _Download_Agent_Http_Misc_H
18 #define _Download_Agent_Http_Misc_H
22 #include "download-agent-type.h"
24 #define SCHEME_HTTP "http://"
25 #define SCHEME_HTTPS "https://"
26 #define SCHEME_CID "cid:"
28 #define METHOD_GET "GET"
29 #define METHOD_POST "POST"
30 #define METHOD_HEAD "HEAD"
32 #define HTTP_TAG_UAGENT "User-Agent: "
33 #define HTTP_TAG_HOST "Host: "
34 #define HTTP_TAG_UAPROF "X-Wap-Profile: "
35 #define HTTP_TAG_CONTENT_LENGTH "Content-Length: "
36 #define HTTP_TAG_CONTENT_TYPE "Content-Type: "
37 #define HTTP_TAG_IF_MATCH "If-Match: "
38 #define HTTP_TAG_RANGE "Range: "
39 #define HTTP_TAG_IF_RANGE "If-Range: "
41 #define END_OF_FIELD "\r\n"
43 char *get_user_agent();
45 da_bool_t is_supporting_protocol(const char *protocol);