Skip to content

Commit

Permalink
add 完成 百度云 & 百度图片 验证码自动识别
Browse files Browse the repository at this point in the history
rm dev目录
fix date more
up version to 1.3
  • Loading branch information
feix760 committed Dec 24, 2015
1 parent 7149912 commit 6d9fb45
Show file tree
Hide file tree
Showing 85 changed files with 2,015 additions and 5,739 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,10 @@ src.pem
.DS_Store
.project
.settings
*.log
*tmp
/dev
/build
/node_modules
/server/img/
/server/test.js
36 changes: 28 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# 12306 Chrome插件
# 12306 Chrome插件, 已实现验证码自动识别

# 开发
## 开发

使用[fis3](http://fis.baidu.com/fis3/docs/beginning/intro.html)构建:

Expand All @@ -20,15 +20,35 @@ fis3 release -w dev
npm install -g fis3-parser-sass
```

# 安装
## 验证码自动识别

chrome浏览器 -> settings -> extensions -> load unpacked extension -> 选择`dev`目录
依靠[百度云ocr](http://bce.baidu.com/solution/image.html)[百度图片](http://image.baidu.com/)

# 问题
`百度云ocr`需要用户认证信息(现阶段使用免费), 使用步骤如下:

- 12306登陆自动退出(非插件问题)
- 注册
- 实名认证
- [控制台](https://console.bce.baidu.com/?_=1450796271208#/index/overview)开通`对象存储 BOS`服务
- 获取`ak`(access key)和`sk`(secret key), 填入抢票页面中(url默认)

# doing
### 启动识图服务

使用百度云ocr、百度图片自动识别验证码(`code分支`)
识图服务不在`Chrome`中运行, 换用`node`服务, 进入目录

```sh
npm install
node app.js
```

## 安装

Chrome浏览器 -> settings -> extensions -> load unpacked extension -> 选择`dev`目录(参考`开发`生成)

## 问题

- 12306登陆自动退出(非插件问题)

## 加入我们

- `git push`

28 changes: 28 additions & 0 deletions app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/**
* @file app
* @date 2015-12-22
*/
var
http = require('http'),
express = require('express'),
bodyParser = require('body-parser'),
controller = require('./server/controller'),
port = 8101;

var app = express();

app.use(bodyParser.json());
app.use(bodyParser.urlencoded({
limit: '1mb',
extended: true
}));

// route
app.use('/recognize', controller.recognize);

app.listen(port, function() {
console.log('Server listening on port %d', port);
});

module.exports = app;

46 changes: 0 additions & 46 deletions dev/background.js

This file was deleted.

Binary file removed dev/icon32.png
Binary file not shown.
Binary file removed dev/icon48.png
Binary file not shown.
22 changes: 0 additions & 22 deletions dev/manifest.json

This file was deleted.

89 changes: 0 additions & 89 deletions dev/modules/common/Chrome.js

This file was deleted.

41 changes: 0 additions & 41 deletions dev/modules/common/lib.js

This file was deleted.

24 changes: 0 additions & 24 deletions dev/modules/common/station_name.js

This file was deleted.

66 changes: 0 additions & 66 deletions dev/modules/css/common.css

This file was deleted.

Binary file removed dev/modules/css/images/animated-overlay.gif
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_flat_0_aaaaaa_40x100.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_flat_75_ffffff_40x100.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_glass_55_fbf9ee_1x400.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_glass_65_ffffff_1x400.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_glass_75_dadada_1x400.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_glass_75_e6e6e6_1x400.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-bg_glass_95_fef1ec_1x400.png
Binary file not shown.
Binary file not shown.
Binary file removed dev/modules/css/images/ui-icons_222222_256x240.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-icons_2e83ff_256x240.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-icons_454545_256x240.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-icons_888888_256x240.png
Binary file not shown.
Binary file removed dev/modules/css/images/ui-icons_cd0a0a_256x240.png
Binary file not shown.
5 changes: 0 additions & 5 deletions dev/modules/css/jquery-ui-1.10.3.css

This file was deleted.

Loading

0 comments on commit 6d9fb45

Please sign in to comment.