diff --git a/peer/peer.go b/peer/peer.go index 70484f09..3d4c2baa 100644 --- a/peer/peer.go +++ b/peer/peer.go @@ -1576,10 +1576,6 @@ out: } case *wire.MsgAlert: - // Note: The reference client currently bans peers that send alerts - // not signed with its key. We could verify against their key, but - // since the reference client is currently unwilling to support - // other implementions' alert messages, we will not relay theirs. if p.cfg.Listeners.OnAlert != nil { p.cfg.Listeners.OnAlert(p, msg) } diff --git a/server.go b/server.go index f21f59ff..ced9387a 100644 --- a/server.go +++ b/server.go @@ -1387,6 +1387,12 @@ func newPeerConfig(sp *serverPeer) *peer.Config { OnAddr: sp.OnAddr, OnRead: sp.OnRead, OnWrite: sp.OnWrite, + + // Note: The reference client currently bans peers that send alerts + // not signed with its key. We could verify against their key, but + // since the reference client is currently unwilling to support + // other implementions' alert messages, we will not relay theirs. + OnAlert: nil, }, NewestBlock: sp.server.db.NewestSha, BestLocalAddress: sp.server.addrManager.GetBestLocalAddress,