blob: 3de6746f523f59d57fe6ad860ee25b2fe8bddfb4 [file] [log] [blame]
Kristian Monsen5ab50182010-05-14 18:53:44 +01001/***************************************************************************
2 * _ _ ____ _
3 * Project ___| | | | _ \| |
4 * / __| | | | |_) | |
5 * | (__| |_| | _ <| |___
6 * \___|\___/|_| \_\_____|
7 *
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -07008 * Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
Kristian Monsen5ab50182010-05-14 18:53:44 +01009 *
10 * This software is licensed as described in the file COPYING, which
11 * you should have received as part of this distribution. The terms
Alex Deymod15eaac2016-06-28 14:49:26 -070012 * are also available at https://curl.haxx.se/docs/copyright.html.
Kristian Monsen5ab50182010-05-14 18:53:44 +010013 *
14 * You may opt to use, copy, modify, merge, publish, distribute and/or sell
15 * copies of the Software, and permit persons to whom the Software is
16 * furnished to do so, under the terms of the COPYING file.
17 *
18 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
19 * KIND, either express or implied.
20 *
21 ***************************************************************************/
22
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070023#include "curl_setup.h"
Kristian Monsen5ab50182010-05-14 18:53:44 +010024
Alex Deymo486467e2017-12-19 19:04:07 +010025/***********************************************************************
26 * Only for builds using synchronous name resolves
27 **********************************************************************/
28#ifdef CURLRES_SYNCH
29
Kristian Monsen5ab50182010-05-14 18:53:44 +010030#ifdef HAVE_NETINET_IN_H
31#include <netinet/in.h>
32#endif
33#ifdef HAVE_NETDB_H
34#include <netdb.h>
35#endif
36#ifdef HAVE_ARPA_INET_H
37#include <arpa/inet.h>
38#endif
Kristian Monsen5ab50182010-05-14 18:53:44 +010039#ifdef __VMS
40#include <in.h>
41#include <inet.h>
Kristian Monsen5ab50182010-05-14 18:53:44 +010042#endif
43
44#ifdef HAVE_PROCESS_H
45#include <process.h>
46#endif
47
48#include "urldata.h"
49#include "sendf.h"
50#include "hostip.h"
51#include "hash.h"
52#include "share.h"
53#include "strerror.h"
54#include "url.h"
Kristian Monsen5ab50182010-05-14 18:53:44 +010055#include "curl_memory.h"
56/* The last #include file should be: */
57#include "memdebug.h"
58
Kristian Monsen5ab50182010-05-14 18:53:44 +010059/*
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070060 * Function provided by the resolver backend to set DNS servers to use.
Kristian Monsen5ab50182010-05-14 18:53:44 +010061 */
Alex Deymoe3149cc2016-10-05 11:18:42 -070062CURLcode Curl_set_dns_servers(struct Curl_easy *data,
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070063 char *servers)
Kristian Monsen5ab50182010-05-14 18:53:44 +010064{
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070065 (void)data;
66 (void)servers;
67 return CURLE_NOT_BUILT_IN;
68
Kristian Monsen5ab50182010-05-14 18:53:44 +010069}
70
71/*
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070072 * Function provided by the resolver backend to set
73 * outgoing interface to use for DNS requests
Kristian Monsen5ab50182010-05-14 18:53:44 +010074 */
Alex Deymoe3149cc2016-10-05 11:18:42 -070075CURLcode Curl_set_dns_interface(struct Curl_easy *data,
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070076 const char *interf)
Kristian Monsen5ab50182010-05-14 18:53:44 +010077{
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070078 (void)data;
79 (void)interf;
80 return CURLE_NOT_BUILT_IN;
Kristian Monsen5ab50182010-05-14 18:53:44 +010081}
82
83/*
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070084 * Function provided by the resolver backend to set
85 * local IPv4 address to use as source address for DNS requests
Kristian Monsen5ab50182010-05-14 18:53:44 +010086 */
Alex Deymoe3149cc2016-10-05 11:18:42 -070087CURLcode Curl_set_dns_local_ip4(struct Curl_easy *data,
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070088 const char *local_ip4)
Kristian Monsen5ab50182010-05-14 18:53:44 +010089{
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070090 (void)data;
91 (void)local_ip4;
92 return CURLE_NOT_BUILT_IN;
93}
Kristian Monsen5ab50182010-05-14 18:53:44 +010094
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -070095/*
96 * Function provided by the resolver backend to set
97 * local IPv6 address to use as source address for DNS requests
98 */
Alex Deymoe3149cc2016-10-05 11:18:42 -070099CURLcode Curl_set_dns_local_ip6(struct Curl_easy *data,
Bertrand SIMONNETe6cd7382015-07-01 15:39:44 -0700100 const char *local_ip6)
101{
102 (void)data;
103 (void)local_ip6;
104 return CURLE_NOT_BUILT_IN;
Kristian Monsen5ab50182010-05-14 18:53:44 +0100105}
106
107#endif /* truly sync */