1
0
mirror of https://github.com/Mrs4s/go-cqhttp.git synced 2025-05-05 03:23:49 +08:00

31 Commits

Author SHA1 Message Date
源文雨
fd6ef4a2b8 optimize(qisgn): async operations
FYI: @1umine
2023-08-28 16:56:19 +08:00
Lumine
f8354ec082
修复TCP缓冲区不足问题;重构 qsign 签名服务对接部分;支持配置多个签名服务器 (#2389)
* fix: skip callback error

* update: update comment

* change the logic of callback and auto-register

* add token update prompt.

* fix log buffer string

* fix #2368

增加对 client 的利用,避免创建过多 clients

* refactor: wrap sign request

* feat: impl additional sign servers configuration

* fix error in using configurations.

* fix lint error

* 支持切换回主签名服务器

* feat: support different key and auth

* optimize: find avaliable sign-server

* fix: register instance after server is changed

* fix lint error

* update: add config 'sync-check-servers'

* update: first check master sign-server, or wait 3s

* add checking log & optimize wait for checking done

* fix wrong judge

* add config: rule for changing sign server

* optimize registration logic after changing server

* add some log

* fix #2390

* resolve requested changes in #2389

* update dependency

* fix lint error 'idx is unused'

* refactor: extract sync check and async check logic

* delete async check sign-server
2023-08-27 13:19:38 +08:00
Bluefissure
88f5db89a8
feat: add Bearer authentication to sign server requests (#2247)
* feat: add sign-server-bearer

* fix: golint

* fix: golint

* fix: remove trimprefix

---------

Co-authored-by: 源文雨 <41315874+fumiama@users.noreply.github.com>
2023-08-01 11:15:31 +08:00
源文雨
7c813f8579 feat: add config sign-server-timeout 2023-08-01 11:09:04 +08:00
Lumine
f466ca7a72
feat: 提供 1.1.6 版本以上 qsign 的对接支持 (#2307)
* 增加签名服务超时设置

* 获取签名和err为空时尝试重新注册实例

* 可配置自动刷新token以及自动注册

* fix lint

* wrap callback

* add config: refresh-interval

* support qsign's `auto-register`

* fix: add registerLock to avoid repeat registraion.

* update: Enable disabling auto token refresh

* fix: use string android_id (not hexadecimal

* update default_config.yml

* fix: compatible with older  qsign (bellow 1.1.0

* fix: refresh token

* update dependency

* update go.sum

* fix: fix warnings on old version sign server

---------

Co-authored-by: 源文雨 <41315874+fumiama@users.noreply.github.com>
2023-08-01 10:33:32 +08:00
KomeiDiSanXian
6cf8030d3c update: 兼容签名服务器到v1.1.3 2023-07-10 07:15:43 +08:00
Mrs4s
9c1390c75c
feat: support sign server 2023-06-27 18:11:06 +08:00
Mrs4s
0b90074a48
feat: http timeout setting 2023-04-08 17:08:53 +08:00
Mrs4s
1ab1cba84c
rf: change protocol auto-update to manual update 2023-04-02 18:04:13 +08:00
Mrs4s
0312f05f6e
feat: basic protocol auto-updater 2023-03-15 02:33:04 +08:00
wdvxdr
84e061f321 make golangci-lint happy 2023-01-26 22:59:04 +08:00
Maiko Tan
2a4ea28f4d
feat: add webp image convert function 2023-01-05 21:58:37 +08:00
wdvxdr
18a091145a
style: go fmt ./...
also delete mkrw.go, we can maintain this file by hand.
2022-04-14 21:53:00 +08:00
wdvxdr
34613306b3
internal/mime: use stdlib to detect mimetype 2022-03-18 17:07:10 +08:00
wdvxdr
76295b0e89
dep: update MiraiGo 2022-03-17 16:59:47 +08:00
wdvxdr1123
9054d4cee8
db/leveldb: impl index read/write drop encoding/gob (#1370)
Two benefit below:
 * shrink go-cqhttp binary size about 200KiB
 * shrink database file from 2.8M to 1.56M compared with v2 database

Also provide a tool to migrate v2 database:
https://github.com/RomiChan/gocq-leveldb-migrate
2022-02-15 22:24:27 +08:00
github-actions[bot]
0145879f37 ci(chore): Fix stylings 2022-02-09 07:02:21 +00:00
wdvxdr
e1937e9f15
docs: document default env placeholder 2022-02-09 15:01:38 +08:00
wdvxdr
8eefcc8cc8
config: impl env placeholder with default value
Fixes #1358
2022-02-09 13:41:19 +08:00
wdvxdr
82b0c69b1b
config: remove old env config
Fixes #1219
2022-02-06 22:19:30 +08:00
Mrs4s
a5dd0bfa1f
feat: disable temp session by default 2022-01-24 19:52:13 +08:00
wdvxdr
b98f75ccab
style: run gofumpt 2021-12-29 14:04:51 +08:00
秋葉あんず
49aedc99fe
fix(expand env): change os.ExpandEnv to regex (#1231)
* fix(expand env): change os.ExpandEnv to regex

* fix: MustCompile

* fix: regex
2021-12-09 17:53:40 +08:00
源文雨
26a7a1f0b6
feat(config): separate config & server (#1212)
* feat(server): add RegisterCustom

* feat(config): seprate config & server

* fix: make lint happy

* fix: make lint happy

* fix: ParseEnv nil pointer error

* typo(config): generateConfig hint

* fix(config): panic on range overflow
2021-12-07 22:39:30 +08:00
wdvxdr
aa2caac3f7
feat: support expand env 2021-12-06 22:31:02 +08:00
openwrt2223
72fec47622
Update modules/config/config.go
https://github.com/Mrs4s/go-cqhttp/issues/1169#issuecomment-970192648
2021-11-19 00:44:27 +08:00
Akiba
4de5efc813
fmt 2021-11-15 11:13:08 +08:00
Akiba
77580ae8ef feat(log): add switch for colorful logging 2021-11-15 02:04:04 +08:00
wdvxdr
d464236573
fix: make linter happy
add db into skip-dirs
2021-09-28 15:46:14 +08:00
wdvxdr
c4d34fa14f
Merge branch 'dev' into database-support
# Conflicts:
#	coolq/bot.go
#	modules/config/config.go
2021-09-26 19:49:48 +08:00
wdvxdr
1337d3f1f3
style: move internal/config to modules/config
config should not be internal, maybe some module need it.
2021-09-26 19:41:03 +08:00