MCPcopy Create free account
hub / github.com/Nariod/RustPacker / test_generate_random_filename_format

Function test_generate_random_filename_format

src/tools.rs:190–204  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

188
189 #[test]
190 fn test_generate_random_filename_format() {
191 let order = arg_parser::Order {
192 shellcode_path: PathBuf::from("/tmp/test.bin"),
193 execution: arg_parser::Execution::NtCreateRemoteThread,
194 encryption: arg_parser::Encryption::Xor,
195 format: arg_parser::Format::Exe,
196 target_process: "dllhost.exe".to_string(),
197 sandbox: None,
198 output: None,
199 proxy_dll: None,
200 };
201 let filename = generate_random_filename(&order);
202 assert!(filename.ends_with(".exe"));
203 assert_eq!(filename.len(), 12); // 8 random chars + ".exe"
204 }
205
206 #[test]
207 fn test_get_source_binary_filename() {

Callers

nothing calls this directly

Calls 1

generate_random_filenameFunction · 0.85

Tested by

no test coverage detected