博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
python刷赞
阅读量:4081 次
发布时间:2019-05-25

本文共 1918 字,大约阅读时间需要 6 分钟。

只是供大家娱乐下,另外希望相关人员不要做这么容易刷赞的网站。

刷点击量,就是重复打开、关闭链接。

当然重点不在这,重点是要知道怎么才能重刷。
从浏览器中打开网址(http://www.xxxxxxxx.com/lxxxx.html),抱歉匿了,读者可以试试其他网站。
点击“投票支持”或者"赞"按钮,这时按钮不能继续点击了,关闭浏览器后,再打开网址又可以点击了。
发现了这个机制,然后找到点击“投票支持”后发送的链接,可以在浏览器chrome的Network中查看。
剩下的就是写个循环不断重复打开、关闭链接的操作。
这是个偏门,很多网站都无法这么简单的刷点击量。

#!/usr/bin/python# -*- coding: UTF-8 -*-import urllib2import timeimport randomfor i in range(100):    '“100”就是刷赞的数量,链接也匿了'    f = urllib2.urlopen('http://www.xxxxx.com/xxxxxx.html')    #查看是否成功打开    print f.read()    f.close()    #稍微休息下    time.sleep(random.random())

偶尔想换个ip,可网上购买虚拟机,断网重连换ip。以下代码在XP系统上可用于换ip。再结合刷赞代码可以做到一个ip刷一次赞。

import subprocessimport timeclass myWang():		def getIp(self):		cmd = subprocess.check_output('ipconfig').split(':')		ip = cmd[-3].split('  ')[0].strip() #获取CMD输出内容中的宽带IP,系统的公网ip。		return ip		def reIp(self):#用CMD命令断网,连网。subprocess.call的速度比os.system快一点		subprocess.call(r"rasdial 宽带连接 /DISCONNECT")		subprocess.call(r"rasdial 宽带连接 05669346520 666888")aip = myWang()count = 0firstIp = aip.getIp()#延迟时间miao = 10while True:	aip.reIp()	nextIp = aip.getIp()	if nextIp == firstIp:		continue	count += 1	print count	print nextIp	firstIp = nextIp	time.sleep(miao)

结合起来的代码如下。

import urllib2import timeimport subprocessclass myWang():		def getIp(self):		cmd = subprocess.check_output('ipconfig').split(':')		ip = cmd[-3].split('  ')[0].strip() #获取CMD输出内容中的宽带IP,系统的公网ip。		return ip		def reIp(self):#用CMD命令断网,连网。subprocess.call的速度比os.system快一点		subprocess.call(r"rasdial 宽带连接 /DISCONNECT")		subprocess.call(r"rasdial 宽带连接 05669346520 666888")aip = myWang()firstIp = aip.getIp()for i in range(100):        '“100”就是刷赞的数量,链接也匿了'        f = urllib2.urlopen('http://www.xxxxx.com/xxxxxx.html')        #查看是否成功打开        print f.read()        f.close()        aip.reIp()        nextIp = aip.getIp()        while nextIp == firstIp:            aip.reIp()            nextIp = aip.getIp()        print nextIp        firstIp = nextIp

转载地址:http://lktni.baihongyu.com/

你可能感兴趣的文章
ping 报name or service not known
查看>>
FTP 常见问题
查看>>
zookeeper单机集群安装
查看>>
do_generic_file_read()函数
查看>>
Python学习笔记之数据类型
查看>>
Python学习笔记之特点
查看>>
shell 快捷键
查看>>
VIM滚屏操作
查看>>
EMC 2014存储布局及十大新技术要点
查看>>
linux内核内存管理(zone_dma zone_normal zone_highmem)
查看>>
将file文件内容转成字符串
查看>>
循环队列---数据结构和算法
查看>>
优先级队列-数据结构和算法
查看>>
链接点--数据结构和算法
查看>>
servlet中请求转发(forword)与重定向(sendredirect)的区别
查看>>
Spring4的IoC和DI的区别
查看>>
springcloud 的eureka服务注册demo
查看>>
eureka-client.properties文件配置
查看>>
MODULE_DEVICE_TABLE的理解
查看>>
platform_device与platform_driver
查看>>