Giter VIP home page Giter VIP logo

situational-awareness's Introduction

Situational-Awareness 态势感知系统

参考:https://github.com/lw1988/PyAwearnessSystem

态势感知系统,基于python和flask

2023-04-27 没想到随便写的系统会受到这么多人关注,所以想对这个系统进行升级和维护,原始代码已经打包到release v1.3,此代码适用于学生,个人,学习,等用途,到V1.3原则上不会再更新。

新系统将加入机器学习,取名Polestar(极星),仓库地址为:https://github.com/cmluZw/Polestar

V1.3

Situational-Awareness

态势感知系统

近期发现某公众号未经本人允许私自售卖此系统以牟利,我在此郑重声明,此态势感知系统开源,望某公众号尽快下架作品,或者免费下载且标明作品作者,拒绝一切未经本人允许的商业用途!!!

前提:此系统只是作者学习flask和态势感知时练手的程序,写的不好,望谅解
V1.3已经打包到右边发行里,请自取,请不要吝啬您的点赞QVQ,小小的点赞带给作者大大的快乐

开发

一个基于linux的态势感知系统,基于python和flask框架开发,项目目录如下:

· admin -核心算法
· charts -图表生成
· model -类
· app.py -主文件
· config.py -配置文件

安装

请下载右边发行代码,数据库文件situational.sql也在发行里,请提前安装好mysql,apache,并启动

配置

数据库密码默认设置为root1/123456789,后台默认初始密码为:admin/123456,apache日志为默认路径
如需修改,请修改config.py里的数据库密码和路径

邮箱密码

如果不需要告警可忽略,需要告警请自行配置config.py和app.py里的邮箱和密码(ps:这里的密码是邮箱授权码)

环境

适配linux,且由于作者水平有限,中间件只支持apache,确保linux用户权限为root,且安装有iptables防火墙命令(不需要告警可忽略iptables)
python3(最好是3.7-3.9,过低或过高会报奇怪的错误),pyecharts0.x
特别说明,在官方给出解决办法之前请勿安装jinja3.1.1,不然会因markup被破坏无法渲染到前端)

安装命令

在以上基础下,执行以下命令进行安装:
安装依赖,请用pip3执行:

pip3 install -r requirements.txt

安装mysql数据库:
sudo apt install mysql-server
创建数据库用户:

CREATE USER 'root1'@'localhost' IDENTIFIED BY '123456789'; GRANT ALL ON *.* TO 'root1'@'localhost'; flush privileges;
create database situational; use situational; source situational.sql;

在依赖和数据库都安装成功成功后,执行

python3 app.py

待控制台输出以下字样即安装成功
INFO:werkzeug: * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)

****访问127.0.0.1:5000即可

如遇报错,请先查看:#6

使用

对apache网站进行检测,所以如需模拟攻击请攻击服务器上的apache网站。

界面展示

登录

image

主页

image

ip管理

image

溯源数据

image

动态demo效果图

预览

后续和支持

如需测试数据,有bug提交,或是有建议,请联系作者本人(* ̄︶ ̄) ps:需要测试数据的话,请作者喝杯奶茶吧(* ̄︶ ̄)

作者qq:2534395766,请备注来意,以便通过 (^▽^)

若觉得本项目对你有帮助,可以给作者点个❤嘛~~

situational-awareness's People

Contributors

cmluzw avatar lisisiejid avatar

Stargazers

 avatar  avatar  avatar N1g0yBug avatar  avatar john avatar  avatar  avatar  avatar lan1oc avatar  avatar boX avatar lhswg avatar  avatar NieR avatar  avatar  avatar  avatar  avatar  avatar Zzh avatar moonz avatar sleep avatar  avatar  avatar  avatar  avatar  avatar Brian avatar  avatar  avatar Liar avatar  avatar  avatar  avatar  avatar  avatar trader avatar MagicSw0rd avatar  avatar  avatar  avatar  avatar Yang.Hu avatar  avatar  avatar  avatar 谢大大 avatar Fatmouse avatar MidNight156 avatar  avatar  avatar Yan Yu avatar  avatar  avatar wade2ng avatar  avatar  avatar yxl avatar Mi avatar  avatar  avatar wangyuam avatar  avatar  avatar scriptkid avatar shenjf avatar ysec avatar  avatar S_0127 avatar xiaoxiaoranxxx avatar  avatar It's Anny avatar hirak0 avatar cc Allen avatar Asenlen avatar MathxH Chen avatar 1s avatar Tim Huang avatar aofa~ avatar  avatar  avatar  avatar  avatar  avatar Johnson avatar  avatar  avatar thestar0 avatar yin avatar  avatar  avatar  avatar K avatar ForVictory avatar Antares avatar 星冉 avatar SuperWinner avatar zeroer avatar  avatar

Watchers

 avatar  avatar

situational-awareness's Issues

install.py无法运行

本人python3.5
使用python3 install.py时报错
报错如下:
Traceback (most recent call last):
File "Install.py", line 2, in
import pymysql
File "/usr/local/lib/python3.5/dist-packages/pymysql/init.py", line 59, in
from . import connections # noqa: E402
File "/usr/local/lib/python3.5/dist-packages/pymysql/connections.py", line 206
):
^
SyntaxError: invalid syntax

如遇报错请先看这

1.[Errno 32]Broken pipe


一般是在执行install.py时遇到的,解决方法为:
1.控制python版本在3.7-3.9之间
2.不要使用install.py,按照主页说明文档,手动安装
3.百度

2.与json相关的错误


1.安装flask=2.0.2(pip3 install flask==2.0.2)
2.从github替换https://github.com/cmluZw/Situational-Awareness/blob/master/output/analyse/network/flowStatistics.txt这个文件
3.百度

3.已经安装过库后依旧报找不到库


1.查找运行app.py的版本是否是安装库对应的版本
2.百度

4.cannot import name ‘Pie’ from ‘Pyecharts’

pyecharts版本安装得太高,只支持0.5.x,重新pip安装requirements.txt

5.部署成功后无法显示主页或者主页乱码

1.使用谷歌或者火狐浏览器

2.清空数据库

3.百度

在确定版本正确,环境正确,且按照说明文档的安装百度之后依然无法解决,找我

数据库连接出问题

你好请问数据库怎么连接,这边连数据库一直出现问题,请问怎么解决?

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.