Initial import of Brizzi HCE project

This commit is contained in:
2026-05-03 10:23:41 +07:00
commit 9994823fb3
693 changed files with 51541 additions and 0 deletions

Binary file not shown.

Binary file not shown.

BIN
references/Brizzi/Hash.pdf Executable file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
references/Brizzi/Redeem Inq.pdf Executable file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
references/Brizzi/Void.pdf Executable file

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,56 @@
# BRIZZI HCE Debug Playbook
Tujuan: verifikasi alur HCE pada reader/terminal nyata atau emulator NFC test tool.
## 1) Jalankan Aplikasi
- Build & install APK.
- Hubungkan device yang akan dipakai sebagai kartu HCE (Android phone).
- Pastikan NFC aktif.
## 2) Aktifkan logcat untuk HCE
Jalankan:
```bash
adb logcat -s BrizziHce:* *:S
```
Jika aplikasi tidak berjalan sebagai debug build, gunakan:
```bash
adb logcat -v time | rg "BrizziHce"
```
## 3) Kasus uji minimum
1. Arahkan reader ke perangkat.
2. Perhatikan urutan awal:
- `HOST_APDU_SERVICE` muncul (select AID).
- `APDU recv: ...` kemudian `APDU out=...`.
3. Uji flow:
- `SELECT AID 3` -> harus ter-respon sukses.
- `SELECT AID 1` -> harus sukses.
- `GET_CARD_INFO`, `GET_BALANCE`, dll sesuai mode.
4. Setelah sesi selesai/berubah reader, pastikan `onDeactivated` terpicu.
5. Jika transaksi sudah mulai dan gagal, kirim `ABORT_TRANSACTION` untuk memastikan state cleared.
## 4) Catatan troubleshooting cepat
- Jika service tidak terpicu:
- Cek apakah AID di `res/xml/apdu_service.xml` sesuai request reader.
- Jika banyak status 6985:
- Reader memanggil command di AID3 tanpa autentikasi.
- Pastikan urutan `SELECT AID3` + `GET KEY` + challenge/authenticate.
- Jika banyak status 6A82:
- Command tidak dikenal/length tidak cocok; log hex raw untuk koreksi parser.
## 5) Template log capture
Contoh pattern yang diambil dari logcat:
- `APDU recv: 12 bytes | CLA=90 INS=BD P1=00 ...`
- `APDU out=...`
- `HCE deactivated: X`
Simpan log per sesi agar mudah dibandingkan dengan trace reader real.