The open vulnerability backlog as package upgrades
curl --request GET \
--url https://app.trustivan.com/api/v1/findings/upgrades \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.trustivan.com/api/v1/findings/upgrades"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.trustivan.com/api/v1/findings/upgrades', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trustivan.com/api/v1/findings/upgrades"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"upgrades": [
{
"asset_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"ecosystem": "npm",
"package": "lodash",
"installed_version": "4.17.15",
"path": "<string>",
"target_version": "<string>",
"crosses_major": true,
"fixes": 123,
"fixed_finding_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"fixed_advisories": [
"<string>"
],
"unfixed_finding_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"unfixed_advisories": [
"<string>"
],
"worst_severity": "<string>",
"max_risk_score": 123,
"manifest_change": {
"manifest": "app/package.json",
"line": "\"lodash\": \"4.17.21\"",
"command": "npm install lodash@4.17.21",
"note": "<string>"
},
"note": "<string>"
}
],
"findings_considered": 123,
"findings_fixable": 123,
"truncated": true,
"method": "<string>"
}{
"error": "<string>",
"code": "validation_failed",
"required_scope": "<string>",
"principal": "user"
}The open vulnerability backlog as package upgrades
Groups the open, triaged and reopened vulnerability findings by package copy (asset, ecosystem, package, installed version and the manifest it was found in) and, for each, gives the smallest version that clears every finding on it that has a recorded fix: “upgrade lodash to 4.17.21 fixes 3 findings”.
The target is chosen from the fixed versions the advisories record,
ordered with the ecosystem’s own version rules, preferring a fix on
the installed major line when an advisory lists one per line. The
package registry is never consulted. A finding whose advisory
records no fix is listed in unfixed_*, never counted. Riskiest
first; reads at most 20000 findings, riskiest first, and says
truncated when there were more.
GET
/
findings
/
upgrades
The open vulnerability backlog as package upgrades
curl --request GET \
--url https://app.trustivan.com/api/v1/findings/upgrades \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.trustivan.com/api/v1/findings/upgrades"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.trustivan.com/api/v1/findings/upgrades', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trustivan.com/api/v1/findings/upgrades"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"upgrades": [
{
"asset_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"ecosystem": "npm",
"package": "lodash",
"installed_version": "4.17.15",
"path": "<string>",
"target_version": "<string>",
"crosses_major": true,
"fixes": 123,
"fixed_finding_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"fixed_advisories": [
"<string>"
],
"unfixed_finding_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"unfixed_advisories": [
"<string>"
],
"worst_severity": "<string>",
"max_risk_score": 123,
"manifest_change": {
"manifest": "app/package.json",
"line": "\"lodash\": \"4.17.21\"",
"command": "npm install lodash@4.17.21",
"note": "<string>"
},
"note": "<string>"
}
],
"findings_considered": 123,
"findings_fixable": 123,
"truncated": true,
"method": "<string>"
}{
"error": "<string>",
"code": "validation_failed",
"required_scope": "<string>",
"principal": "user"
}