Skip to content

Commit

Permalink
Merge pull request #108 from bugsnag/release-v1.4.1
Browse files Browse the repository at this point in the history
Release v1.4.1
  • Loading branch information
kinbiko committed Mar 18, 2019
2 parents 834d8fe + e88ab59 commit 939b556
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 4 deletions.
2 changes: 0 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ jobs:
go: "1.10"
- script: make ci
go: "1.11"
- script: make ci
go: "master"

- stage: plain go app tests
script: make testplain
Expand Down
15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
# Changelog

## 1.4.1 (2019-03-18)

This release fixes a compilation error on Windows.
Due to a missing implementation in the Go library, Windows users may have to send two interrupt signals to interrupt the application. Other signals are unaffected.

Additionally, ensure data sanitisation behaves the same for both request data and metadata.

### Bug fixes

* Use the `os` package instead of `syscall` to re-send signals, as `syscall` varies per platform, which caused a compilation error.

* Make sure that all data sanitization using `Config.ParamsFilters` behaves the same.
[#104](https://github.com/bugsnag/bugsnag-go/pull/104)
[Adam Renberg Tamm](https://github.com/tgwizard)

## 1.4.0 (2018-11-19)

This release is a big non-breaking revamp of the notifier. Most importantly, this release introduces session tracking to Go applications.
Expand Down
2 changes: 1 addition & 1 deletion request_extractor.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func parseRequestHeaders(header map[string][]string) map[string]string {

func contains(slice []string, e string) bool {
for _, s := range slice {
if strings.ToLower(s) == strings.ToLower(e) {
if strings.Contains(strings.ToLower(e), strings.ToLower(s)) {
return true
}
}
Expand Down
1 change: 1 addition & 0 deletions request_extractor_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ func TestParseHeadersWillSanitiseIllegalParams(t *testing.T) {
headers["password"] = []string{"correct horse battery staple"}
headers["secret"] = []string{"I am Banksy"}
headers["authorization"] = []string{"licence to kill -9"}
headers["custom-made-secret"] = []string{"I'm the insider at Sotheby's"}
for k, v := range parseRequestHeaders(headers) {
if v != "[FILTERED]" {
t.Errorf("expected '%s' to be [FILTERED], but was '%s'", k, v)
Expand Down
7 changes: 6 additions & 1 deletion sessions/tracker.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,12 @@ func (s *sessionTracker) flushSessionsAndRepeatSignal(shutdown chan<- os.Signal,
s.config.logf("%v", err)
}
}
syscall.Kill(syscall.Getpid(), sig)

if p, err := os.FindProcess(os.Getpid()); err != nil {
s.config.logf("%v", err)
} else {
p.Signal(sig)
}
}

func (s *sessionTracker) FlushSessions() {
Expand Down

0 comments on commit 939b556

Please sign in to comment.