admin
2ece12d44b
rebrand: 收尾 —— 协议标识与表前缀一并换成 vupay
...
Docker Build (Gitea) / Build and Push Docker Image (push) Successful in 13s
之前刻意保留的三处,在没有订单数据的前提下一起改掉:
- 表前缀 bep_ → vupay_(6 张表 + gormigrate 的 vupay_migration)
- api_type 取值 "epusdt"/"epusdt_order" → "vupay"/"vupay_order"
- handler 包 app/handler/epusdt → app/handler/vupay、类型 Epusdt → Vupay、EpusdtSign → VupaySign
顺带清理:
- 删 docs/faq/vupay.md(整篇是「本项目和 EPusdt 的关系」的上游叙事)
- README 去掉「缘起于/原项目已转手」说明与上游致谢条目,联系邮箱不再指向 vupay.online
- 修 app/task/testenv_test.go 的 model.Init 调用(上一版加 MySQL 支持时漏了第三个参数,go build 不编译测试所以没暴露)
验证:go build ./... / go vet ./... / go test ./app/... 全通过;全仓 grep -i epusdt 归零
2026-11-25 09:22:48 +08:00
admin
a950fd2ead
rebrand: BEpusdt → VUPAY
...
Docker Build (Gitea) / Build and Push Docker Image (push) Successful in 47s
展示层与标识符全量改名:
- module github.com/v03413/bepusdt → git.viaeon.com/admin/vupay(含全部 import)
- 二进制/镜像/容器/DB 名 bepusdt → vupay(Dockerfile、workflow IMAGE、compose、docs)
- 显示名 BEpusdt → VUPAY(前端 title、后端 banner、version 命令、通知文案)
- 默认路径 /var/lib/bepusdt → /var/lib/vupay,/var/log/bepusdt → /var/log/vupay
- Telegram 通知的频道按钮原来指向上游 t.me 群,改成站点链接(否则改名后是死链)
刻意保留(运行语义,改了会坏):
- api_type 取值 "epusdt" / "epusdt_order"(库里存量数据按此匹配)
- 表前缀 bep_(bep_order / bep_conf / …,改需 RENAME TABLE 迁移)
- 签名函数 EpusdtSign 与 handler 包名 epusdt(对外协议语义,非品牌)
- 所有加密/会话派生的字面量原样不动
验证:gofmt 通过、go build ./... 通过、全仓 grep -i bepusdt 归零
2026-11-25 09:06:06 +08:00
admin
92cca8a420
perf(db): bep_order 加 (status,trade_type) 复合索引
...
Docker Build (Gitea) / Build and Push Docker Image (push) Successful in 13s
动机:转账/回调任务反复跑 WHERE status=? AND trade_type IN (...),原来只有单列索引。
10 万行实测(同机 mysql:8.0,1 核):
IN 两个值: 21.5ms → 0.9ms
IN 单值: 25.4ms → 16.0ms
COUNT: 11.4ms → 1.6ms
空表/小表无感,订单积累后差距明显。AutoMigrate 会在新库上自动建同名索引。
顺带:示例 compose 的小机器参数注释更新(buffer pool 256M、慢日志 1s)
2026-11-25 08:49:06 +08:00
admin
647e1b96b1
feat(db): 支持 MySQL(MYSQL_DSN 环境变量 / --mysql 参数)
...
Docker Build (Gitea) / Build and Push Docker Image (push) Successful in 46s
- app/cmd/flag.go: 新增 MysqlDSNFlag(env MYSQL_DSN)
- start/reset: 读取并传给 model.Init
- model.Init 改为三选一:MySQL > PostgreSQL > SQLite
- 新增 initMysql():连接池参数对齐 Postgres 那套(10/100、30m 生命周期)
- order.go: return_url / notify_url 从 TEXT 改 VARCHAR(1024)
MySQL 8 不允许 TEXT 列带 DEFAULT(Error 1101),改 varchar 三库通用
实测(真 mysql:8.0 容器):6 张表全部建出,bep_order 列类型符合预期
2026-11-24 19:58:08 +08:00
sylearn
c592d3fb7a
fix: fold truncate matching into has_prefix
...
Per review, drop the separate truncate mode and use its logic for
has_prefix instead. Order amounts are stored without trailing zeros
(1.50 as "1.5"), so the plain string prefix check let the 1.5 order
claim a 1.51 payment meant for a concurrent order on the same address.
Truncate the received amount to the larger of the atom precision and
the order's own decimals, then compare exactly: overpayment below the
atom precision still matches, underpayment and overpayment of a full
atom no longer do.
2026-11-01 22:49:44 +09:00
sylearn
5cb1d6f099
feat: add truncate amount match mode
...
Truncate the received amount to the atom precision before an exact comparison, so overpayment below the atom precision still matches while concurrent orders on one address (1.50, 1.51, ...) never claim each other's payments.
2026-10-31 23:45:49 +09:00
sylearn and Claude Opus 5.5
014bb8e12b
feat(solana): reconcile expired orders against token account history
...
Block scanning gives every slot one chance. A skipped or abandoned slot,
a restart, or an incomplete lookback range loses a payment for good, and
nothing finds it again.
Once a Solana order has been expired for a minute (up to two hours), look
it up once in the receiving token accounts' own history:
- token accounts: the wallet's associated token account, derived locally,
plus any other account from getTokenAccountsByOwner when the node
supports it (publicnode's free tier rejects that method);
- getSignaturesForAddress back to the order's creation time, keeping
successful signatures inside the order window that no order has used;
- getTransaction, parsed with parseTransaction and checked with the
existing orderTransferMatch. A match is marked confirming and then
follows the normal confirm and callback flow.
RPC errors leave the order for the next round. Cost: a few RPC calls per
expired Solana order plus one getTransaction per candidate payment.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com >
2026-10-18 13:41:36 +08:00
v03413
d36d34fe04
fix: 订单 URL 字段改为 text
...
return_url/notify_url 原为 varchar(255),超长时 PostgreSQL 写入订单报错 (SQLSTATE 22001),由 AutoMigrate 自动变更列类型。
Fix #234
2026-10-15 18:07:53 +08:00
betaxab
7eb0263193
fix: Fixed the issue of dropped orders on the TON blockchain
...
fix: Set "lookbackDone" only after the lookback has truly completed.
misc: Move TON address validation to utils.
2026-07-24 03:57:58 +08:00
v03413
b321da7bba
feat: add checkout network ordering
2026-07-15 10:14:56 +08:00
long2ice
efd1ce348a
fix: use match_address when locking exclusive wallets
...
LockTradeAddress queried bep_order with match_addr (wallet column),
causing Error 1054 and breaking exclusive address checks.
2026-07-14 01:11:03 +08:00
v03413
43c579198a
fix: remove order fingerprint index
2026-07-08 17:45:24 +08:00
v03413
e180b52c9a
Merge branch 'refs/heads/main' into Fingerprint
...
# Conflicts:
# app/handler/epusdt/epusdt.go
# app/model/order.go
# app/model/trade.go
2026-07-08 17:38:16 +08:00
v03413
3ca46e7fb9
fix: enforce fingerprint checks on payments
2026-07-08 17:32:11 +08:00
v03413
8076cd4b75
refactor: remove MySQL support and add migrations
2026-07-08 15:47:40 +08:00
v03413
e5e847f18f
feat: always allow payment type reselect
2026-07-08 10:45:51 +08:00
v03413
54e73e48e4
fix: filter empty TronGrid API keys
2026-07-08 09:22:52 +08:00
v03413
451da12e09
feat: add client fingerprint checks for orders
2026-07-08 09:20:29 +08:00
betaxab
1f92306b03
fix: wallet.go: Pre-initialize MatchAddr = Address to prevent issues: #213
2026-06-27 19:32:26 +08:00
betaxab
79982c935f
fix: order model: add default:0 value to fix #211
2026-06-26 13:17:50 +08:00
betaxab
aafbac7b7b
feat: Add the ability to reselect order trade types
2026-06-24 00:51:20 +08:00
v03413
2edf26857e
feat: add configurable order lookback hours
2026-06-21 16:23:55 +08:00
v03413
13d3fad174
refactor: move block api package to core
2026-06-21 01:30:04 +08:00
v03413
5e598cd2f3
feat: add unified checkout template
2026-06-21 01:24:12 +08:00
v03413
c350868195
perf: set Coingecko request user agent
2026-06-19 01:35:14 +08:00
v03413
d458ef7ca3
feat: add API-backed block lookback
2026-06-19 01:33:56 +08:00
狼哥
9ac18ade71
Add LangGe checkout template mode
2026-06-17 03:28:59 -07:00
Jason.li
1e52f40a6c
Merge origin/main into payment reconciliation fix
2026-06-07 14:40:38 +08:00
Jason.li
f28ae2aa8d
fix(solana): reconcile missed token payments
...
Add a Solana reconciliation task that backfills recent waiting, expired, and failed orders by scanning token accounts, signatures, and parsed transactions for matching SPL transfers.
Reuse shared order matching for realtime transfer handling, return DB errors from MarkConfirming, and keep confirming orders eligible when the on-chain payment timestamp was inside the order window even if final confirmation happens after expiry.
2026-06-07 12:51:23 +08:00
v03413
2bf1406566
feat: rename TON native coin to GRAM
...
ref: https://t.me/toncoin/2384
ref: https://ton.vote/EQDQvywF226NXojPky_9gwbCz0FPoygqY11bGl03SONNBs5V/proposal/EQAv-VS2OM80SYLB0ouRWRcpFg4J0L-egUf1-utF-OJ6h0rK
2026-06-03 15:25:41 +08:00
v03413
94440de2d3
feat: 增加支持自定义主页跳转
...
feat: https://github.com/v03413/BEpusdt/issues/197
2026-06-02 21:46:07 +08:00
v03413
ea113e6e90
feat: 增加支持 Ton 区块链网络扫块
...
新增交易类型 ton.toncoin usdt.ton
close: https://github.com/v03413/BEpusdt/pull/192
2026-06-02 21:03:19 +08:00
betaxab
cb5aed93c6
perf: add order notify retry index
2026-05-02 17:18:05 +08:00
v03413
94ba4b7c5b
perf: remove default currency limit setting in BuildOrder
...
fix: https://github.com/v03413/BEpusdt/issues/178
2026-04-25 21:15:30 +08:00
v03413
6ccd93a161
feat: 增加支持历史汇率自动清理
2026-04-16 10:57:57 +08:00
v03413
2edf71dee1
feat: 增加支持自定义Topic 路径前缀
2026-04-15 21:44:34 +08:00
v03413
c4d5e20c7a
feat: 实现交易监听 MQTT服务器广播
2026-04-15 14:58:24 +08:00
v03413
30eb6659d8
feat: 实现钱包地址独占模式 & 安全优化
2026-04-14 13:36:54 +08:00
v03413
f866db9f1b
feat: 配置支持多个 trongrid key
...
多个用半角符逗号隔开,使用的时候随机抽取
feat: https://github.com/v03413/BEpusdt/issues/171
2026-04-07 14:05:34 +08:00
v03413
8c4ead0169
fix: ensure Datetime uses local time zone
2026-02-27 15:20:34 +08:00
v03413
9e7707588f
perf: remove hardcoded secret
2026-02-27 14:22:29 +08:00
v03413
0db728dc52
fix: synchronize BuildOrder correctly
2026-02-27 14:00:54 +08:00
v03413
6a2f3b6d6e
feat: add PostgreSQL database support
2026-02-26 14:51:53 +08:00
v03413
0ed85860fc
feat: add block offset confirmation feature
...
resolved: https://github.com/v03413/BEpusdt/issues/160
2026-02-22 22:11:38 +08:00
v03413
e7e1cae418
refactor: streamline request host handling and adjust url paths
...
解决后台创建订单,在某些反代服务器下无法识别 scheme 问题 && 调整部分路由;既然已经做到了这一步,后期可考虑直接将两个收银台合并,无论是逻辑还是界面
2026-02-22 19:47:29 +08:00
betaxab
7d926f4dae
fix: rebuild order should include the crypto and rate param
...
fix: GetTxUrl prevents cases where the URL is empty
2026-02-20 17:58:36 +08:00
betaxab
cd656eb455
feat: Methods API blacklist mode
2026-02-19 11:53:55 +08:00
betaxab
13388f197d
feat: admin: order/create api
2026-02-19 02:55:30 +08:00
betaxab
a9a94a1413
feat: Complete the backend support for the checkout cashier
2026-02-18 18:18:39 +08:00
betaxab
8478d47abf
feat: Add Update order API
2026-02-18 18:18:27 +08:00