mirror of
https://github.com/xvzc/SpoofDPI.git
synced 2024-12-22 14:26:31 +00:00
refactor: correction in debugging messages (#238)
* removed typos * converted some words to lower case
This commit is contained in:
parent
2e45975ea9
commit
78b9cdb3c2
@ -85,7 +85,7 @@ func (h *HttpHandler) deliverRequest(ctx context.Context, from *net.TCPConn, to
|
|||||||
pkt.Tidy()
|
pkt.Tidy()
|
||||||
|
|
||||||
if _, err := to.Write(pkt.Raw()); err != nil {
|
if _, err := to.Write(pkt.Raw()); err != nil {
|
||||||
logger.Debug().Msgf("error Writing to %s", td)
|
logger.Debug().Msgf("error writing to %s", td)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -116,7 +116,7 @@ func (h *HttpHandler) deliverResponse(ctx context.Context, from *net.TCPConn, to
|
|||||||
}
|
}
|
||||||
|
|
||||||
if _, err := to.Write(bytesRead); err != nil {
|
if _, err := to.Write(bytesRead); err != nil {
|
||||||
logger.Debug().Msgf("error Writing to %s", td)
|
logger.Debug().Msgf("error writing to %s", td)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -61,7 +61,7 @@ func (h *HttpsHandler) Serve(ctx context.Context, lConn *net.TCPConn, initPkt *p
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.Debug().Msgf("sent connection estabalished to %s", lConn.RemoteAddr())
|
logger.Debug().Msgf("sent connection established to %s", lConn.RemoteAddr())
|
||||||
|
|
||||||
// Read client hello
|
// Read client hello
|
||||||
m, err := packet.ReadTLSMessage(lConn)
|
m, err := packet.ReadTLSMessage(lConn)
|
||||||
@ -118,7 +118,7 @@ func (h *HttpsHandler) communicate(ctx context.Context, from *net.TCPConn, to *n
|
|||||||
}
|
}
|
||||||
|
|
||||||
if _, err := to.Write(bytesRead); err != nil {
|
if _, err := to.Write(bytesRead); err != nil {
|
||||||
logger.Debug().Msgf("error Writing to %s", td)
|
logger.Debug().Msgf("error writing to %s", td)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,11 +2,11 @@ package proxy
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"github.com/xvzc/SpoofDPI/util"
|
|
||||||
"net"
|
"net"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"github.com/xvzc/SpoofDPI/packet"
|
"github.com/xvzc/SpoofDPI/packet"
|
||||||
|
"github.com/xvzc/SpoofDPI/util"
|
||||||
"github.com/xvzc/SpoofDPI/util/log"
|
"github.com/xvzc/SpoofDPI/util/log"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -41,7 +41,7 @@ func (pxy *Proxy) handleHttps(ctx context.Context, lConn *net.TCPConn, exploit b
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.Debug().Msgf("sent connection estabalished to %s", lConn.RemoteAddr())
|
logger.Debug().Msgf("sent connection established to %s", lConn.RemoteAddr())
|
||||||
|
|
||||||
// Read client hello
|
// Read client hello
|
||||||
m, err := packet.ReadTLSMessage(lConn)
|
m, err := packet.ReadTLSMessage(lConn)
|
||||||
|
@ -3,11 +3,11 @@ package proxy
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"errors"
|
"errors"
|
||||||
"github.com/xvzc/SpoofDPI/util"
|
|
||||||
"io"
|
"io"
|
||||||
"net"
|
"net"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"github.com/xvzc/SpoofDPI/util"
|
||||||
"github.com/xvzc/SpoofDPI/util/log"
|
"github.com/xvzc/SpoofDPI/util/log"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -65,7 +65,7 @@ func Serve(ctx context.Context, from *net.TCPConn, to *net.TCPConn, proto string
|
|||||||
}
|
}
|
||||||
|
|
||||||
if _, err := to.Write(bytesRead); err != nil {
|
if _, err := to.Write(bytesRead); err != nil {
|
||||||
logger.Debug().Msgf("error Writing to %s", td)
|
logger.Debug().Msgf("error writing to %s", td)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user