search request header field for HTTP basic auth.
(req *http.Request)
| 183 | |
| 184 | // search request header field for HTTP basic auth. |
| 185 | func (h *httpReader) searchForBasicAuth(req *http.Request) { |
| 186 | if u, p, ok := req.BasicAuth(); ok { |
| 187 | if u != "" || p != "" { |
| 188 | secret.WriteSecret(&types.Secret{ |
| 189 | Timestamp: h.conversation.FirstClientPacket.UnixNano(), |
| 190 | Service: "HTTP Basic Auth", |
| 191 | Flow: h.conversation.Ident, |
| 192 | User: u, |
| 193 | Password: p, |
| 194 | }) |
| 195 | } |
| 196 | } |
| 197 | } |
| 198 | |
| 199 | // search for user name and password in http url params and body params. |
| 200 | func (h *httpReader) searchForLoginParams(req *http.Request) { |