Skip to content

Commit

Permalink
Change mitm mode back to connect
Browse files Browse the repository at this point in the history
  • Loading branch information
gunnargrosch committed Oct 21, 2020
1 parent 53b2ee8 commit c080f7a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ Inspired by Yan Cui's articles on latency injection for AWS Lambda (https://hack

## Changelog

### 2020-10-21 v0.3.1

* Change mitm mode back to connect to fix issue with all connections being blocked.

### 2020-08-24 v0.3.0

* Changed mitm mode from connect to connection for quicker enable/disable of failure injection.
Expand Down
2 changes: 1 addition & 1 deletion lib/failure.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ var injectFailure = function (fn) {
config.denylist.forEach(function (regexStr) {
blRegexs.push(new RegExp(regexStr))
})
mitm.on('connection', function (socket, opts) {
mitm.on('connect', function (socket, opts) {
let block = false
blRegexs.forEach(function (blRegex) {
if (blRegex.test(opts.host)) {
Expand Down

0 comments on commit c080f7a

Please sign in to comment.