23 lines
		
	
	
		
			379 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			379 B
		
	
	
	
		
			Go
		
	
	
	
	
	
package tls
 | 
						|
 | 
						|
import (
 | 
						|
	"time"
 | 
						|
 | 
						|
	mdata "github.com/go-gost/core/metadata"
 | 
						|
	mdutil "github.com/go-gost/core/metadata/util"
 | 
						|
)
 | 
						|
 | 
						|
type metadata struct {
 | 
						|
	handshakeTimeout time.Duration
 | 
						|
}
 | 
						|
 | 
						|
func (d *tlsDialer) parseMetadata(md mdata.Metadata) (err error) {
 | 
						|
	const (
 | 
						|
		handshakeTimeout = "handshakeTimeout"
 | 
						|
	)
 | 
						|
 | 
						|
	d.md.handshakeTimeout = mdutil.GetDuration(md, handshakeTimeout)
 | 
						|
 | 
						|
	return
 | 
						|
}
 |