mirror of
https://github.com/fatedier/frp.git
synced 2025-07-16 10:51:45 +07:00
TlsOnly - only accept TLS connections if enabled
This commit is contained in:
@ -284,7 +284,7 @@ func (svr *Service) HandleListener(l net.Listener) {
|
||||
|
||||
log.Trace("start check TLS connection...")
|
||||
originConn := c
|
||||
c, err = frpNet.CheckAndEnableTLSServerConnWithTimeout(c, svr.tlsConfig, connReadTimeout)
|
||||
c, err = frpNet.CheckAndEnableTLSServerConnWithTimeout(c, svr.tlsConfig, svr.cfg.TlsOnly, connReadTimeout)
|
||||
if err != nil {
|
||||
log.Warn("CheckAndEnableTLSServerConnWithTimeout error: %v", err)
|
||||
originConn.Close()
|
||||
|
Reference in New Issue
Block a user