mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 02:36:57 -07:00
Merge pull request #752 from denandz/master
Make domain matches in the dns.spoof module case insensitive
This commit is contained in:
commit
b1381568d0
1 changed files with 2 additions and 1 deletions
|
@ -22,7 +22,8 @@ type HostEntry struct {
|
|||
}
|
||||
|
||||
func (e HostEntry) Matches(host string) bool {
|
||||
return e.Host == host || strings.HasSuffix(host, e.Suffix) || (e.Expr != nil && e.Expr.Match(host))
|
||||
lowerHost := strings.ToLower(host)
|
||||
return e.Host == lowerHost || strings.HasSuffix(lowerHost, e.Suffix) || (e.Expr != nil && e.Expr.Match(lowerHost))
|
||||
}
|
||||
|
||||
type Hosts []HostEntry
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue