close-issue-app
close-issue-app copied to clipboard
fix(deps): update dependency probot to v12 [security]
This PR contains the following updates:
| Package | Change | Age | Confidence |
|---|---|---|---|
| probot (source) | 9.15.1 -> 12.3.3 |
GitHub Vulnerability Alerts
CVE-2023-50728
Impact
Versions v9.26.0, v10.9.x), v11.1.x, v12.0.x all contained the code that would throw the error.
Specifically, during a pentest we encountered a bug in the octokit/webhooks library (a dependency of Probot, a framework for building Github Apps). The resulting request was found to cause an uncaught exception that ends the nodejs process.
The problem is caused by an issue with error handling in the @octokit/webhooks library because the error can be undefined in some cases.
Credit goes to @pb82 (for the early analysis) and @rh-tguittet (for discovery).
Patches
Maintenance releases for the Error being thrown by the verify method in octokit/webhooks.js
Maintenance release for the reference for octokit/webhooks.js in app.js
Maintenance release for the reference for octokit/webhooks.js in octokit.js
Maintenance release for the reference for octokit/webhooks.js in Protobot
Workarounds
It is recommend that all users upgrade to the latest version of octokit/webhooks.js or use one of the updated back ported versions.
Release Notes
probot/probot (probot)
v12.3.3
Bug Fixes
v12.3.2
Bug Fixes
v12.3.1
Bug Fixes
v12.3.0
Features
v12.2.9
Bug Fixes
v12.2.8
Bug Fixes
v12.2.7
Bug Fixes
v12.2.6
Bug Fixes
v12.2.5
Bug Fixes
- remove update-notifier (#1706) (05297fb), closes /github.com/probot/probot/issues/1102#issuecomment-570598406
v12.2.4
Bug Fixes
- logging of first octokit instance is not set (#1676) - thanks @kammerjaeger @markjm (646b6a9)
v12.2.3
Bug Fixes
- deps: bump eventsource from 1.1.0 to 2.0.2 (7fd06d6)
v12.2.2
Bug Fixes
v12.2.1
Bug Fixes
v12.2.0
Features
- customize account name for manifest creation flow using
GH_ORGenvironment variable (#1606) (992b480)
v12.1.4
Bug Fixes
v12.1.3
Bug Fixes
v12.1.2
Bug Fixes
v12.1.1
Bug Fixes
v12.1.0
Features
v12.0.0
Features
BREAKING CHANGES
- remove '*' event
- app.webhooks.middleware has been removed in
@octokit/webhooksv9 - removes the
webhookPathoption onnew Probot({})for the webhooks middleware
v11.4.1
Bug Fixes
v11.4.0
Features
v11.3.2
Bug Fixes
v11.3.1
Bug Fixes
v11.3.0
Features
v11.2.4
Bug Fixes
v11.2.3
Bug Fixes
v11.2.2
Bug Fixes
v11.2.1
Bug Fixes
v11.2.0
Features
v11.1.1
Bug Fixes
v11.1.0
Features
v11.0.6
Bug Fixes
- deps: pin version of @octokit/webhooks (#1472) (cd14dd4)
v11.0.5
Bug Fixes
v11.0.4
Bug Fixes
v11.0.3
Bug Fixes
- correctly import (transpiled) app function for run and receive (#1457) thanks @ZauberNerd (2275698)
v11.0.2
Bug Fixes
v11.0.1
Bug Fixes
v11.0.0
BREAKING CHANGES
For a smooth upgrade, make sure to update to the latest Probot v10 version first (npm install probot@10), run your tests, and address all deprecation messages. Nearly all removed APIs have previously been deprecated.
-
deprecated
context.octokit.*have been removed via@octokit/plugin-rest-endpoint-methodsv4 -
probot.serverproperty removed. Build your own server instead usingimport { Server } from "probot" -
probot.load()is now asynchronous and no longer returns the instance -
express-async-errorsis no longer used. -
Probotconstructor parameter no longer supported increateNodeMiddleware(app, { Probot }). Pass aprobotinstance instead:createNodeMiddleware(app, { probot }) -
getOptions()has been removed. Use{ probot: createProbot() }instead -
probot.load(appFn)no longer acceptsappFnto be a path string. Pass the actual function instead. -
probot.setup()removed. Use the newServerclass instead:const { Server, Probot } = require("probot") const server = new Server({ // optional: host, port, webhookPath, webhookProxy, Probot: Probot.defaults({ id, privateKey, ... }) }) // load probot app function await server.load((app) => {}) // start listening to requests await server.start() // stop server with: await server.stop()If you have more than one app function, combine them in a function instead
const app1 = require("./app1") const app2 = require("./app2") module.exports = function app ({ probot, getRouter }) { await app1({ probot, getRouter }) await app2({ probot, getRouter }) } -
probot.start()/probot.stop()removed. Use the newServerclass instead:const { Server, Probot } = require("probot") const server = new Server({ Probot: Probot.defaults({ id, privateKey, ... }) // optional: host, port, webhookPath, webhookProxy, }) // load probot app function await server.load((app) => {}) // start listening to requests await server.start() // stop server with: await server.stop() -
REDIS_URLis ignored when usingProbotconstructor. Usenew Probot({ redisConfig: redis://... })instead -
Probotconstructor no longer reads environment variables. Pass options instead, orimport { createProbot } from "probot"instead -
Probot.run()has been removed. Useimport { run} from "probot"instead -
context.githubhas been removed. Usecontext.octokitinstead -
context.eventhas been removed. Usecontext.nameinstead -
app.route()has been removed. Use thegetRouter()argument from the app function instead:(app, { getRouter }) => { ... } -
app.routerhas been removed. UsegetRouter()from the app function instead:(app, { getRouter }) => { ... } -
probot.loggerhas been removed. Useprobot.loginstead -
new Probot({ id })has been removed. Usenew Probot({ appId })instead -
new Probot({ cert })has been removed. Usenew Probot({ privateKey })instead -
probot.webhookhas been removed. Useprobot.webhooksinstead -
createProbot(options)no longer supports any keys besidesoverrides,defaults, orenv -
options.throttleOptionshas been removed. Setoptions.OctokittoProbotOctokit.defaults({ throttle })instead -
import { Application } from probothas been removed. Useimport { Probot } from probotinstead, the APIs are the same
v10.19.0
Features
- un-deprecate
(app) => {}. Deprecate({ app, getRouter }) => {}in favor of(app, { getRouter }) => {}(#1441) (42b043e), closes /github.com/probot/probot/issues/1286#issuecomment-744094299
v10.18.0
Features
createProbot()(#1431) (d315f0c)new Probot({ appId })(a94fdca)Probot.version,Probot.defaults()(2ff5d21)run(appFn, { env })(3d90806)- createNodeMiddleware (bdbe94e)
- use new
Serverclass when usingprobot runbinary (8a3599d)
Deprecations
probot.load()(3d4b363)probot.start()/probot.stop()/probot.setup()(7a8f268)- Deprecates
new Probot({ id })(a94fdca)
Bug Fixes
- `createProbot() without options (8c01e90)
- load app function only once when using createNodeMiddleware (#1432) (60b702b)
- server: log error requests as
[METHOD] /[PATH] [STATUS] - [NUM]ms, e.gPOST / 500 - 123ms(9d767e1)
v10.17.3
Bug Fixes
v10.17.2
Bug Fixes
v10.17.1
Bug Fixes
- set default log level correctly to
"info"(49153b8)
v10.17.0
Features
import { run } from "probot". Deprecates Probot.run() (f35b58a)new Probot({ baseUrl }). DeprecatesGHE_HOST/GHE_PROTOCOLwhen using with theProbotconstructor (7abbef7)new Probot({ logLevel }). DeprecatesLOG_LEVELwhen usingProbotconstructor (7c46218)- deprecate
INSTALLATION_TOKEN_TTL(dfc59fc) - deprecate
LOG_FORMAT,LOG_LEVEL_IN_STRING,SENTRY_DSNenvironment variables when usingProbotconstructor. Pass a custom log instance instead: (514c764) - deprecate
REDIS_URLenvironment variable when using with theProbotconstructor. Usenew Probot({ redisConfig: "redis://..." })instead (1dbd999)
v10.16.0
Features
v10.15.0
Features
v10.14.1
Bug Fixes
v10.14.0
Features
- deprecate
{ Application }export. Use{ Probot }instead, it has the same APIs now. (#1408) (0e52e05)
v10.13.0
Features
v10.12.0
Features
v10.11.0
Features
v10.10.2
Bug Fixes
- stop using
.webhooks.on("*", handler)in favor of `.webhooks.onAny(handler) (ab6fcb1)
v10.10.1
Bug Fixes
v10.10.0
Features
v10.9.5
Bug Fixes
v10.9.4
Bug Fixes
v10.9.3
Bug Fixes
- types: set correct type for
contextpassed to event handler (#1378) (05abeef), closes #r501871740
v10.9.2
Bug Fixes
v10.9.1
Bug Fixes
- do not overwrite
options.throttlepassed to{Octokit: ProbotOctokit.defaults(options)}(#1373) (9483546)
v10.9.0
Features
v10.8.1
Bug Fixes
-
use
@probot/octokit-plugin-configforcontext.config(#1362) (a235671)If you mocked http requests for configuration files, you will have to adapt them. Instead of returning a JSON response with a
{ content }object, wherecontentis a base64 encoded version of your raw configuration, you can now return the content without encoding directly. ExampleBefore
nock("https://api.github.com") .get("/repos/wip/app/contents/.github%2Fwip.yml") .reply(200, { content: Buffer.from("terms: 🚧").toString("base64"), });After
nock("https://api.github.com") .get("/repos/wip/app/contents/.github%2Fwip.yml") .reply(200, "terms: 🚧");
v10.8.0
Features
v10.7.1
Bug Fixes
v10.7.0
Features
v10.6.0
Features
v10.5.0
Features
v10.4.1
Bug Fixes
v10.4.0
Features
v10.3.0
Features
v10.2.0
Features
- sentry: set user ID to
installation.idand username to repository owner login (when present) (#1337) (4cf7de9)
v10.1.5
Bug Fixes
v10.1.4
Bug Fixes
- prevent double new lines when using
LOG_FORMAT=json(86c1973)
v10.1.3
Bug Fixes
v10.1.2
Bug Fixes
- trigger release to update docs on probot.github.com (4c88da9)
v10.1.1
v10 release notes
This is the first stable release for v10. See all breaking changes and new features at https://github.com/probot/probot/releases/tag/v10.0.0
Bug Fixes
app.auth(installationId)returnsoctokitinstance with all required installation authentication settings (#1326) (410302f)
v10.1.0
Features
v10.0.1
Bug Fixes
v10.0.0
Breaking changes
-
@octokit/resthas been updated from v16 to v17. See release notes. Important: If you currently mockedcontext.github.*methods in your test, replace these with http mocks using nock instead, otherwise your tests will create methods that no longer exist and you will see errors in production although your tests passed. See wip/app#238 for an example -
URL parameters are now always encoded when using
context.github.*methods. For example, if you usecontext.github.repos.getContent( owner, repo, path )make sure to not encode the value forpath. Also if you were mocking http requests in your tests, replace e.g.repos/octocat/hello-world/contents/.github/config.ymlwithrepos/octocat/hello-world/contents/.github%2Fconfig.yml -
require Node 10.21+
-
Logging: an object with extra information must be passed as first argument. Passing it as last argument is no longer supported.
before
context.log.info('something happened', {extra: 'info'})after
context.log.info({extra: 'info'}, 'something happened') -
The logging output changed. Before, probot used bunyan with all kind of hacks and customizations for its log output. Now we use pino. We still do the formatting and sending errors to Sentry in the same process, but the logic is now encapsulated in
@probot/pino. We might decouple it in future as part of making Probot more suitable for serverless/function environments -
context.issue()now returns.issue_numberinstead of.number. Usecontext.pullRequest()foroctokit.pulls.*method calls. -
registry_packageevent was renamed topackage -
The
probotpackage no longer exportsOctokit. UseProbotOctokitinstead.const { ProbotOctokit, ProbotOctokitCore } = require('probot') -
Probotno longer acceptsoptions.throttlingOptions. In order to disable throttling for testing, setoptions.OctokittoProbotOctokit.defaults({ retry: { enabled: false }, throttle: { enabled: false } }):const { Probot, ProbotOctokit } = require('probot') const probot = new Probot({ Octokit: ProbotOctokit.defaults({ retry: { enabled: false }, throttle: { enabled: false } }) }) -
Undocumented & untested APIs removed
probot.errorHandlerprobot.httpServerapp.log.targethas been removed.routeroption forApplicationcontructor:new Application({ router })
Features

- Significant lower memory usage
- update to
@octokit/restto v17 - update to
@octokit/webhooksto v7 context.pullRequest()probot.log(probot.loggeris now deprecated)probot.stop()(Replaces undocumentedprobot.httpServer)- replace
bunyanwithpinofor logging - use a single Octokit instance with JWT auth
Bug Fixes
- use JWT auth for marketplace endpoints
Configuration
📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
- [ ] If you want to rebase/retry this PR, check this box
This PR was generated by Mend Renovate. View the repository job log.