| 1 |
% Generated by roxygen2: do not edit by hand |
| 2 |
% Please edit documentation in R/vulns.R |
| 3 |
\name{vulns} |
| 4 |
\alias{vulns} |
| 5 |
\title{Request Vulnerability Information for a Package} |
| 6 |
\usage{ |
| 7 |
vulns( |
| 8 |
packages = NULL, |
| 9 |
lockfile = NULL, |
| 10 |
..., |
| 11 |
repos = NULL, |
| 12 |
verbose = FALSE, |
| 13 |
project = NULL |
| 14 |
) |
| 15 |
} |
| 16 |
\arguments{ |
| 17 |
\item{packages}{A vector of package specifications, of the form |
| 18 |
\verb{<package>==<version>} or \verb{<package>@<version>}.} |
| 19 |
|
| 20 |
\item{lockfile}{The path to an \code{renv} lockfile. When specified, \code{packages} |
| 21 |
is ignored, and vulnerabilities are queried based on the packages defined |
| 22 |
in the lockfile.} |
| 23 |
|
| 24 |
\item{...}{Unused arguments, reserved for future expansion. If any arguments |
| 25 |
are matched to \code{...}, renv will signal an error.} |
| 26 |
|
| 27 |
\item{repos}{The Package Manager repository to be queried.} |
| 28 |
|
| 29 |
\item{verbose}{Boolean; when \code{TRUE}, verbose information from the \code{curl} |
| 30 |
web request will be printed to the console.} |
| 31 |
|
| 32 |
\item{project}{The project directory. If \code{NULL}, then the active project will |
| 33 |
be used. If no project is currently active, then the current working |
| 34 |
directory is used instead.} |
| 35 |
} |
| 36 |
\value{ |
| 37 |
An \R list with one entry per requested package. Each entry |
| 38 |
contains metadata returned by Posit Package Manager (e.g. \code{name}, |
| 39 |
\code{version}, \code{licenses}, \code{blocked}), plus a \code{vulns} field. The \code{vulns} |
| 40 |
field is an empty list when the package has no known vulnerabilities, |
| 41 |
and otherwise holds one or more vulnerability records. |
| 42 |
} |
| 43 |
\description{ |
| 44 |
This function acts as an interface to Posit Package Manager's vulnerability |
| 45 |
API, making it possible to ascertain if the provided packages have any |
| 46 |
known vulnerabilities. |
| 47 |
} |
| 48 |
\details{ |
| 49 |
This function requires the \pkg{curl} package to be installed. |
| 50 |
} |
| 51 |
\keyword{internal} |