add --allow-private-dst support for docker, bot and creator app
This commit is contained in:
1 parent
ca0966bc33
commit
d171a757aa
16 files changed
+129
-32
No files matched your search
+6
-1
@@ -2,6 +2,7 @@ package main
|
||||
|
||||
import (
|
||||
"encoding/binary"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"log"
|
||||
@@ -171,7 +172,11 @@ func (c *dcCreatorRelay) handleUDP(connID uint32, payload []byte) {
|
||||
|
||||
conn, err := common.DialUDP(addr)
|
||||
if err != nil {
|
||||
if common.Debug {
|
||||
if errors.Is(err, common.ErrPrivateDst) {
|
||||
if suppressed, ok := common.ClaimBlockedDstLog(); ok {
|
||||
log.Printf("dc-creator: UDP %d blocked %s, private destinations need --allow-private-dst, suppressed=%d", connID, common.MaskAddr(addr), suppressed)
|
||||
}
|
||||
} else if common.Debug {
|
||||
log.Printf("dc-creator: UDP dial %s failed: %s", common.MaskAddr(addr), common.MaskError(err))
|
||||
}
|
||||
return
|
||||
|
||||
Reference in new issue
Block a user