mirror of
https://github.com/miekg/dns.git
synced 2025-10-14 19:31:01 +02:00
nicer verbose output
This commit is contained in:
parent
c44591ab85
commit
05a23e25e1
@ -79,7 +79,8 @@ func doFunkensturm(i []byte) ([]byte, os.Error) {
|
|||||||
}
|
}
|
||||||
if *verbose {
|
if *verbose {
|
||||||
fmt.Printf(">>>>>> ORIGINAL INCOMING\n")
|
fmt.Printf(">>>>>> ORIGINAL INCOMING\n")
|
||||||
fmt.Printf("%v\n", pkt)
|
fmt.Printf("%v", pkt)
|
||||||
|
fmt.Printf("<<<<<< ORIGINAL INCOMING\n")
|
||||||
}
|
}
|
||||||
if pkt.MsgHdr.Response == true {
|
if pkt.MsgHdr.Response == true {
|
||||||
return nil, &dns.Error{Error: "Response bit set, not replying"}
|
return nil, &dns.Error{Error: "Response bit set, not replying"}
|
||||||
@ -101,7 +102,8 @@ func doFunkensturm(i []byte) ([]byte, os.Error) {
|
|||||||
}
|
}
|
||||||
if *verbose {
|
if *verbose {
|
||||||
fmt.Printf(">>>>>> MODIFIED INCOMING\n")
|
fmt.Printf(">>>>>> MODIFIED INCOMING\n")
|
||||||
fmt.Printf("%v\n", pkt1)
|
fmt.Printf("%v", pkt1)
|
||||||
|
fmt.Printf("<<<<<< MODIFIED INCOMING\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
// Loop through the Actions.Func* and do something with the
|
// Loop through the Actions.Func* and do something with the
|
||||||
@ -118,7 +120,8 @@ func doFunkensturm(i []byte) ([]byte, os.Error) {
|
|||||||
|
|
||||||
if *verbose {
|
if *verbose {
|
||||||
fmt.Printf(">>>>>> ORIGINAL OUTGOING\n")
|
fmt.Printf(">>>>>> ORIGINAL OUTGOING\n")
|
||||||
fmt.Printf("%v\n", resultpkt)
|
fmt.Printf("%v", resultpkt)
|
||||||
|
fmt.Printf("<<<<<< ORIGINAL OUTGOING\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
// loop again for matching, but now with OUT, this is done
|
// loop again for matching, but now with OUT, this is done
|
||||||
@ -132,7 +135,8 @@ func doFunkensturm(i []byte) ([]byte, os.Error) {
|
|||||||
|
|
||||||
if *verbose {
|
if *verbose {
|
||||||
fmt.Printf(">>>>>> MODIFIED OUTGOING\n")
|
fmt.Printf(">>>>>> MODIFIED OUTGOING\n")
|
||||||
fmt.Printf("%v\n", pkt1)
|
fmt.Printf("%v", pkt1)
|
||||||
|
fmt.Printf("<<<<<< MODIFIED OUTGOING\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
out, ok1 := pkt1.Pack()
|
out, ok1 := pkt1.Pack()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user