This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Installing TOR on mac: brew install tor | |
# Run TOR on custom port: tor --SOCKSPort 9050 | |
# Check the 'origin' field in the response to verify TOR is working. | |
library(httr) | |
GET("https://httpbin.org/get", use_proxy("socks5://localhost:9050")) | |
# Set proxy in curl | |
library(curl) | |
h <- new_handle(proxy = "socks5://localhost:9050") |