
safeconduct: Fetch Files Through a Real Browser When a Plain Request is Refused
Source:R/safeconduct-package.R
safeconduct-package.RdSome servers refuse any request that does not come from a web browser, with a browser check or a block page instead of the file, 'Cloudflare' being the common case. This package opens a real 'Chrome' with a throwaway profile, lets any check run, and fetches the file or page: through 'curl' carrying the clearance the browser was given where the server accepts that, and through the browser itself where it does not. Nothing is simulated; where a check asks a person to click, a window waits for them. Built on 'chromote'.
Options
Behaviour switches are function arguments, so that nothing leaks between
packages using safeconduct in one R session; the options are these.
safeconduct.browser = FALSE never opens a browser. safeconduct.window
sets the window's size, c(width, height) in pixels (1000 by 800 by
default) or "maximized". Experimentally, safeconduct.focus, a CSS
selector, pins the element holding the check to the window's top left
corner, enlarged by safeconduct.zoom (1.5), and hides the rest of the
page.
Author
Maintainer: Jens von Bergmann jens@mountainmath.ca
Authors:
Jens von Bergmann jens@mountainmath.ca