mirror of
				https://github.com/TeaOSLab/EdgeCommon.git
				synced 2025-11-04 05:00:24 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			23 lines
		
	
	
		
			595 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			595 B
		
	
	
	
		
			Go
		
	
	
	
	
	
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
 | 
						|
 | 
						|
package dnsconfigs
 | 
						|
 | 
						|
type DNSHost struct {
 | 
						|
	Host     string `json:"host"`
 | 
						|
	Port     int    `json:"port"`
 | 
						|
	Protocol string `json:"protocol"`
 | 
						|
}
 | 
						|
 | 
						|
// RecursionConfig 递归DNS设置
 | 
						|
type RecursionConfig struct {
 | 
						|
	IsOn          bool       `json:"isOn"`
 | 
						|
	Hosts         []*DNSHost `json:"hosts"`
 | 
						|
	UseLocalHosts bool       `json:"useLocalHosts"` // 自动从本机读取DNS
 | 
						|
	AllowDomains  []string   `json:"allowDomains"`
 | 
						|
	DenyDomains   []string   `json:"denyDomains"`
 | 
						|
}
 | 
						|
 | 
						|
func (this *RecursionConfig) Init() error {
 | 
						|
	return nil
 | 
						|
}
 |