首页 > 解决方案 > Github 为 R 用户提供的 JavaScript 安全警报

问题描述

我使用 R 并且不熟悉 JavaScript。近日,Github 发出安全警报:

在此处输入图像描述

这与 R 包“迷你图”有关。Github 说:“我们在您的依赖项中发现了潜在的安全漏洞。” 并提到这个文件:static/rmarkdown-libs/jquery-sparkline/package.json

{
  "name": "Sparkline",
  "title": "jQuery Sparkline",
  "description": "Easily generate small, inline sparkline charts directly in the browser",
  "keywords": ["canvas", "charts", "graphics", "graphing", "graphs", "sparklines", "ui", "vml"],
  "banner": "/* jquery.sparkline 2.1.3 - http://omnipotent.net/jquery.sparkline/ \n Licensed under the New BSD License - see above site for details */\n",
  "version": "2.1.4",
  "repository": "git@github.com:relayfoods/jquery.sparkline.git",
  "author": {
    "name": "Gareth Watts",
    "url": "http://gwatts.com/"
  },
  "licenses": [{
    "type": "BSD-3-Clause",
    "url": "http://opensource.org/licenses/BSD-3-Clause"
  }],
  "bugs": "https://github.com/gwatts/jquery.sparkline/issues",
  "homepage": "http://omnipotent.net/jquery.sparkline/",
  "demo": "http://omnipotent.net/jquery.sparkline/",
  "docs": "http://omnipotent.net/jquery.sparkline/#s-docs",
  "download": "http://omnipotent.net/jquery.sparkline/#s-download",
  "dependencies": {
    "jquery": ">=2.1.4"
  },
  "devDependencies": {
    "grunt": "~0.4.5",
    "grunt-contrib-jshint": "~0.11.3",
    "grunt-contrib-uglify": "~0.9.2",
    "grunt-contrib-watch": "~0.6.1",
    "grunt-contrib-concat": "~0.5.1"
  }
}

我尝试使用以下内容更新我的 JavaScript 包:

npm i -g npm-check-updates
npm install

但这对 Github 的警告信息没有影响。我相信“sparkline”包的 v2.0 是来自 CRAN 和 Github 的最新版本。

我可以解决这个问题还是必须由迷你图维护者来完成?

标签: javascriptrgithubnpmgruntjs

解决方案


推荐阅读