Giter Site home page Giter Site logo

awake1t / linglong Goto Github PK

View Code? Open in Web Editor NEW
1.7K 24.0 305.0 120.38 MB

一款甲方资产巡航扫描系统。系统定位是发现资产,进行端口爆破。帮助企业更快发现弱口令问题。主要功能包括: 资产探测、端口爆破、定时任务、管理后台识别、报表展示

Go 44.69% JavaScript 2.12% HTML 6.37% Vue 42.24% CSS 4.19% Dockerfile 0.38% Shell 0.01%

linglong's Introduction

linglong

一款资产巡航扫描系统。系统定位是通过masscan+nmap无限循环去发现新增资产,自动进行端口弱口令爆破/、指纹识别、XrayPoc扫描。主要功能包括: 资产探测端口爆破Poc扫描指纹识别定时任务管理后台识别报表展示。 使用场景是Docker搭建好之后,设置好你要扫描的网段跟爆破任务。就不要管他了,没事过来收漏洞就行了

功能清单

  • masscan+namp巡航扫描资产
  • 创建定时爆破任务(FTP/SSH/SMB/MSSQL/MYSQL/POSTGRESQL/MONGOD)
  • 管理后台识别
  • 结果导出
  • 报表展示
  • docker一键部署 [21-02-08]
  • CMS识别 - 结合威胁情报、如果某个CMS爆出漏洞,可以快速定位企业内部有多少资产 [21-02-20]
  • poc扫描 - 调用xray的Poc,对新发现的资产自动扫描poc [21-02-20]

预览

tip:如果图片加载不出来,点我去gitee看图片

首页 image

资产列表 image

敏感后台 image

指纹管理 image

任务列表 image

任务详情 image

xray image image

设置 image

管理后台识别

不论甲方乙方。大家在渗透一个网站的时候,很多时候都想尽快找到后台地址。linglong对自己的资产库进行Title识别。然后根据title关键字、url关键字、body关键字(比如url中包含login、body中包含username/password)进行简单区分后台。帮助我们渗透中尽快锁定后台。

指纹识别

系统会对新发现的资产进行一遍指纹识别, 也可以手动新增指纹。比如某个CMS爆出漏洞,新增指纹扫描一遍系统中存在的资产。可以快速定位到漏洞资产,对于渗透打点或者甲方应急都是极好的

POC扫描

对于任何一个扫描系统,poc扫描都是必不可少的。但是poc的更新一直是所有开源项目面临的一个问题。综合考虑用Xray的poc,系统集成的XRAY版本是1.7.0,感谢Xray对安全圈做出的贡献! linglong会对每次新发现的资产进行一遍Xray的Poc扫描。如果发现漏洞会自动入库,可以可视化查看漏洞结果

资产巡航更新

masscan可以无限扫描,但是对于失效资产我们也不能一直保存。linglong通过动态设置资产扫描周期,对于N个扫描周期都没有扫描到的资产会进行删除。保存资产的时效性

安装

Docker安装

如果部署在本地体验(本地机器或者自己的虚拟机)

如果是本地体验下,直接运行如下命令

git clone https://github.com/awake1t/linglong
cd linglong
docker-compose up -d

运行结束后,运行docker container ls -a看下是否运行正常

image

web访问 http://ip:8001 登录账号:linglong 登录密码:linglong5s

Web账号 linglong linglong5s
类型 用户名 密码
mysql数据库 root linglong8s

注: 首次运行在设置里修改扫描的网段范围,点击保存后就行了。然后耐心等待系统自动扫描,扫描耗时您配置的网段+端口+速率会有变化

如果部署在服务器上(地址不是127.0.0.1情况)

git clone https://github.com/awake1t/linglong
cd linglong/web

# 把 YourServerIp 换成你的IP地址
sed -i 's#http://127.0.0.1:18000#http://YourServerIp:18000#g' ./dist/js/app.4dccb236.js && sed -i 's#http://127.0.0.1:18000#http://YourServerIp:18000#g' ./dist/js/app.4dccb236.js.map


# 重要!!! 如果之前安装过,使用如下命令删除所有名字包含linglong的历史镜像
docker rmi $(docker images | grep "linglong" | awk '{print $3}') 


# 返回到 linglong的目录下
cd ../
docker-compose up -d

一般这时候就部署好了,如果访问不了. 要确认下服务器上安全组的8001和18000有没有打开.

image

未来

我觉得一个好的工具就是 拿来就用、用完既走。后期会加入漏洞的机器人通知,发现漏洞自动通知到机器人,连你登录系统的步骤都省略。 或者看有没有方式把Goby集成。加油,干饭人!

更新日志

  • [2021-0210] 指纹资产管理、增删改查
  • [2021-0210] 优化资产的查询方式
  • [2021-0213] 发现资产POC自动扫描、扫描结果界面查看、删除
  • [2021-0214] 密码修改功能,关闭Xray-server-error
  • [2021-0215] Docker折腾了好久
  • [2021-0225] 更新docker-compose的部署方式

常见问题

Q: 为什么安装后,点击登录没有反应??

A:大概率是你的部署的服务器地址不是 127.0.0.1, 所以会登录不上。 解决参考安装方式中: “如果部署在服务器上(地址不是127.0.0.1情况)”。 如果你的部署服务器地址是127.0.0.1,登录没反应。提供F12网络中的请求包截图,环境,部署方式到ISSUE。

Q: 怎么知道服务器的某个端口有没有打开

A: 比如8002端口, 在服务器上使用命令 python3 -m http.server 8002 启动一个临时WebServer. 然后在自己本地电脑 curl -v http://ip:8002 如果有返回,就代表服务器端口是开的.

Q: 出现 Service 'web' failed to build : Error parsing reference: "nginx:1.15.3-alpine as production-stage" is not a valid repository/tag: invalid reference format??报错

A: docker版本过低,查看docker的版本 docker --version。 解决: 需要升级docker的版本, 我的docker版本, Docker version 19.03.4, build 9013bf5docker升级参考

致谢

https://github.com/ysrc/xunfeng

https://github.com/chaitin/xray

404StarLink 2.0 - Galaxy

linglong 是 404Team 星链计划2.0中的一环,如果对linglong 有任何疑问又或是想要找小伙伴交流,可以参考星链计划的加群方式。

linglong's People

Contributors

awake1t avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

linglong's Issues

小建议

  1. 建议任务类型可以批量多选,现在好像是只能指定单一的任务类型
  2. 建议任务资产 处 可以直接输入域名、ip、等一些资产。在创建任务的时候就直接将想要扫描的资产加入进去扫描。
  3. 不知道咱们这个能不能加入自定义写的poc。

安装报错

师傅请问一下,我docker安装的时候出现这个错误是怎么回事呢
npm ERR! gyp verb extracted file from tarball include/node/openssl/archs/VC-WIN64-ARM/no-asm/include/openssl/opensslconfnpm ERR! gyp verb command remove [ '15.5.1' ]
npm ERR! gyp verb remove using node-gyp dir: /root/.node-gyp
npm ERR! gyp verb remove removing target version: 15.5.1
npm ERR! gyp verb remove removing development files for version: 15.5.1
npm ERR! gyp verb content checksum node-v15.5.1-headers.tar.gz e1837220591e22fdc53d367adf0cd6c539af89be51dba4e50d6d2d0ab0b477ab
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: aborted
npm ERR! gyp ERR! stack at connResetException (node:internal/errors:631:14)
npm ERR! gyp ERR! stack at TLSSocket.socketCloseListener (node:_http_client:434:19)
npm ERR! gyp ERR! stack at TLSSocket.emit (node:events:388:22)
npm ERR! gyp ERR! stack at node:net:666:12
npm ERR! gyp ERR! stack at TCP.done (node:_tls_wrap:573:7)
npm ERR! gyp ERR! System Linux 5.4.72-microsoft-standard-WSL2
npm ERR! gyp ERR! command "/usr/local/bin/node" "/app/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
npm ERR! gyp ERR! cwd /app/node_modules/node-sass
npm ERR! gyp ERR! node -v v15.5.1
npm ERR! gyp ERR! node-gyp -v v3.8.0
npm ERR! gyp ERR! not ok
npm ERR! Build failed with error code: 1

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-03-10T16_59_43_277Z-debug.log
ERROR: Service 'web' failed to build : The command '/bin/sh -c rm -rf node_modules && npm install node-sass && cnpm run build' returned a non-zero code: 1

执行docker搭建时遇到问题

以下是报错:
root@ruleaker:~/Desktop/linglong-master# docker-compose up -d
/usr/local/lib/python2.7/dist-packages/paramiko/transport.py:33: CryptographyDeprecationWarning: Python 2 is no longer supported by the Python core team. Support for it is now deprecated in cryptography, and will be removed in the next release.
from cryptography.hazmat.backends import default_backend
Building web
Step 1/11 : FROM node:latest as build-stage
---> 34c1219e2da7
Step 2/11 : MAINTAINER drunk_kk
---> Using cache
---> c83cdc2c5bcd
Step 3/11 : RUN npm install -g cnpm --registry=https://registry.npm.taobao.org
---> Running in 3023c47a1f41
npm ERR! code EAI_AGAIN
npm ERR! syscall getaddrinfo
npm ERR! errno EAI_AGAIN
npm ERR! request to https://registry.npm.taobao.org/cnpm failed, reason: getaddrinfo EAI_AGAIN registry.npm.taobao.org

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-02-25T03_48_44_817Z-debug.log
ERROR: Service 'web' failed to build: The command '/bin/sh -c npm install -g cnpm --registry=https://registry.npm.taobao.org' returned a non-zero code: 1

以下是npm以及cnpm版本
root@ruleaker:# cnpm -v
[email protected] (/usr/local/lib/node_modules/cnpm/lib/parse_argv.js)
[email protected] (/usr/local/lib/node_modules/cnpm/node_modules/npm/lib/npm.js)
[email protected] (/usr/bin/node)
[email protected] (/usr/local/lib/node_modules/cnpm/node_modules/npminstall/lib/index.js)
prefix=/usr/local
linux x64 5.7.0-kali1-amd64
registry=https://r.npm.taobao.org
root@ruleaker:
# npm -v
7.5.6

环境:
VMware虚拟机 Kali 2020.1
桥接模式
网络是高中校园网屏蔽了一些网站比如p站 但是淘宝是上的去的 应该不是代理问题, 额 语言不够严谨请见谅 高一学生 还需要多多学习 需要前辈指点帮助

我在搭建过程中遇到了问题

image

我也不知道我的图片你能看见吗 我在搭建过程中 遇到了npm node等相关问题 解决一个又遇到了 一个我个人用的是阿里云的ubantu18.04 因为是小白 所以自己解决不了

爆破字典修改

爆破字典好像不能自己添加或者修改,后期会添加这个功能吗?

关于docker部署和xray启用的两个小建议

1.docker部署可以考虑默认vps部署的配置写法,在README中把“如果要部署在本地”放在后面,因为感觉这种默认127.0.0.1的docker配置比较少见,很多人可能就直接docker-compose up -d一把梭了,也导致ISSUES里面很多人问为什么登录没反应(当然也是自己没仔细看)。
2.xray模块添加启用的开关,可以考虑默认不启用。很多人可能只想测试一下资产探测,正常TCP连接而已没什么风险,结果联动着xray直接咔咔一批POC打过去,可能就影响服务可用性甚至有喝茶的风险了。

端口扫描

如果扫描列表比较大 进行全端口扫描 会出现一种情况 masscan隔一段时间扫描 但是没有端口信息出来

docker 启动error

大佬你好:
启动doker提示出错。百度没有结果。
linglong_mysql_1 is up-to-date
Starting linglong-server ... error

ERROR: for linglong-server Cannot start service server: OCI runtime create failed: container_linux.go:349: starting container process caused "exec: "./linglong": permission denied": unknown

ERROR: for server Cannot start service server: OCI runtime create failed: container_linux.go:349: starting container process caused "exec: "./linglong": permission denied": unknown
ERROR: Encountered errors while bringing up the project.

密码加强建议

经过测试,新修改密码无法通过特殊符号登陆,建议加强密码策略。

资产分组

是否考虑增加资产分组功能,方便更加细致管理。

域名资产

只能扫ip地址吗?域名,子域等能支持不

拉取制作docker镜像时出错

如题,具体提示为:

.......
Step 5/5 : CMD ["nginx", "-g", "daemon off;"]
 ---> Running in c25323fb634b
Removing intermediate container c25323fb634b
 ---> 7795dfe488ae
Successfully built 7795dfe488ae
Successfully tagged linglong_web:latest
WARNING: Image for service web was built because it did not already exist. To rebuild this image you must use `docker-compose build` or `docker-compose up --build`.
Recreating 690641597a3c_linglong_mysql_1 ... error

ERROR: for 690641597a3c_linglong_mysql_1  no such image: sha256:7ce9d9ba440e8e821900ef9a4b0adc8d0a08ea70ab0014231aa526ec87dd09b8: No such image: sha256:7ce9d9ba440e8e821900ef9a4b0adc8d0a08ea70ab0014231aa526ec87dd09b8

ERROR: for mysql  no such image: sha256:7ce9d9ba440e8e821900ef9a4b0adc8d0a08ea70ab0014231aa526ec87dd09b8: No such image: sha256:7ce9d9ba440e8e821900ef9a4b0adc8d0a08ea70ab0014231aa526ec87dd09b8
ERROR: The image for the service you're trying to recreate has been removed. If you continue, volume data could be lost. Consider backing up your data before continuing.

Continue with the new image? [yN]N
ERROR: no such image: sha256:7ce9d9ba440e8e821900ef9a4b0adc8d0a08ea70ab0014231aa526ec87dd09b8: No such image: sha256:7ce9d9ba440e8e821900ef9a4b0adc8d0a08ea70ab0014231aa526ec87dd09b8

image

建议

1、建议增加一个资产删除功能
2、增加一个dirsearch 目录爆破功能

ps:后续功能待定

docker时web容器启动失败

图片
你好,我在启动docker时发现web容器报错,但我找不到相关的代码进行修改,已经在百度查找了解决方法,但还是时没能解决,只能打扰一下询问一下解决方案。报错如下:
[root@localhost linglong-master]# docker-compose up -d web
Building web
Step 1/11 : FROM node:latest as build-stage
---> 34c1219e2da7
Step 2/11 : MAINTAINER drunk_kk
---> Using cache
---> bbb20c283f31
Step 3/11 : RUN npm install -g cnpm --registry=https://registry.npm.taobao.org
---> Using cache
---> 1102b372972c
Step 4/11 : WORKDIR /app
---> Using cache
---> 2f6b7f847d60
Step 5/11 : COPY . .
---> Using cache
---> 6f8b3db2fcb1
Step 6/11 : RUN rm -rf node_modules && npm install node-sass && cnpm run build
---> Running in 82c3765d6f32
npm notice
npm notice New patch version of npm available! 7.5.3 -> 7.5.6
npm notice Changelog: https://github.com/npm/cli/releases/tag/v7.5.6
npm notice Run npm install -g [email protected] to update!
npm notice
npm ERR! code EAI_AGAIN
npm ERR! syscall getaddrinfo
npm ERR! errno EAI_AGAIN
npm ERR! request to https://registry.npm.taobao.org/zrender/download/zrender-4.3.1.tgz failed, reason: getaddrinfo EAI_AGAIN registry.npm.taobao.org

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-02-23T06_03_30_520Z-debug.log
ERROR: Service 'web' failed to build: The command '/bin/sh -c rm -rf node_modules && npm install node-sass && cnpm run build' returned a non-zero code: 1

关于容器部署错误的建议

个人有2种想法:
1、构建好镜像,放到文件夹中。缺点:文件压缩包会很大,但只需要按照好docker和docker-compose就行了,没有构建容器的错误;
2、构建好镜像,推到docker仓库中,通过docker push 下载,最后通过docker-compose文件调用。

资产建议

建议
1.增加任务只能破解数据库弱口令,可以扫描域名和网站,漏扫功能
2.端口扫描,需要进行快速全端口扫描,和资产探测
3.目录扫描功能,参考dirsearch等
4.资产自动分类进行后测试,比如后台登录直接爆破,比如数据库端口直接数据库爆破,比如web服务有框架漏洞,直接poc验证,比如web门户,爬虫被动扫描等等
假设导入上万个ip,
1.进行全端口探测和资产扫描,
2.指纹识别,搜集信息
3.资产自动分类
4.资产定向自动测试

新增一个网段却无法开始扫描

例如,新增了一个132.97.0.0/16的网段,如附件,也更新了扫描设置,新增了任务列表,但是就是无法进行扫描,已经一两天了,还是扫描到了0个资产,请问下大佬,这种怎么解决呀~

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.