Scope first-packet reinjection to kernel mode and drop userspace bind capture

This commit is contained in:
Viktor Liu
2026-06-28 16:37:33 +02:00
parent 3a6d4cfeab
commit 52dd8703fa
5 changed files with 10 additions and 43 deletions
+2 -8
View File
@@ -136,14 +136,8 @@ func (p *ProxyBind) CloseConn() error {
return p.close()
}
// InjectPacket writes b to the remote peer over the underlying transport.
func (p *ProxyBind) InjectPacket(b []byte) error {
if p.remoteConn == nil {
return errors.New("proxy not started")
}
if _, err := p.remoteConn.Write(b); err != nil {
return err
}
// InjectPacket is a no-op for the userspace proxy: first-packet reinjection is kernel-only.
func (p *ProxyBind) InjectPacket(_ []byte) error {
return nil
}