1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

The test on youtube

Discussion in 'YouTube' started by pussyback, May 19, 2008.

  1. pussyback

    pussyback Regular Member

    Joined:
    Apr 5, 2008
    Messages:
    402
    Likes Received:
    79
    http://forums.digitalpoint.com/showthread.php?t=847389
     
  2. ajaj

    ajaj Registered Member

    Joined:
    Jan 6, 2008
    Messages:
    59
    Likes Received:
    9
    I love how that thread deteriorated into an argument. I never did understand why people waste their time arguing over the internet. I guess it's brain stimulation tho.. better than watchin mindless p0rn and getting addicted to it.. So maybe it is good .. lol

    So who thinks the OP is telling the truth ?
     
  3. pussyback

    pussyback Regular Member

    Joined:
    Apr 5, 2008
    Messages:
    402
    Likes Received:
    79
    well the views are going way up !! so I would say that software it working
     
  4. snowwhite

    snowwhite Power Member

    Joined:
    Feb 12, 2008
    Messages:
    730
    Likes Received:
    1,415
    Occupation:
    Psychiatrist
    Location:
    Las Islas Filipinas
  5. havokb8

    havokb8 Guest

    someone should get it its only 35
     
  6. snowwhite

    snowwhite Power Member

    Joined:
    Feb 12, 2008
    Messages:
    730
    Likes Received:
    1,415
    Occupation:
    Psychiatrist
    Location:
    Las Islas Filipinas
    please get it dear and share with me, lol

    remember the guy selling the same type of product for $500 for 1000 views a day? ahahahahhah - this is a slap
     
  7. nicksor

    nicksor BANNED BANNED

    Joined:
    May 19, 2008
    Messages:
    76
    Likes Received:
    7
    I just finished an app in perl that does it. I'm testing , maybe i'll post on here afterwards.
     
  8. tonlilaz

    tonlilaz Executive VIP Premium Member

    Joined:
    Feb 28, 2008
    Messages:
    1,558
    Likes Received:
    1,700
    Occupation:
    Deleting crappy threads on BHW, making good use of
    Location:
    Over There
    Home Page:
    some of these people arguing sound like total douche bags
     
  9. nicksor

    nicksor BANNED BANNED

    Joined:
    May 19, 2008
    Messages:
    76
    Likes Received:
    7
    Ahh, here it is.

    Needs:
    Perl 5.3+
    LWP::UserAgent
    HTTP::Request::Common
    Parallel::ForkManager

    list of proxies in format:
    IP:pORT

    or linux machine with a decent amount of IPS & bandwidth.

    I imagine this won't run so fast via proxies.. I also don't know how often youtube updates stats.



    Code:
    #!/usr/bin/perl
    # youBoob
    
    use LWP::UserAgent;
    use HTTP::Request::Common;
    use Parallel::ForkManager;
    
    my %config;
    our (%iptracking,%proxytrack);
    
    %config = (
    		   video_url => 'http://www.youtube.com/watch?v=',  				# Video URL...
    		   use_random_ips => 1, 																							# If you have a server with many IPS set to 1.
    		   use_proxies => 0, 																									# Use Proxy list 1 = yes...
    		   proxy_list =>'proxylist.txt', 																			# List Format  IP:PORT
    		   max_threads => 50,  																								# Max processes
    		   max_views_per_host => '200',																				# Max views per IP / Proxy
    		   ifconfig_path => '/sbin/ifconfig',																	# Path to ifconfig [to find local IPs]
    		   debug => 1,																												# Print out infoz..
    			);
    
    
    	
    main();
    
    sub main {
    		
    		my $pm = new Parallel::ForkManager();
    		$pm = new Parallel::ForkManager($config{max_threads});
    		
    		if ($config{use_random_ips}) { our (@localaddrs) = get_local_ips(); print "Found: $#localaddrs local ipsn" if ($config{debug});}
    		if ($config{use_proxies}) { our (@proxies) = loadfile($config{proxy_list}); print "Loaded: $#proxies proxies from $confg{proxy_list}n" if ($config{debug});}
    		
    		if ($config{debug}) {
    				print "Configured Options:n"; 
    				while ( my ($opt,$value) = each (%config)) { print "t$opt => $valuen";}
    				}
    				
    		# Get busy!
    		
    		if ($config{use_random_ips}) { $doViews = $#localaddrs * $config{max_views_per_host}; }
    		if ($config{use_proxies}) { $doViews = $#proxies * $config{max_views_per_host}; }
    				
    		print "Max Views: $doViewsn";
    		$cView=0;
    		
    		for (1...$doViews) {
    		$cView++;
    		print "Loading view: $cViewn";
    		
    		if ($config{use_random_ips}) { 
    				$localaddr = $localaddrs[int(rand(@localaddrs))];
    				if ($iptracking{$localaddr} >= $config{max_views_per_host}) { $localaddr = $localaddr[int(rand(@localaddrs))]; } 
    				print "Using LocalAddr => $localaddr TimesUsed => $iptracking{$localaddr} n" if $config{debug};
    				$iptracking{$localaddr}++; 
    				}
    		
    		if ($config{use_proxies}) { 
    		$proxy = $proxies[int(rand(@proxies))];
    		if ($proxytrack{$proxy} >= $config{max_views_per_host}) { $proxy = $proxies[int(rand(@proxies))]; }
    		print "Using Proxy => $proxy TimesUsed => $proxytrack{$proxy} n" if $config{debug};
    		$proxytrack{$proxy}++; 
    		}
    		my $pid = $pm->start and next;
    				
    		view_video();
    		
    		$pm->finish;
    		
    		}
    		
    		$pm->wait_all_children;
    		
    
    }
    
    
    sub view_video {
    		my $ua = LWP::UserAgent->new;
    		$ua->agent('Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/2006120418 Firefox/2.0.0.1');
    		$ua->timeout('180');
    		
    		if ($config{use_proxies}) {
    				$ua->proxy(['http'], 'http://$proxy');
    		}
    
    		if ($config{use_random_ips}) {
    				@LWP::Protocol::http::EXTRA_SOCK_OPTS = (LocalAddr => $localaddr,Reuse => 1 ); 
    		}
    		
    		my $req = HTTP::Request->new(GET => $config{video_url});
    		$req->content_type('application/x-www-form-urlencoded');
    		my $res = $ua->request($req);
    		
    #		if ($config{debug}) {
    #				if ($res->is_success) {
    #						print $res->content;
    #						}
    #		}
    		
    		if ($res->is_success) {
    		print "OK! Loadedn";
    		print "Used: $localaddrn" if ($config{use_random_ips});
    		print "Used: $proxyn" if ($config{use_proxies});
    		}
    	
    		
    		
    }
    
    
    sub load_file {
    my ($fname) = @_;
    my (@fhin);
    			open(FH,"$fname") || die "can't open $fname: $0";
    				
    				while (<FH>) {
    						s/n//g;
    						s/r//g;
    						push(@fhin,$_);
    				}
    				
    			close(FH);
    			return(@fhin);
    }
    
    sub get_local_ips {
    my @iflines = `$config{ifconfig_path}`;
    		for (@iflines) { 
    				if (/s*inet addr:([d.]+)/) {
    						push(@local_addrs,$1);
    					}
    				}
    		return @local_addrs;
    }
    
     
  10. nicksor

    nicksor BANNED BANNED

    Joined:
    May 19, 2008
    Messages:
    76
    Likes Received:
    7
    I just noticed this forum strips the \n from the code tag.. What's the purpose of a code tag if \n is stripped?? lol
     
  11. nicksor

    nicksor BANNED BANNED

    Joined:
    May 19, 2008
    Messages:
    76
    Likes Received:
    7
    I attached the script to this post because the code tags strip \n and i'm too lazy to add an extra \ to the code and paste it again..
     

    Attached Files:

  12. dsfeeer

    dsfeeer Junior Member

    Joined:
    Jul 1, 2007
    Messages:
    100
    Likes Received:
    6
    Thanks for sharing ! :)
     
  13. dsfeeer

    dsfeeer Junior Member

    Joined:
    Jul 1, 2007
    Messages:
    100
    Likes Received:
    6
    nicksor, does the code work on your host ?
    i tried but got error below:

    500 Internal Server Error
    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
     
  14. pussyback

    pussyback Regular Member

    Joined:
    Apr 5, 2008
    Messages:
    402
    Likes Received:
    79
    I just bought it and it already working , I would share it but it connect to a server to check the key so don't want to lose it. 35 bucks I will make that back in about 2hr ,nicksor couldn't get your code to work
     
  15. nicksor

    nicksor BANNED BANNED

    Joined:
    May 19, 2008
    Messages:
    76
    Likes Received:
    7
    It's not a web based perl script. It's a console based script. That's why you received a 500 error. This will not work as a cgi script because of the run time limits imposed by apache on scripts.
     
  16. pussyback

    pussyback Regular Member

    Joined:
    Apr 5, 2008
    Messages:
    402
    Likes Received:
    79
    how do you run a console based script?
     
  17. razohad

    razohad Jr. VIP Jr. VIP Premium Member

    Joined:
    Jan 11, 2008
    Messages:
    701
    Likes Received:
    1,005
    Occupation:
    Software engginer
    Location:
    online most of the time

    is it any good?
     
  18. havokb8

    havokb8 Guest

    i was thinking more along the lines of getting it and telling me if it works :)
     
  19. pussyback

    pussyback Regular Member

    Joined:
    Apr 5, 2008
    Messages:
    402
    Likes Received:
    79
    so far working great!!!
     
  20. MaestroDelWeb

    MaestroDelWeb Executive VIP

    Joined:
    Nov 5, 2007
    Messages:
    815
    Likes Received:
    869
    Occupation:
    Jack of all trades.
    Location:
    USA
    I watched the video and it looks like it would work with any URL not just youtube. Have you been able to test if it will work with other sites?