Skip to content

Commit d82d340

Browse files
authored
Backup
1 parent 390fc9e commit d82d340

File tree

1 file changed

+13
-6
lines changed

1 file changed

+13
-6
lines changed

Obfuscation/main.rs

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
// Just an Backup to code at remote area,
2-
// will be coding shortly ...!
3-
// Sorry for the inconvenience Nerds ;(
4-
51
use std::{env::Args, net::Ipv4Addr};
62

3+
// IpV4 Obfuscation ...!
74
fn obfuscate_ipv4(shellcode: &mut Vec<u8>){
85
if shellcode.len() % 4 != 0 {
96
while shellcode.len() % 4 != 0{
@@ -19,10 +16,20 @@ fn obfuscate_ipv4(shellcode: &mut Vec<u8>){
1916

2017
}
2118

19+
fn deobfuscate_ipv4(ipv4_addr: Vec<&str>) -> Result<Vec<u8>, ()>{
20+
let mut debug: Vec<u8> = Vec::with_capacity(ipv4_addr.len() * 4);
21+
22+
for ip in ipv4_addr{
23+
match ip.parse::<Ipv4Addr>(){
24+
Ok(ip_addr) => debug.extend_from_slice(&ip_addr.octets()),
25+
Err(_) => return Err(()),
26+
}
27+
}
28+
Ok(debug)
29+
}
30+
2231
// add utils file . !
2332
fn main(){
2433
let args = utils::Args::parse();
25-
2634
// Will be coding at remove area ;)
2735
}
28-

0 commit comments

Comments
 (0)