The public JAR API was also rechecked with javap, including the actual getThStatus(String) method, absence of a public logout API, ABRet.getDicDatas(), IrInfo.getStatus(), and downloadIrCodes(List<IrInfo>).
## Summary
- add a pure Kotlin/JVM anti-corruption layer for ABSDK 0630
- serialize blocking SDK calls and enforce one provider-scoped session
- map `ABRet`, raw maps, SDK exceptions, and error codes into typed domain results
- implement session, socket, temperature/humidity, and infrared gateways
- document bytecode-confirmed protocol facts, SDK limitations, and unresolved behavior
- align JVM module bytecode with the Android Java 17 target
## Scope boundaries
- the bridge is not wired into the Android app in this PR; debug continues using Fakes
- `setHostInfo` is intentionally not called or implemented as a provider flow
- logout clears only the bridge-local session because the JAR exposes no logout or token setter
- no real credentials, network calls, or hardware were used in tests
- `docs/requirement_spec.md` and `docs/project_plan.md` are unchanged
## Verification
```text
gradlew.bat --stop
gradlew.bat clean :absdk-bridge:test :domain:test :testing:fakes:test :android:app:lintDebug :android:app:assembleDebug :android:app:assembleRelease build
```
Result: `BUILD SUCCESSFUL`
The public JAR API was also rechecked with `javap`, including the actual `getThStatus(String)` method, absence of a public logout API, `ABRet.getDicDatas()`, `IrInfo.getStatus()`, and `downloadIrCodes(List<IrInfo>)`.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
ABRet, raw maps, SDK exceptions, and error codes into typed domain resultsScope boundaries
setHostInfois intentionally not called or implemented as a provider flowdocs/requirement_spec.mdanddocs/project_plan.mdare unchangedVerification
Result:
BUILD SUCCESSFULThe public JAR API was also rechecked with
javap, including the actualgetThStatus(String)method, absence of a public logout API,ABRet.getDicDatas(),IrInfo.getStatus(), anddownloadIrCodes(List<IrInfo>).PR Reviewer Guide 🔍
(Review updated until commit
13fd18a9f3)Here are some key observations to aid the review process:
明文传输:
AbsdkBridge.create()构造的厂商客户端会通过硬编码 HTTP 端点执行登录和设备操作,登录凭据派生值、会话 Token、设备状态及红外数据可能被窃听或篡改。@CleartextAbsdkTransport只提供编译期提示,并不保护实际链路。当前 PR 尚未将该实现接入 Android App,因此现有应用路径不会触发此风险;后续集成前必须落实文档所述的加密代理、HTTPS 或其他经批准的传输控制。已处理本轮意见:
AbsdkBridge.create()现在始终返回进程内同一个实例,使Mutex、活动 Session 与厂商进程级单例保持一致;新增工厂单例测试。DomainError.TokenInvalid时,Bridge 会同步清除本地 Session;新增测试验证会话清除以及后续操作不会继续进入 SDK。@CleartextAbsdkTransport编译期 opt-in 门禁,真实工厂和厂商 Client 都被标记;Bridge 继续未接入 App。架构与协议文档明确,在获批的 HTTPS、加密代理或其他传输控制确定前不得启用真实 ABox 入口。该门禁防止误接入,但不宣称提供了链路加密。完整测试、lint、debug/release 构建和全项目 build 均为
BUILD SUCCESSFUL。修复提交:
0e9b7df fix: guard global ABSDK session statePersistent review updated to latest commit
0e9b7dfd4b已处理红外总体错误码误判问题:
parseDownloadResult现在只允许00000和已确认表示逐项部分失败的20204进入ret解析;ret也不会被误判为成功;10002+ 合法ret必须返回TokenInvalid、清除本地 Session,且后续红外调用不会继续进入 SDK;20204逐项成功/失败测试继续通过;BUILD SUCCESSFUL。修复提交:
13fd18a fix: reject invalid infrared batch responses明文 HTTP 限制仍作为真实集成阻塞项保留;Bridge 尚未接入 App,
@CleartextAbsdkTransport只防误接入,不宣称提供链路加密。Persistent review updated to latest commit
13fd18a9f3