1*6236dae4SAndroid Build Coastguard Worker--- 2*6236dae4SAndroid Build Coastguard Workerc: Copyright (C) Daniel Stenberg, <[email protected]>, et al. 3*6236dae4SAndroid Build Coastguard WorkerSPDX-License-Identifier: curl 4*6236dae4SAndroid Build Coastguard WorkerLong: resolve 5*6236dae4SAndroid Build Coastguard WorkerArg: <[+]host:port:addr[,addr]...> 6*6236dae4SAndroid Build Coastguard WorkerHelp: Resolve host+port to address 7*6236dae4SAndroid Build Coastguard WorkerAdded: 7.21.3 8*6236dae4SAndroid Build Coastguard WorkerCategory: connection dns 9*6236dae4SAndroid Build Coastguard WorkerMulti: append 10*6236dae4SAndroid Build Coastguard WorkerSee-also: 11*6236dae4SAndroid Build Coastguard Worker - connect-to 12*6236dae4SAndroid Build Coastguard Worker - alt-svc 13*6236dae4SAndroid Build Coastguard WorkerExample: 14*6236dae4SAndroid Build Coastguard Worker - --resolve example.com:443:127.0.0.1 $URL 15*6236dae4SAndroid Build Coastguard Worker--- 16*6236dae4SAndroid Build Coastguard Worker 17*6236dae4SAndroid Build Coastguard Worker# `--resolve` 18*6236dae4SAndroid Build Coastguard Worker 19*6236dae4SAndroid Build Coastguard WorkerProvide a custom address for a specific host and port pair. Using this, you 20*6236dae4SAndroid Build Coastguard Workercan make the curl requests(s) use a specified address and prevent the 21*6236dae4SAndroid Build Coastguard Workerotherwise normally resolved address to be used. Consider it a sort of 22*6236dae4SAndroid Build Coastguard Worker/etc/hosts alternative provided on the command line. The port number should be 23*6236dae4SAndroid Build Coastguard Workerthe number used for the specific protocol the host is used for. It means 24*6236dae4SAndroid Build Coastguard Workeryou need several entries if you want to provide address for the same host but 25*6236dae4SAndroid Build Coastguard Workerdifferent ports. 26*6236dae4SAndroid Build Coastguard Worker 27*6236dae4SAndroid Build Coastguard WorkerBy specifying `*` as host you can tell curl to resolve any host and specific 28*6236dae4SAndroid Build Coastguard Workerport pair to the specified address. Wildcard is resolved last so any --resolve 29*6236dae4SAndroid Build Coastguard Workerwith a specific host and port is used first. 30*6236dae4SAndroid Build Coastguard Worker 31*6236dae4SAndroid Build Coastguard WorkerThe provided address set by this option is used even if --ipv4 or --ipv6 is 32*6236dae4SAndroid Build Coastguard Workerset to make curl use another IP version. 33*6236dae4SAndroid Build Coastguard Worker 34*6236dae4SAndroid Build Coastguard WorkerBy prefixing the host with a '+' you can make the entry time out after curl's 35*6236dae4SAndroid Build Coastguard Workerdefault timeout (1 minute). Note that this only makes sense for long running 36*6236dae4SAndroid Build Coastguard Workerparallel transfers with a lot of files. In such cases, if this option is used 37*6236dae4SAndroid Build Coastguard Workercurl tries to resolve the host as it normally would once the timeout has 38*6236dae4SAndroid Build Coastguard Workerexpired. 39*6236dae4SAndroid Build Coastguard Worker 40*6236dae4SAndroid Build Coastguard WorkerTo redirect connects from a specific hostname or any hostname, independently 41*6236dae4SAndroid Build Coastguard Workerof port number, consider the --connect-to option. 42*6236dae4SAndroid Build Coastguard Worker 43*6236dae4SAndroid Build Coastguard WorkerSupport for resolving with wildcard was added in 7.64.0. 44*6236dae4SAndroid Build Coastguard Worker 45*6236dae4SAndroid Build Coastguard WorkerSupport for the '+' prefix was added in 7.75.0. 46