p10_第10天:信息收集-资产监控拓展

一、知识搜集


二、知识讲解及案例

(一)Github 监控

**便于收集整理最新 exp 或 poc **
**便于发现相关测试目标的资产 **

大佬们喜欢在GitHub发布漏洞, 可通过绑定GitHub实时推送关心的漏洞。

1.演示:监控最新的 EXP 发布及其他

先下载python3,将代码复制到python中。
项目地址:https://github.com/weixiao9188/wechat_push
server酱:https://sct.ftqq.com/after
代码复制了一个笔记里的。https://www.yuque.com/weiker/xiaodi/qdao80

# Title: wechat push CVE-2020
# Date: 2020-5-9
# Exploit Author: weixiao9188
# Version: 4.0
# Tested on: Linux,windows
# coding:UTF-8
import requests
import json
import time
import os
import pandas as pd
time_sleep = 20 #每隔20秒爬取一次
while(True):
    headers = {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.25 Safari/537.36 Core/1.70.3741.400 QQBrowser/10.5.3863.400"}
    #判断文件是否存在
    datas = []
    response1=None
    response2=None
    if os.path.exists("olddata.csv"):
        #如果文件存在则每次爬取10个
        df = pd.read_csv("olddata.csv", header=None)
        datas = df.where(df.notnull(),None).values.tolist()#将提取出来的数据中的nan转化为None
        response1 = requests.get(url="https://api.github.com/search/repositories?q=CVE-2020&sort=updated&per_page=10",
                                 headers=headers)
        response2 = requests.get(url="https://api.github.com/search/repositories?q=RCE&ssort=updated&per_page=10",
                                 headers=headers)

    else:
        #不存在爬取全部
        datas = []
        response1 = requests.get(url="https://api.github.com/search/repositories?q=CVE-2020&sort=updated&order=desc",headers=headers)
        response2 = requests.get(url="https://api.github.com/search/repositories?q=RCE&ssort=updated&order=desc",headers=headers)

    data1 = json.loads(response1.text)
    data2 = json.loads(response2.text)
    for j in [data1["items"],data2["items"]]:
        for i in j:
            s = {"name":i['name'],"html":i['html_url'],"description":i['description']}
            s1 =[i['name'],i['html_url'],i['description']]
            if s1 not in datas:
                #print(s1)
                #print(datas)
                params = {
                    "text":s["name"],
                    "desp":" 链接:"+str(s["html"])+"\n简介"+str(s["description"])
                }
                print("当前推送为"+str(s)+"\n")
                print(params)
                requests.get("https://sc.ftqq.com/xxx.send",params=params,timeout=10)
                #time.sleep(1)#以防推送太猛
                print("推送完成!")
                datas.append(s1)
            else:
                pass
                #print("数据已处在!")
    pd.DataFrame(datas).to_csv("olddata.csv",header=None,index=None)
    time.sleep(time_sleep)

更改代码中框框中的可以更改需要查的漏洞信息。
image.png
server酱注册后会有一个码,复制到代码中。
image.png
image.png
运行后,手机微信会收到推送。
image.png

(二)各种子域名查询

![image.png](https://img-blog.csdnimg.cn/img_convert/165d291dd9ab7add32854805aaf5470d.png#clientId=u77d86878-1e0f-4&crop=0&crop=0&crop=1&crop=1&from=paste&id=qiq8Z&margin=%5Bobject%20Object%5D&name=image.png&originHeight=1288&originWidth=1287&originalType=url&ratio=1&rotation=0&showTitle=true&size=146567&status=done&style=none&taskId=ub1b918c6-3953-442f-9146-d83a5d16bd9&title=引自 https://blog.csdn.net/kclax/article/details/90600979 “引自 https://blog.csdn.net/kclax/article/details/90600979”)
图片来自https://blog.csdn.net/kclax/article/details/90600979
#DNS,备案,证书
#全球节点请求 cdn
枚举爆破或解析子域名对应
便于发现管理员相关的注册信息

(三)黑暗引擎相关搜索

工具:
fofa:https://fofa.info/
shodan:https://www.shodan.io/
zoomeye:https://www.zoomeye.org/
image.png
有外国的,说明有seo优化。可能有国外业务。seo会被用来做域名劫持。
3个网站都可以试试用。

(四)全自动搜集域名使用

工具链接:https://github.com/bit4woo/teemo
image.png
这里需要配置,如果没有配置,可能搜不到;所以还是要买会员。
弹幕说现在比较多用oneforall。

(五)SRC目标中的信息收集全覆盖

(1)补天上专属SRC上简易测试

提交漏洞的平台
image.png

(六)利用其它第三发接口获取更多信息

#微信公众号接口获取
#内部群内部应用内部接口
https://tools.ipip.net/cdn.php
用别的偏僻地址ping域名,可能得到真实IP,对方不可能所有地方都有cdn
image.png
image.png

https://crt.sh/
https://dnsdb.io/zh-cn/
https://sct.ftqq.com/login
https://tools.ipip.net/cdn.php
https://github.com/bit4woo/teemo
https://securitytrails.com/domain/www.baidu.com/history/a

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值