feat: Expose remote destination (udp proxy maybe domain of node)

This commit is contained in:
Skyxim
2022-05-04 16:57:08 +08:00
parent bdfa16ca6f
commit fb58595d44
9 changed files with 66 additions and 18 deletions

View File

@ -86,8 +86,12 @@ type Metadata struct {
Uid *int32 `json:"uid"`
Process string `json:"process"`
ProcessPath string `json:"processPath"`
RemoteDst string `json:"remoteDestination"`
}
// avoid stack overflow
type jsonMetadata Metadata
func (m *Metadata) RemoteAddress() string {
return net.JoinHostPort(m.String(), m.DstPort)
}