纪年科技aming网络安全,深度学习,嵌入式机器强化,生物智能,生命科学

优采云 发布时间: 2021-08-01 20:27

  

纪年科技aming网络安全,深度学习,嵌入式机器强化,生物智能,生命科学

  

  济年科技aming

  网络安全、深度学习、嵌入式、机器增强、生物智能、生命科学。

  想法:

  使用现有的搜索引擎 API 和 Google Hacking 技术,

  批量关键字查询和注入点检测

  #分为三步:

  网址采集

  过滤采集无法到达的URL,如静态页面等

  注射点检测

  网址采集:

  使用必应提供的免费API,URL采集:(Bing.py)

   #!/usr/bin/env python

#coding:utf8

import requests

import json

import sys

# config-start

BingKey = "" # config your bing Ocp-Apim-Subscription-Key

Keyword = "简书"

maxPageNumber = 10

pageSize = 10

# config-end

url = "https://api.cognitive.microsoft.com/bing/v5.0/search?q=" + Keyword

headers = {

'Host':'api.cognitive.microsoft.com',

'User-Agent':'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:50.0) Gecko/20100101 Firefox/50.0',

'Accept':'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',

'Accept-Language':'zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3',

'Accept-Encoding':'gzip, deflate, br',

'Ocp-Apim-Subscription-Key':BingKey,

'Upgrade-Insecure-Requests':'1',

'Referer':'https://api.cognitive.microsoft.com/bing/v5.0/search?q=opensns',

'Connection':'keep-alive',

}

for i in range(maxPageNumber):

tempUrl = url + "&offset=" + str(i * pageSize) + "&count=" + str(pageSize)

response = requests.get(tempUrl, headers=headers)

content = response.text

jsonObject = json.loads(content)

results = jsonObject['webPages']['value']

for result in results:

resulturl = result['displayUrl']

if resulturl.startswith("https://"):

print resulturl

else:

print "http://" + resulturl

  使用开源HTML解析库解析百度搜索结果页面,采集URL:(Baidu.py)

   #!/usr/bin/env python

#coding:utf8

import requests

from bs4 import BeautifulSoup

import sys

# config-start

keyword = "简书"

# config-end

url = "http://www.baidu.com/s?wd=" + keyword

response = requests.get(url)

content = response.content

status_code = response.status_code

soup = BeautifulSoup(content, "html.parser")

links = soup.findAll("a")

for link in links:

try:

dstURL = link['href']

if (dstURL.startswith("http://") or dstURL.startswith("https://")) and dstURL.startswith("http://www.baidu.com/link?url=") :

result_url = requests.get(dstURL).url

print result_url

except Exception as e:

continue

  过滤静态页面等网址

   #!/usr/bin/env python

#coding:utf8

file = open("urls.txt","r")

for line in file:

content = line[0:-1]

if content.endswith("html"):

continue

if content.endswith("htm"):

continue

if ".php" in content or ".asp" in content:

print content

  检测注入点:

   #!/usr/bin/env python

#coding:utf8

import os

import sys

file = open(sys.argv[1],"r")

for line in file:

url = line[0:-1]

print "*******************"

command = "sqlmap.py -u " + url + " --random-agent -f --batch --answer=\"extending=N,follow=N,keep=N,exploit=n\""

print "Exec : " + command

os.system(command)

  搜索引擎语法关键字(搜索范围)引擎

  【1】精确匹配搜索-精确匹配""引号和书名""

  查询词很长,经过百度分析,可能会被拆分

  搜索收录引号的部分作为一个整体进行匹配

  引号是英文的引号。

  屏蔽一些百度推广

  例如:

  “网站促销策划”全称

  ""移动"/"移动""

  【2】±正负号的用法

  加号同时收录两个关键字,相当于空格和。

  减号在搜索结果中不收录特定的查询词——它前面必须有一个空格,后跟要排除的词

  例如:

  电影-搜狐

  音乐 + 古代

  [3] 如何使用 OR

  搜索两个或多个关键字

  例如:

  “seo 或深圳 seo”

  可能会出现这些关键字之一,也可能同时出现。

  “seo 或您的名字”(此处没有引号)。

  如果您的名字是通用名称。你会发现意想不到的惊喜。有和你同名同姓的同行业人。

  “seo or Shenzhen seo”(这里没有引号)我找到了一个同名同姓的人,他和我一起去了。

  [4] 标题

  网页标题内容-网页内容大纲样式的总结

  比赛页面

  关键词optimization

  例如:

  (搜索时不要加引号)

  "intitle:管理登录"

  《新疆题:学局》

  “网络推广标题:他的名字”

  [5] intext 和 allintext(对谷歌有效)

  出现在页面内容中,而不是标题中,

  搜索页面收录“SEO”,标题收录SEO对应的文章页面。

  只搜索网页部分收录的文字(忽略标题、网址等文字),

  类似于某些网站中使用的“文章Content Search”功能。

  例如:

  “深圳SEO intext:SEO”

  [6] 网址

  在url中搜索url链接中收录的字符串(中英文),

  竞争对手排名

  例如:

  搜索登录地址,可以这样写“inurl:admin.asp”,

  如果要搜索Discuz的论坛,可以输入inurl:forum.php,

  "csdn 博客 inurl:py_shell"

  【7】网站

  搜索特定网页

  查看搜索引擎收录 有多少页。

  ——如果您在某个站点有什么需要查找的,可以将搜索范围限制在本站点

  “胡歌空间内:”

  [8]链接

  搜索指向网站 的链接。

  搜索网站url 的内外部链接

  并非每个搜索引擎都非常准确,尤其是 Google,

  只会返回索引库的一部分,而且是随机部分,

  百度不支持此命令。

  雅虎完全支持,查询更准确。

  一般我们查网站的链接以雅虎为准,

  [9] 文件类型

  搜索你想要的电子书,限于指定的文档格式

  并非所有格式都受支持。现在百度支持pdf、doc、xls、all、ppt、rtf、

  例如:

  “python 教程文件类型:pdf”

  对于doc文件,只需写“filetype:doc”,

  "seo filetype:doc",(搜索时不带引号),

  [10] 相关(仅适用于谷歌)

  指定与 URL 相关的页面,

  通常会显示与您的网站具有相同外部链接的网站。

  竞争对手,

  相同的外链。

  [11] * 通配符(百度不支持)

  例如:搜索*引擎

  [12] Inanchor 导入链接收录锚文本(百度不支持)

  竞争对手

  链接到

  [13] allintitle 收录多组关键字

  [14] allinurl

  [15] 链接域(雅虎)

  排除域名反向链接,获取外链

  链接域:

  [16] 相关(谷歌)网站 相关页面

  有常用的外链

  [17]域某网站相关信息

  “域名:网址”

  [18] 索引(百度)

  “mp3 索引”

  [19] A|B 收录 a 或 b

0 个评论

要回复文章请先登录注册


官方客服QQ群

微信人工客服

QQ人工客服


线