M-A

Base 64 : Cod e & Decode

M-A
Jan 1st, 2013
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 2.35 KB | None | 0 0
  1. #!usr/bin/perl
  2. #Simple Tool Base 64 Code & Decode
  3. #Hav fun <3
  4. use MIME::Base64;
  5. use Time::HiRes "usleep";
  6.  
  7.  
  8. sub main {
  9.    Header();
  10.     my @logo = (
  11.         "+=============================================+", "\n",
  12.         "|           Base 64 : Code & Decode           |", "\n",
  13.         "+---------------------------------------------+", "\n",
  14.         "| Author: Mr_AnarShi-T                        |", "\n",
  15.         "| GreeT's: All Friends <3                     |", "\n",
  16.         "| Home: Www.GaZa-Hacker.NeT                   |", "\n",
  17.         "+---------------------------------------------+", "\n",
  18.         "|           Thnx For Using Hav Fun ;)         |", "\n",
  19.         "+=============================================+", "\n"
  20.     );
  21.  
  22.     print "\n";
  23.     marquesina(@logo);
  24.  
  25. }
  26. main();
  27. print "\n[+] Options\n\n";
  28. print q(
  29. 1 - Base64 encode
  30. 2 - Base64 decode
  31. 3 - Exit
  32.  
  33. );
  34. while (true) {
  35.     print "\n\n[+] r00t~GHT: : ";
  36.     chomp( my $op = <stdin> );
  37.     print "\n\n";
  38.     if ( $op eq 1 ) {
  39.         print "[+] c  : ";
  40.         chomp( my $string = <stdin> );
  41.         print "\n\n[+] Base64 : " . encode_base64($string);
  42.     }
  43.     elsif ( $op eq 2 ) {
  44.         print "[+] ???? ???? : ";
  45.         chomp( my $string = <stdin> );
  46.         print "\n\n[+] Base64 Decode : " . decode_base64($string) . "\n";
  47.     }
  48.     elsif ( $op eq 3 ) {
  49.     print "have a nice Day";
  50.         exit(1);
  51.     }
  52.     else {
  53.         print "[+] Wrong Chose try Again !\n";
  54.     }
  55. }
  56.  
  57. sub Header {
  58.     my $os = $^O;
  59.     if ( $os =~ /Win32/ig ) {
  60.         system("cls");
  61.     }
  62.     else {
  63.         system("clear");
  64.     }
  65. }
  66. sub marquesina {
  67.  
  68.     #Effect based in the exploits by Jafer Al Zidjali
  69.  
  70.     my @logo = @_;
  71.  
  72.     my $car = "|";
  73.  
  74.     for my $uno (@logo) {
  75.         for my $dos ( split //, $uno ) {
  76.  
  77.             $|++;
  78.  
  79.             if ( $car eq "|" ) {
  80.                 mostrar( "\b" . $dos . $car, "/" );
  81.             }
  82.             elsif ( $car eq "/" ) {
  83.                 mostrar( "\b" . $dos . $car, "-" );
  84.             }
  85.             elsif ( $car eq "-" ) {
  86.                 mostrar( "\b" . $dos . $car, "\\" );
  87.             }
  88.             else {
  89.                 mostrar( "\b" . $dos . $car, "|" );
  90.             }
  91.             usleep(40_000);
  92.         }
  93.         print "\b ";
  94.     }
  95.     sub mostrar {
  96.         print $_[0];
  97.         $car = $_[1];
  98.     }
  99.  
  100.     }
Advertisement
Add Comment
Please, Sign In to add comment