Add colorful headlines

This commit is contained in:
maride 2019-11-27 16:49:07 +01:00
parent 62c11bd3ac
commit b13350eac7

View File

@ -2,6 +2,7 @@ package ethernet
import (
"fmt"
"github.com/fatih/color"
"github.com/google/gopacket"
"github.com/google/gopacket/layers"
publicsuffix2 "golang.org/x/net/publicsuffix"
@ -166,7 +167,10 @@ func ipIsPrivate(ip net.IP) bool {
// Print a summary after all DNS packets were processed
func printDNSSummary() {
headline := color.New(color.FgRed, color.Bold)
headline.Println("DNS Request Summary")
printDNSQuestionSummary()
headline.Println("DNS Response Summary")
printDNSAnswerSummary()
}