docs: map msglib dotnet wrapper path
This commit is contained in:
@@ -27,7 +27,7 @@ Remote base before local roadmap commits: `b2d839e Merge branch 'codex/n15-repor
|
|||||||
- `scripts/verify-win-helper.ps1` and `scripts/verify-go-mcp.ps1` provide repeatable local checks for the helper, eight-tool MCP surface, default empty-source receive/contact/group/file calls, synthetic configured-file receive/contact/group/file smoke, and synthetic configured-directory receive/contact/group/file smoke.
|
- `scripts/verify-win-helper.ps1` and `scripts/verify-go-mcp.ps1` provide repeatable local checks for the helper, eight-tool MCP surface, default empty-source receive/contact/group/file calls, synthetic configured-file receive/contact/group/file smoke, and synthetic configured-directory receive/contact/group/file smoke.
|
||||||
- `isphere_receive_messages` now returns the contract-facing `ok`, `conversation`, `messages`, `next_cursor`, and `audit` envelope while retaining legacy parser-native message fields for compatibility.
|
- `isphere_receive_messages` now returns the contract-facing `ok`, `conversation`, `messages`, `next_cursor`, and `audit` envelope while retaining legacy parser-native message fields for compatibility.
|
||||||
- `isphere_receive_messages` accepts the read-contract argument set for the current local-readonly path: `conversation_id`, `query`, `since`, `limit`, `include_attachment_metadata`, `source_preference`, `preview`, and empty `cursor`.
|
- `isphere_receive_messages` accepts the read-contract argument set for the current local-readonly path: `conversation_id`, `query`, `since`, `limit`, `include_attachment_metadata`, `source_preference`, `preview`, and empty `cursor`.
|
||||||
- `isphere_search_contacts` and `isphere_search_groups` accept and validate the safe search-contract args for the current local-readonly path, but display names/member data remain JID-derived/unknown because C23/C24 found no validated DB read path yet.
|
- `isphere_search_contacts` and `isphere_search_groups` accept and validate the safe search-contract args for the current local-readonly path, but display names/member data remain JID-derived/unknown until C26 validates copied `MsgLib.db` read-only schema access.
|
||||||
- `isphere_receive_files` list mode accepts and validates the safe file-list contract args for the current local-readonly path while keeping download blocked.
|
- `isphere_receive_files` list mode accepts and validates the safe file-list contract args for the current local-readonly path while keeping download blocked.
|
||||||
- N12-pre and N12R documents define safe offline evidence intake and internal-sandbox live UIA capture procedures.
|
- N12-pre and N12R documents define safe offline evidence intake and internal-sandbox live UIA capture procedures.
|
||||||
- N13/N14/N15 produced selector catalog/report validation infrastructure, but those are supporting validation assets only.
|
- N13/N14/N15 produced selector catalog/report validation infrastructure, but those are supporting validation assets only.
|
||||||
@@ -55,7 +55,7 @@ N13/N14/N15 are pre-business validation results. They can help identify UI eleme
|
|||||||
|
|
||||||
## Current loop
|
## Current loop
|
||||||
|
|
||||||
Current loop: `Stage C / Loop C25 - static .NET DB wrapper analysis`.
|
Current loop: `Stage C / Loop C26 - copied MsgLib.db read-only schema extraction`.
|
||||||
|
|
||||||
Plan file: `docs/superpowers/plans/2026-07-09-stage-c-log-backed-receive-messages-loop.md`.
|
Plan file: `docs/superpowers/plans/2026-07-09-stage-c-log-backed-receive-messages-loop.md`.
|
||||||
|
|
||||||
@@ -92,10 +92,11 @@ Current loop output so far:
|
|||||||
22. C22: `isphere_receive_files` list mode now accepts and validates safe contract args, rejects unsupported source/cursor/output/download cases, and keeps download blocked.
|
22. C22: `isphere_receive_files` list mode now accepts and validates safe contract args, rejects unsupported source/cursor/output/download cases, and keeps download blocked.
|
||||||
23. C23: display-name enrichment was blocked because current committed evidence and ignored metadata do not validate a JID-to-display-name/group-title source; `MsgLib.db` remains the most likely next source but inspected copies are not directly readable as SQLite.
|
23. C23: display-name enrichment was blocked because current committed evidence and ignored metadata do not validate a JID-to-display-name/group-title source; `MsgLib.db` remains the most likely next source but inspected copies are not directly readable as SQLite.
|
||||||
24. C24: `MsgLib.db` readability precheck found high-entropy non-SQLite files with a consistent wrapper/encryption signature; wrapper candidates include `HYHC.IMPP.DAL.dll`, `Utilities.Lib.SQLiteInteraction*.dll`, `Utilities.Lib.DBModel.dll`, and `RepairDatabase.exe`.
|
24. C24: `MsgLib.db` readability precheck found high-entropy non-SQLite files with a consistent wrapper/encryption signature; wrapper candidates include `HYHC.IMPP.DAL.dll`, `Utilities.Lib.SQLiteInteraction*.dll`, `Utilities.Lib.DBModel.dll`, and `RepairDatabase.exe`.
|
||||||
|
25. C25: static .NET wrapper analysis recovered the DAL open path: `HYHC.IMPP.DAL.IMPPDAL` configures `System.Data.SQLite` through `Utilities.Lib.DBSQLite`, sets `DatabaseName` to the DB path and `Password` to `123`, and exposes candidate display/message tables such as `TD_Roster`, `tblRecent`, `tblPersonMsg`, `tblMsgGroupPersonMsg`, and `TD_WorkGroupAuth`.
|
||||||
|
|
||||||
## Next business mainline
|
## Next business mainline
|
||||||
|
|
||||||
1. Run Stage C Loop C25: statically inspect the .NET DB wrapper assemblies to map table/model names and connection-string/password/decryption flow before any copied-DB read attempt.
|
1. Run Stage C Loop C26: attempt copied `MsgLib.db` read-only schema extraction with the recovered wrapper password/connection flow; query schema and counts only, not message bodies/personal values.
|
||||||
2. Leave `isphere_send_message` blocked until bridge/API, UIA action-chain, or protocol connector evidence is validated.
|
2. Leave `isphere_send_message` blocked until bridge/API, UIA action-chain, or protocol connector evidence is validated.
|
||||||
3. Leave actual file download/cache mapping as a later connector node until a message-to-cache hash or client download source is validated.
|
3. Leave actual file download/cache mapping as a later connector node until a message-to-cache hash or client download source is validated.
|
||||||
4. Keep UIA selector/report work as fallback support, not as the primary roadmap.
|
4. Keep UIA selector/report work as fallback support, not as the primary roadmap.
|
||||||
|
|||||||
@@ -0,0 +1,99 @@
|
|||||||
|
# Static .NET DB wrapper analysis for MsgLib.db
|
||||||
|
|
||||||
|
Date: 2026-07-10
|
||||||
|
|
||||||
|
## Question
|
||||||
|
|
||||||
|
Can the copied `MsgLib.db` files be opened through the same .NET wrapper path used by the iSphere/IMPP client, and which tables/fields are likely to unlock contact, group, message, and file metadata?
|
||||||
|
|
||||||
|
## Evidence checked
|
||||||
|
|
||||||
|
Ignored read-only IL/metadata generated from the copied archive:
|
||||||
|
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/HYHC.IMPP.DAL.dll.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/Utilities.Lib.DBBase.dll.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/Utilities.Lib.DBModel.dll.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/Utilities.Lib.DBSQLite.dll.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/Utilities.Lib.SQLiteInteraction.dll.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/RepairDatabase.exe.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/IMPP.Model.dll.il`
|
||||||
|
- `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-wrapper-il-summary.json`
|
||||||
|
|
||||||
|
`IMPP.Model.dll`, `Utilities.Lib.DBBase.dll`, and `Utilities.Lib.SQLiteInteractionBase.dll` were added to the C25 static inspection because the original C24 wrapper candidates reference them directly. No client executable was run, no original DB was modified, and no raw DB bytes/decrypted message content are committed.
|
||||||
|
|
||||||
|
## Connection/password flow findings
|
||||||
|
|
||||||
|
1. `HYHC.IMPP.DAL.IMPPDAL` is the client DAL entry point for `MsgLib.db`. Its private constructor accepts `dbPath` and `userInfoDomain`, creates a `DBConfigElement`, and configures:
|
||||||
|
- `DBID = 0x1a0a`;
|
||||||
|
- `DBConInfoType = 1`;
|
||||||
|
- `DatabaseName = dbPath`;
|
||||||
|
- `Password = "123"`;
|
||||||
|
- `ConName = Path.GetFileName(dbPath)`;
|
||||||
|
- `DBFactory = "Utilities.Lib.DBSQLite.Core.SQLiteDBFactory,Utilities.Lib.DBSQLite"`.
|
||||||
|
2. The same constructor registers the config through `ConfigManager.AddConfigItem(...)`, obtains `_dbAccess` through `DBAccessManager.GetDBAccessInstance(DBID)`, and checks the DB with `IsDBDamage(dbPath)` when the file exists.
|
||||||
|
3. `Utilities.Lib.DBBase.Base.DBInteractionBase.GetDBConStr(...)` is the central connection-string switch:
|
||||||
|
- if `DBConfigElement.Decryption` is empty and `DBConInfoType == 0`, it uses `ConStr` directly;
|
||||||
|
- if `DBConfigElement.Decryption` is empty and `DBConInfoType != 0`, it calls `GenerateDBConStr(config, visitType)`;
|
||||||
|
- if `Decryption` is set, it instantiates an `IConStrDecryption` implementation and delegates `GetDBConStr(config, visitType)` to it.
|
||||||
|
4. `Utilities.Lib.SQLiteInteraction.Interaction.GenerateDBConStr(...)` constructs a `System.Data.SQLite.SQLiteConnectionStringBuilder` and, for the DAL path above, sets:
|
||||||
|
- `Pooling = true`;
|
||||||
|
- `DataSource = GetFullPath(DatabaseName)`;
|
||||||
|
- `Password = DBConfigElement.Password` when non-empty;
|
||||||
|
- `ReadOnly = true`;
|
||||||
|
- then returns the builder `ConnectionString`.
|
||||||
|
5. `Utilities.Lib.SQLiteInteraction.Interaction.GetConnection(...)` creates `System.Data.SQLite.SQLiteConnection(connectionString)`.
|
||||||
|
6. `Utilities.Lib.DBSQLite.Core.SQLiteInteraction.CreateReadConnection(...)` calls `GetDBConStr(config, DBVisitType)` and then `GetConnection(...)`.
|
||||||
|
|
||||||
|
## Candidate table/model findings
|
||||||
|
|
||||||
|
The static IL gives enough table and model names to target schema-only DB extraction next.
|
||||||
|
|
||||||
|
### Message and conversation tables
|
||||||
|
|
||||||
|
- `tblMsgGroupPersonMsg` is the main group/discussion message table. Static SQL references include create/insert/update/select paths for:
|
||||||
|
- `Id`, `SndPerson`, `SndPersonId`, `MsgType`, `MsgText`, `MsgFont`, `MsgTime`;
|
||||||
|
- `MsgGroupId`, `MsgGroupName`, `SessionTitle`, `SessionPersonId`, `SessionPersonName`, `GroupType`;
|
||||||
|
- `MsgReadState`, `MsgRecaptionState`, `IsReceipt`, `MessageBody`, `InterOut`, `MsgContent`, `MsgVersion`, `MsgReadStatus`;
|
||||||
|
- later-added fields such as `ReadMembers`, `UnreadTotal`, and `MemInfoVersion`.
|
||||||
|
- `tblPersonMsg` is the main one-to-one message table. Static SQL/model fields include sender, receiver, object person, message text/body/content/version/read state, and receipt state fields.
|
||||||
|
- `tblRecent` likely stores recent conversation entries; model fields include `PersonId` and `PersonName`.
|
||||||
|
|
||||||
|
### Contact and display-name sources
|
||||||
|
|
||||||
|
- `TD_Roster` is explicitly queried with `JId`, `Nick`, `Ask`, `Subscription`, `Show`, `Status`, and `GroupName`.
|
||||||
|
- `tblChatLevel` has `PersonId` and `PersonName` fields.
|
||||||
|
- `tblRecent` has `PersonId` and `PersonName` fields.
|
||||||
|
- `CustomEffigyModel` includes `PersonJid`, `PersonName`, `PersonSex`, avatar/local path style fields.
|
||||||
|
|
||||||
|
### Group and member-display sources
|
||||||
|
|
||||||
|
- `tblMsgGroupPersonMsg` provides `MsgGroupId`, `MsgGroupName`, `SessionPersonId`, `SessionPersonName`, `GroupType`, and read/member summary fields.
|
||||||
|
- `TD_WorkGroupAuth` has create/update/select evidence and model `WorkGroupAuth` contains `GroupJID`, `GroupName`, `SendPersonJid`, `SendPersonName`, and `ChildGroupJid`.
|
||||||
|
- `GetDiscussMemberNames(groupJid)` queries distinct `SessionPersonId` from `tblMsgGroupPersonMsg` by `MsgGroupId`.
|
||||||
|
|
||||||
|
### File metadata candidates
|
||||||
|
|
||||||
|
- `tblRecvFile` and the receive/send file models expose `FileName`, file id/path-like fields, `SndPerson`, `SndPersonId`, and sender/receiver display-name fields.
|
||||||
|
- Group file-message insert/update paths write file-transfer references through `tblMsgGroupPersonMsg`.
|
||||||
|
|
||||||
|
## Decision
|
||||||
|
|
||||||
|
C25 recovered the wrapper route. The next safe path is no longer blind DB-format guessing.
|
||||||
|
|
||||||
|
High-confidence local hypothesis:
|
||||||
|
|
||||||
|
> A copied `MsgLib.db` should be attempted through the exact bundled `System.Data.SQLite.dll` path with a read-only connection string equivalent to `Data Source=<copied MsgLib.db>;Password=123;Read Only=True;Pooling=False` or the wrapper-generated equivalent.
|
||||||
|
|
||||||
|
C26 can attempt read-only schema extraction from copied DB files under ignored paths. C26 should only query schema/table/column names and row counts first; it must not dump message bodies, personal values, or write to any DB.
|
||||||
|
|
||||||
|
If the direct read-only `System.Data.SQLite` open fails, the next fallback is to record the exact exception and use the DAL/wrapper path as the reference for a wrapper-assisted schema-only probe.
|
||||||
|
|
||||||
|
## Next slice
|
||||||
|
|
||||||
|
Loop C26 should perform copied-DB read-only schema extraction:
|
||||||
|
|
||||||
|
1. Use the bundled `System.Data.SQLite.dll` from the extracted iSphere client files.
|
||||||
|
2. Open only copied DB files under `runs/offline-evidence-intake/.../extracted/msgdb-*`.
|
||||||
|
3. Use the recovered password `123` and force read-only mode.
|
||||||
|
4. Query `sqlite_master` and `PRAGMA table_info(...)` for target tables only.
|
||||||
|
5. Save schema metadata under ignored `runs/.../metadata/` and commit only docs/matrix/status updates.
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
# Capability Source Matrix
|
# Capability Source Matrix
|
||||||
|
|
||||||
Date: 2026-07-09
|
Date: 2026-07-10
|
||||||
Stage: C log-backed receive implementation
|
Stage: C log-backed receive implementation
|
||||||
Evidence index: `docs/source-discovery/2026-07-09-n12-pre-zyl-index.md`
|
Evidence index: `docs/source-discovery/2026-07-09-n12-pre-zyl-index.md`
|
||||||
Schema notes: `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md`
|
Schema notes: `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md`
|
||||||
@@ -17,9 +17,9 @@ Schema notes: `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md`
|
|||||||
|
|
||||||
| MCP tool | Primary source | Fallback source | Evidence file | Decision status | Next implementation slice |
|
| MCP tool | Primary source | Fallback source | Evidence file | Decision status | Next implementation slice |
|
||||||
| --- | --- | --- | --- | --- | --- |
|
| --- | --- | --- | --- | --- | --- |
|
||||||
| `isphere_receive_messages` | decrypted `PacketReader.ProcessPacket` XMPP `<message>` stanzas via `internal/isphere.EncryptedPacketLogSource`; configured by `ISPHERE_PACKET_LOG_FILE` or `ISPHERE_PACKET_LOG_DIR` | decrypted `Smark.SendReceive` transport stanzas; decrypted `SaveToDB` `Chat_OnMessageArrived` traces; wrapped `MsgLib.db` after DB wrapper is solved | `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md#field-mapping-evidence` | C20 supports and validates the current safe receive-message contract args; default source remains empty when unset | apply safe contract args to contact/group search |
|
| `isphere_receive_messages` | decrypted `PacketReader.ProcessPacket` XMPP `<message>` stanzas via `internal/isphere.EncryptedPacketLogSource`; configured by `ISPHERE_PACKET_LOG_FILE` or `ISPHERE_PACKET_LOG_DIR` | decrypted `Smark.SendReceive` transport stanzas; decrypted `SaveToDB` `Chat_OnMessageArrived` traces; copied `MsgLib.db` after C26 read-only schema/open validation | `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md#field-mapping-evidence`; `docs/source-discovery/2026-07-10-dotnet-wrapper-static-analysis.md` | C20 supports and validates the current safe receive-message contract args; C25 recovered the likely `MsgLib.db` wrapper password/connection flow but DB open is not validated yet | C26 copied-DB read-only schema extraction |
|
||||||
| `isphere_search_contacts` | bare sender/receiver JIDs extracted from normalized log-backed messages loaded from configured PacketReader file or directory source | decrypted roster/contact stanzas from `Smark.SendReceive`; `MsgLib.db` contact/conversation tables after DB wrapper is solved; UIA helper source if display names are missing | `docs/source-discovery/2026-07-10-msglib-readability-precheck.md` | C24 confirms `MsgLib.db` is not ordinary SQLite and likely needs client DB wrapper/static .NET analysis before display-name extraction | static wrapper analysis for table/model/password flow |
|
| `isphere_search_contacts` | bare sender/receiver JIDs extracted from normalized log-backed messages loaded from configured PacketReader file or directory source | `MsgLib.db` tables after C26 read-only validation: `TD_Roster`, `tblRecent`, `tblChatLevel`, `tblPersonMsg`; decrypted roster/contact stanzas from `Smark.SendReceive`; UIA helper source if display names are still missing | `docs/source-discovery/2026-07-10-dotnet-wrapper-static-analysis.md` | C25 recovered the static wrapper path and candidate contact/display-name tables; direct copied-DB read is still unvalidated | C26 copied-DB read-only schema extraction with recovered wrapper password |
|
||||||
| `isphere_search_groups` | decrypted `PacketReader.ProcessPacket` `type="groupchat"` stanzas and conference/MUC JIDs loaded from configured PacketReader file or directory source | `MsgLib.db` group/conversation tables after DB wrapper is solved; UIA helper source if group display names are missing | `docs/source-discovery/2026-07-10-msglib-readability-precheck.md`; C9 ignored-log scan: PacketReader 86 groupchat/86 conference hits; Smark 24 groupchat/658 conference/631 muc hits | C24 finds group table/model candidates in wrapper strings but no validated copied-DB read path yet; JID-only display fallback remains honest | static wrapper analysis for table/model/password flow |
|
| `isphere_search_groups` | decrypted `PacketReader.ProcessPacket` `type="groupchat"` stanzas and conference/MUC JIDs loaded from configured PacketReader file or directory source | `MsgLib.db` tables after C26 read-only validation: `tblMsgGroupPersonMsg`, `TD_WorkGroupAuth`, `tblRecent`; UIA helper source if group display names are still missing | `docs/source-discovery/2026-07-10-dotnet-wrapper-static-analysis.md`; C9 ignored-log scan: PacketReader 86 groupchat/86 conference hits; Smark 24 groupchat/658 conference/631 muc hits | C25 recovered the static wrapper path and candidate group/member display fields; direct copied-DB read is still unvalidated | C26 copied-DB read-only schema extraction with recovered wrapper password |
|
||||||
| `isphere_receive_files` | decrypted `PacketReader.ProcessPacket` file-transfer message stanzas via `internal/isphere.ListFilesFromMessages` and `isphere_receive_files` list mode; configured PacketReader file or directory source; `zyl\importal\<hash>` cache entries remain unlinked | decrypted `Smark.SendReceive` and `SaveToDB` traces for file-reference reconciliation; future UIA/client connector for download | `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md#c12-file-transfer-evidence-precheck` | C22 verifies safe file-list contract args; no log-to-cache/download mapping yet | defer download mapping; precheck contact/group display-name evidence |
|
| `isphere_receive_files` | decrypted `PacketReader.ProcessPacket` file-transfer message stanzas via `internal/isphere.ListFilesFromMessages` and `isphere_receive_files` list mode; configured PacketReader file or directory source; `zyl\importal\<hash>` cache entries remain unlinked | decrypted `Smark.SendReceive` and `SaveToDB` traces for file-reference reconciliation; future UIA/client connector for download | `docs/source-discovery/2026-07-09-n12-pre-zyl-schema-notes.md#c12-file-transfer-evidence-precheck` | C22 verifies safe file-list contract args; no log-to-cache/download mapping yet | defer download mapping; precheck contact/group display-name evidence |
|
||||||
| `isphere_send_message` | none validated yet | existing bridge/API/local service preferred; UIA write connector only after internal-sandbox action evidence; network/protocol connector only after protocol discovery | `docs/source-discovery/2026-07-10-send-message-source-precheck.md` | C15 blocked: contract exists, but no committed bridge/API/local service, helper write op, UIA action chain, or protocol connector is validated | do not implement write behavior; harden existing read source configuration |
|
| `isphere_send_message` | none validated yet | existing bridge/API/local service preferred; UIA write connector only after internal-sandbox action evidence; network/protocol connector only after protocol discovery | `docs/source-discovery/2026-07-10-send-message-source-precheck.md` | C15 blocked: contract exists, but no committed bridge/API/local service, helper write op, UIA action chain, or protocol connector is validated | do not implement write behavior; harden existing read source configuration |
|
||||||
| `isphere_send_file` | none validated yet | depends on send-message connector plus outbound file/upload evidence | `docs/source-discovery/2026-07-10-send-message-source-precheck.md` | blocked behind `isphere_send_message` connector selection and file upload/source policy | defer until send-message connector is validated |
|
| `isphere_send_file` | none validated yet | depends on send-message connector plus outbound file/upload evidence | `docs/source-discovery/2026-07-10-send-message-source-precheck.md` | blocked behind `isphere_send_message` connector selection and file upload/source policy | defer until send-message connector is validated |
|
||||||
@@ -39,4 +39,4 @@ Start Stage C with a narrow log-backed `isphere_receive_messages` source abstrac
|
|||||||
|
|
||||||
## Deferred source work
|
## Deferred source work
|
||||||
|
|
||||||
`MsgLib.db` is deferred because the selected DB files are not direct SQLite and did not decrypt to a SQLite header with the known log policy key. A separate DB-wrapper analysis node is required before using DB tables as a production read source.
|
`MsgLib.db` is no longer treated as ordinary SQLite. C25 recovered the likely wrapper route (`System.Data.SQLite` plus DB config password `123`), but C26 must still validate a copied read-only DB open and schema extraction before any DB-backed production read source is implemented.
|
||||||
|
|||||||
@@ -1972,12 +1972,12 @@ Evidence precheck result:
|
|||||||
|
|
||||||
**Goal:** Statically inspect the extracted DB wrapper assemblies to map candidate table/model names and connection-string/password/decryption flow for future read-only `MsgLib.db` access.
|
**Goal:** Statically inspect the extracted DB wrapper assemblies to map candidate table/model names and connection-string/password/decryption flow for future read-only `MsgLib.db` access.
|
||||||
|
|
||||||
**Planned files:**
|
**Files:**
|
||||||
- Modify: `docs/source-discovery/capability-source-matrix.md`
|
- Modify: `docs/source-discovery/capability-source-matrix.md`
|
||||||
- Modify: `docs/current-status-card.md`
|
- Modify: `docs/current-status-card.md`
|
||||||
- Modify: `docs/superpowers/plans/2026-07-09-stage-c-log-backed-receive-messages-loop.md`
|
- Modify: `docs/superpowers/plans/2026-07-09-stage-c-log-backed-receive-messages-loop.md`
|
||||||
- Optionally create a focused source-discovery note under `docs/source-discovery/`.
|
- Create: `docs/source-discovery/2026-07-10-dotnet-wrapper-static-analysis.md`
|
||||||
- Optionally create ignored metadata under `runs/`; do not commit binaries, raw DB bytes, decrypted content, or personal values.
|
- Ignored metadata under `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/`; no binaries, raw DB bytes, decrypted content, or personal values are committed.
|
||||||
|
|
||||||
**Planned behavior:**
|
**Planned behavior:**
|
||||||
- Inspect .NET assembly metadata/IL read-only for:
|
- Inspect .NET assembly metadata/IL read-only for:
|
||||||
@@ -1986,20 +1986,26 @@ Evidence precheck result:
|
|||||||
- `Utilities.Lib.DBModel.dll`
|
- `Utilities.Lib.DBModel.dll`
|
||||||
- `Utilities.Lib.DBSQLite.dll`
|
- `Utilities.Lib.DBSQLite.dll`
|
||||||
- `RepairDatabase.exe`
|
- `RepairDatabase.exe`
|
||||||
|
- Include direct dependency IL only when needed to resolve model fields and connection flow.
|
||||||
- Extract only table/model/method/property names and connection/decryption flow summaries.
|
- Extract only table/model/method/property names and connection/decryption flow summaries.
|
||||||
- Decide whether C26 can attempt copied-DB read-only schema extraction or must stay blocked.
|
- Decide whether C26 can attempt copied-DB read-only schema extraction or must stay blocked.
|
||||||
- Do not execute client binaries or modify DB files.
|
- Do not execute client binaries or modify DB files.
|
||||||
- Do not add write/send/file-download behavior.
|
- Do not add write/send/file-download behavior.
|
||||||
|
|
||||||
- [ ] **Step 1: Generate static wrapper metadata**
|
- [x] **Step 1: Generate static wrapper metadata**
|
||||||
|
|
||||||
Use read-only metadata/IL tools or string extraction. Keep output under ignored metadata.
|
Generated IL and structured ignored metadata with `ildasm`/Python under:
|
||||||
|
|
||||||
- [ ] **Step 2: Write source-discovery conclusion**
|
```text
|
||||||
|
runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-il/
|
||||||
|
runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/c25-wrapper-il-summary.json
|
||||||
|
```
|
||||||
|
|
||||||
Record likely tables/models and the safest next read path.
|
- [x] **Step 2: Write source-discovery conclusion**
|
||||||
|
|
||||||
- [ ] **Step 3: Verify and commit docs**
|
Created `docs/source-discovery/2026-07-10-dotnet-wrapper-static-analysis.md` with recovered connection/password flow and target table/model mapping.
|
||||||
|
|
||||||
|
- [x] **Step 3: Verify and commit docs**
|
||||||
|
|
||||||
Run:
|
Run:
|
||||||
|
|
||||||
@@ -2013,6 +2019,68 @@ Expected: all exit 0. Commit exact C25 paths only and rewrite the next loop from
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
## Loop C25 Result
|
||||||
|
|
||||||
|
Static wrapper analysis result:
|
||||||
|
|
||||||
|
- `HYHC.IMPP.DAL.IMPPDAL` configures the DB through `Utilities.Lib.DBModel.Config.DBConfigElement` with `DBID = 0x1a0a`, `DBConInfoType = 1`, `DatabaseName = dbPath`, `Password = "123"`, and `DBFactory = "Utilities.Lib.DBSQLite.Core.SQLiteDBFactory,Utilities.Lib.DBSQLite"`.
|
||||||
|
- `Utilities.Lib.DBBase.Base.DBInteractionBase.GetDBConStr(...)` chooses between direct `ConStr`, generated connection string, or an `IConStrDecryption` implementation. The observed DAL path uses generated SQLite connection strings rather than the earlier log DES policy.
|
||||||
|
- `Utilities.Lib.SQLiteInteraction.Interaction.GenerateDBConStr(...)` builds a `System.Data.SQLite.SQLiteConnectionStringBuilder`, sets `DataSource`, sets `Password` when present, forces `ReadOnly = true`, and returns the connection string. `GetConnection(...)` then creates `System.Data.SQLite.SQLiteConnection`.
|
||||||
|
- Candidate schema sources are now mapped:
|
||||||
|
- contact/display names: `TD_Roster`, `tblRecent`, `tblChatLevel`, `tblPersonMsg`;
|
||||||
|
- group/display/member names: `tblMsgGroupPersonMsg`, `TD_WorkGroupAuth`, `tblRecent`;
|
||||||
|
- receive messages: `tblPersonMsg`, `tblMsgGroupPersonMsg`;
|
||||||
|
- file metadata: `tblRecvFile` and file-message rows in message tables.
|
||||||
|
- Decision: C26 can attempt copied-DB read-only schema extraction using the bundled `System.Data.SQLite.dll` and the recovered wrapper password. It must query schema/counts only before any DB-backed feature implementation.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Loop C26: Copied `MsgLib.db` read-only schema extraction
|
||||||
|
|
||||||
|
**Goal:** Validate whether copied `MsgLib.db` files can be opened read-only through the recovered wrapper connection flow, then extract schema/table/column metadata only.
|
||||||
|
|
||||||
|
**Planned files:**
|
||||||
|
- Modify: `docs/source-discovery/capability-source-matrix.md`
|
||||||
|
- Modify: `docs/current-status-card.md`
|
||||||
|
- Modify: `docs/superpowers/plans/2026-07-09-stage-c-log-backed-receive-messages-loop.md`
|
||||||
|
- Create: `docs/source-discovery/2026-07-10-msglib-readonly-schema-extraction.md` if the probe yields non-trivial evidence.
|
||||||
|
- Ignored metadata under `runs/offline-evidence-intake/zyl-qqfile-20260709/metadata/`; do not commit DBs, raw rows, message bodies, personal values, or helper binaries.
|
||||||
|
|
||||||
|
**Planned behavior:**
|
||||||
|
- Use copied DB candidates under `runs/offline-evidence-intake/zyl-qqfile-20260709/extracted/msgdb-*` only.
|
||||||
|
- Use the bundled `System.Data.SQLite.dll` from the extracted iSphere client files.
|
||||||
|
- Open with the recovered wrapper path equivalent: `Data Source=<copy>;Password=123;Read Only=True;Pooling=False`.
|
||||||
|
- Query only `sqlite_master`, `PRAGMA table_info(...)`, and safe row counts for target tables.
|
||||||
|
- Save schema metadata under ignored `runs/.../metadata/`.
|
||||||
|
- If direct bundled `System.Data.SQLite` open fails, record the exact exception and plan the next wrapper-assisted schema probe.
|
||||||
|
- Do not add write/send/file-download behavior.
|
||||||
|
|
||||||
|
- [ ] **Step 1: Build a read-only schema probe**
|
||||||
|
|
||||||
|
Create a temporary/ignored probe that references the bundled SQLite assembly and opens copied DB files read-only with password `123`.
|
||||||
|
|
||||||
|
- [ ] **Step 2: Extract schema-only metadata**
|
||||||
|
|
||||||
|
Collect table names, column names/types, and safe row counts for candidate business tables. Do not dump message/contact/file rows.
|
||||||
|
|
||||||
|
- [ ] **Step 3: Record conclusion and next implementation slice**
|
||||||
|
|
||||||
|
If schema open succeeds, write C27 as DB-backed contact/group display-name enrichment or DB-backed receive-message source design. If schema open fails, write C27 as wrapper-assisted open diagnosis.
|
||||||
|
|
||||||
|
- [ ] **Step 4: Verify and commit docs**
|
||||||
|
|
||||||
|
Run:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
git diff --check
|
||||||
|
go test ./...
|
||||||
|
powershell -NoProfile -ExecutionPolicy Bypass -File scripts/verify-go-mcp.ps1
|
||||||
|
```
|
||||||
|
|
||||||
|
Expected: all exit 0. Commit exact C26 docs only and rewrite the next loop from actual results.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## Self-Review
|
## Self-Review
|
||||||
|
|
||||||
- Spec coverage: the plan follows the user's cyclic requirement: plan first, implement one loop at a time, update the next loop after each result, and ask only on blockers.
|
- Spec coverage: the plan follows the user's cyclic requirement: plan first, implement one loop at a time, update the next loop after each result, and ask only on blockers.
|
||||||
|
|||||||
Reference in New Issue
Block a user