Documentation ¶
Index ¶
- func CheckIp(ipStr string) bool
- func GetIpByDomain(hostname string) (string, error)
- func GetSafeURL(inputUrl string, innerHosts ...string) (r string, errorReturn error)
- func InetAton(ipStr string) int64
- func InetNtoa(ipnr int64) net.IP
- func IsInnerIp(ipStr string, innerHosts ...string) bool
- func NewSafeClient(innerIpv4Nets ...Ipv4Net) *http.Client
- func SafeCurl(untrustedURL string, innerIpv4Nets ...Ipv4Net) *http.Response
- type Ipv4Net
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetSafeURL ¶
GetSafeURL 校验URL的安全性
func NewSafeClient ¶
NewSafeClient 安全的HTTP请求客户端
Types ¶
Click to show internal directories.
Click to hide internal directories.