Skip to content

Commit

Permalink
fix merge issue
Browse files Browse the repository at this point in the history
  • Loading branch information
奶爸 committed May 8, 2018
1 parent c9c9d98 commit 3e1bb69
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
2 changes: 1 addition & 1 deletion bitbucket/bitbucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const (
PullRequestDeclinedEvent Event = "pullrequest:rejected"
PullRequestCommentCreatedEvent Event = "pullrequest:comment_created"
PullRequestCommentUpdatedEvent Event = "pullrequest:comment_updated"
PullRequestCommentDeletedEvent Event = "pull_request:comment_deleted"
PullRequestCommentDeletedEvent Event = "pullrequest:comment_deleted"
)

// New creates and returns a WebHook instance denoted by the Provider type
Expand Down
4 changes: 0 additions & 4 deletions gogs/gogs.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,6 @@ func (hook Webhook) ParsePayload(w http.ResponseWriter, r *http.Request) {
expectedMAC := hex.EncodeToString(mac.Sum(nil))

if !hmac.Equal([]byte(signature), []byte(expectedMAC)) {
webhooks.DefaultLog.Error("HMAC verification failed")
webhooks.DefaultLog.Debug("LocalHMAC:" + expectedMAC)
webhooks.DefaultLog.Debug("RemoteHMAC:" + signature)
webhooks.DefaultLog.Debug("Secret:" + hook.secret)
webhooks.DefaultLog.Debug(string(payload))
http.Error(w, "403 Forbidden - HMAC verification failed", http.StatusForbidden)
return
Expand Down

0 comments on commit 3e1bb69

Please sign in to comment.