添加dtls支持

This commit is contained in:
bjdgyc
2021-05-21 19:00:23 +08:00
parent 07163aa33b
commit c8f090c9e3
17 changed files with 279 additions and 183 deletions

View File

@@ -55,7 +55,7 @@ func LinkCstp(conn net.Conn, cSess *sessdata.ConnSession) {
return
case 0x03: // DPD-REQ
// base.Debug("recv DPD-REQ", cSess.IpAddr)
if payloadOut(cSess, sessdata.LTypeIPData, 0x04, nil) {
if payloadOutCstp(cSess, sessdata.LTypeIPData, 0x04, nil) {
return
}
case 0x04:
@@ -86,7 +86,7 @@ func cstpWrite(conn net.Conn, cSess *sessdata.ConnSession) {
for {
select {
case payload = <-cSess.PayloadOut:
case payload = <-cSess.PayloadOutCstp:
case <-cSess.CloseChan:
return
}