1pub const SQL_INJECTION: &str = include_str!("../payloads/sql_injection.txt");
8
9pub const XSS: &str = include_str!("../payloads/xss.txt");
11
12pub const SSRF: &str = include_str!("../payloads/ssrf.txt");
14
15pub const XXE: &str = include_str!("../payloads/xxe.txt");
17
18pub const COMMAND_INJECTION: &str = include_str!("../payloads/command_injection.txt");
20
21pub const LFI: &str = include_str!("../payloads/lfi.txt");
23
24pub const NOSQL_INJECTION: &str = include_str!("../payloads/nosql_injection.txt");
26
27pub const SSTI: &str = include_str!("../payloads/ssti.txt");
29
30pub const AUTH_BYPASS_HEADERS: &str = include_str!("../payloads/auth_bypass_headers.txt");
32
33pub const API_ENDPOINTS: &str = include_str!("../payloads/api_endpoints.txt");
35
36pub fn lines(payload: &str) -> Vec<&str> {
38 payload
39 .lines()
40 .map(|l| l.trim())
41 .filter(|l| !l.is_empty() && !l.starts_with('#'))
42 .collect()
43}
44
45pub fn auth_headers(payload: &str) -> Vec<(&str, &str)> {
47 lines(payload)
48 .into_iter()
49 .filter_map(|l| {
50 let idx = l.find(':')?;
51 let name = l[..idx].trim();
52 let value = l[idx + 1..].trim();
53 Some((name, value))
54 })
55 .collect()
56}