docs: audit NDS fragger stubs
This commit is contained in:
40
AI.md
40
AI.md
@@ -11,18 +11,18 @@ When the user says this is a new chat or asks to continue mars-nwe work, first
|
||||
read this file before proposing patches or making assumptions. Then ask for, or
|
||||
use, the current project status that the user pasted into the chat.
|
||||
|
||||
## Current handoff status after patch 0216
|
||||
## Current handoff status after patch 0217
|
||||
|
||||
The current accepted patch line in this chat is expected to include:
|
||||
|
||||
- endpoint-audit/documentation patches through `0176-docs-audit-direct-lifecycle-buffer-endpoints.patch`;
|
||||
- redesign documentation patches `0177` through `0198`;
|
||||
- endpoint-audit/documentation patches `0199` through `0216`;
|
||||
- latest expected patch name: `0216-docs-audit-packet-burst-endpoints.patch`.
|
||||
- endpoint-audit/documentation patches `0199` through `0217`;
|
||||
- latest expected patch name: `0217-docs-audit-nds-fragger-stubs.patch`.
|
||||
|
||||
When continuing in a new chat, first ask the user which patch was actually last
|
||||
applied. If they confirm `0216`, build the next patch as `0217-...` against a
|
||||
tree that already contains `0216`. If any patch failed or was skipped, rebuild
|
||||
applied. If they confirm `0217`, build the next patch as `0218-...` against a
|
||||
tree that already contains `0217`. If any patch failed or was skipped, rebuild
|
||||
against the last confirmed applied patch instead of assuming the file in
|
||||
`/mnt/data` was accepted.
|
||||
|
||||
@@ -198,20 +198,24 @@ Schema/import direction:
|
||||
|
||||
Latest endpoint audit note:
|
||||
|
||||
- Patch `0216` audits Packet Burst / Big Packet support in `src/nwconn.c`: SDK
|
||||
`97` / wire `0x61` Get Big Packet NCP Max Packet Size, SDK `101` / wire
|
||||
`0x65` Packet Burst Connection Request, and the follow-on `0x7777`
|
||||
packet-burst data-plane handler. `97` and `101` are 4.x-era direct NCPs and
|
||||
are present in source, so no missing stubs were needed. The audit documents
|
||||
request/reply layouts, burst-mode disabled behavior (`0xfb`), and the current
|
||||
lack of NDK security-flag negotiation for checksums/signatures/encryption.
|
||||
The `0x7777` handler is not a normal `0x2222` endpoint; it is the runtime
|
||||
data path created by `101`.
|
||||
- Patch `0217` audits the planned NetWare-4.x NDS/NCP Fragger family
|
||||
`0x2222/104` / wire `0x68` in `src/nwconn.c`. The top-level source case was
|
||||
already present and still returns `0xfb` at runtime. Patch `0217` adds
|
||||
disabled `MARS_NWE_4` source-stub selector documentation for `104/01` Ping for
|
||||
NDS NCP, `104/02` Send NDS Fragmented Request/Reply, `104/03` Fragment Close,
|
||||
`104/04` Return Bindery Context, `104/05` Monitor NDS Connection, `104/06`
|
||||
Return NDS Statistics, `104/07` Clear Statistics, and `104/08` Reload NDS
|
||||
Software.
|
||||
- Remember that `104/02` is a nested-selector path: the NDS `Verb` is a 32-bit
|
||||
payload field after the NDS subfunction, so future docs should write paths
|
||||
like `0x2222/104/02 verb=<n>` instead of inventing one-byte `zz` cases.
|
||||
Future implementation belongs to `nwnds`/`libdirectory`; `nwserv` remains
|
||||
control plane only.
|
||||
|
||||
The next patch number should be `0217` if `0216` was applied. Likely next
|
||||
blocks are the planned-4.x NDS/NCP fragger `0x2222/104` path, deeper
|
||||
`0x2222/23` bindery/property/admin subfunction coverage, SDK `0x2222/90`
|
||||
generation-scope work, or another user-selected endpoint family.
|
||||
The next patch number should be `0218` if `0217` was applied. Likely next
|
||||
blocks are deeper `0x2222/23` bindery/property/admin subfunction coverage,
|
||||
SDK `0x2222/36`/`37` NCP Extension scope, SDK `0x2222/17` Print/Spool, or
|
||||
another user-selected endpoint family.
|
||||
|
||||
## Patch workflow
|
||||
|
||||
|
||||
35
TODO.md
35
TODO.md
@@ -202,8 +202,10 @@ Present in the code but not yet fully endpoint-audited:
|
||||
`src/nwconn.c` and endpoint-audited as the 4.x-era packet-burst negotiation
|
||||
and setup paths. The follow-on `0x7777` packet-burst data-plane handler is
|
||||
also documented, but it is not a normal `0x2222` endpoint.
|
||||
- SDK `0x2222/104` / wire `0x68` NDS/NCP fragger has a top-level code entry and
|
||||
still needs its own planned-4.x audit before any new stubs are added.
|
||||
- SDK `0x2222/104` / wire `0x68` NDS/NCP fragger is endpoint-audited as
|
||||
planned NetWare-4.x/NDS work. The top-level source case remains active as
|
||||
unsupported (`0xfb`), while the documented 104/01..104/08 selector slots are
|
||||
recorded behind `#if MARS_NWE_4` in `src/nwconn.c`.
|
||||
|
||||
SDK-listed blocks that do not currently show a top-level handler in
|
||||
`src/nwconn.c`:
|
||||
@@ -1197,6 +1199,35 @@ Follow-up:
|
||||
rather than `nwnds`.
|
||||
|
||||
|
||||
### NDS/NCP Fragger group 0x2222/104
|
||||
|
||||
Current status:
|
||||
|
||||
- `NCP 0x2222/104` / wire `0x68` is planned NetWare-4.x/NDS work, not a
|
||||
default NetWare-3.x server feature. `src/nwconn.c` already had a top-level
|
||||
`case 0x68` that returns `0xfb`; patch 0217 keeps that runtime behavior and
|
||||
adds disabled `MARS_NWE_4` source-stub selectors for the documented NDS
|
||||
subfunctions.
|
||||
- The documented selector slots are `104/01` Ping for NDS NCP, `104/02` Send
|
||||
NDS Fragmented Request/Reply, `104/03` Fragment Close, `104/04` Return
|
||||
Bindery Context, `104/05` Monitor NDS Connection, `104/06` Return NDS
|
||||
Statistics, `104/07` Clear Statistics, and `104/08` Reload NDS Software.
|
||||
- `104/02` is a nested-selector endpoint: after the NDS SubFunctionCode it
|
||||
carries a 32-bit NDS `Verb` payload field. Document selector paths as
|
||||
`0x2222/104/02 verb=<Verb>` when future nwnds work reaches this block; do
|
||||
not flatten the verb into a one-byte NCP case.
|
||||
- Future implementation belongs to `nwnds` and `libdirectory`, with `nwserv`
|
||||
used only for control-plane actions such as reload/supervision. Normal NDS
|
||||
request payloads must not be routed through `nwserv` as a data-plane broker.
|
||||
|
||||
Follow-up:
|
||||
|
||||
- Keep the `MARS_NWE_4` stubs disabled until a real `nwnds`/fragment-state
|
||||
design exists. The next endpoint audit can continue with deeper `23`
|
||||
bindery/property/admin coverage, `36`/`37` NCP Extension scope, print/spool
|
||||
`17`, or another user-selected family.
|
||||
|
||||
|
||||
### Retrospective source-stub coverage for already audited blocks
|
||||
|
||||
Current status:
|
||||
|
||||
100
src/nwconn.c
100
src/nwconn.c
@@ -6916,11 +6916,109 @@ static int handle_ncp_serv(void)
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x68 : /* NDS NCP, NDS Fragger Protokoll ?? */
|
||||
case 0x68 : { /* NDS NCP / NDS Fragger protocol. */
|
||||
#if MARS_NWE_4
|
||||
/*
|
||||
* NCP 0x2222/104 NDS / NCP Fragger.
|
||||
*
|
||||
* Source outcome: top-level wire case 0x68 exists, but MARS-NWE
|
||||
* does not implement NetWare 4.x NDS fragmentation or the
|
||||
* NDS service verbs yet. Keep the planned-4.x selector slots
|
||||
* disabled behind MARS_NWE_4 until nwnds/libdirectory exists.
|
||||
*
|
||||
* Request handoff: direct NCP 104 requests put the NDS
|
||||
* SubFunctionCode at requestdata[0]. Subfunction 104/02 then
|
||||
* contains an additional 32-bit NDS Verb payload selector; do
|
||||
* not treat that verb as a normal one-byte NCP dispatch case.
|
||||
*
|
||||
* Reply ownership: this local handler would return a normal
|
||||
* NCP Completion plus optional payload. The current active
|
||||
* behavior intentionally remains 0xfb for the whole family.
|
||||
*/
|
||||
int nds_sub = (requestlen > (int)sizeof(NCPREQUEST))
|
||||
? (int)requestdata[0] : -1;
|
||||
|
||||
switch (nds_sub) {
|
||||
case 0x01: /* Ping for NDS NCP
|
||||
* Request: byte SubFunctionCode=1, byte Reserved[3].
|
||||
* Reply: long PingVersion (Lo-Hi), unicode TreeName,
|
||||
* long RootMostEntryDepth (Lo-Hi).
|
||||
* Future owner: nwnds.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x02: /* Send NDS Fragmented Request/Reply
|
||||
* Request: byte SubFunctionCode=2, then long fields
|
||||
* FraggerHandle, FragSize, TotalRequest, Flags,
|
||||
* Verb, ReplyBufferSize, followed by RequestData.
|
||||
* Selector path: 0x2222/104/02 verb=<Verb>.
|
||||
* Reply: long ReplySize, long FraggerHandle, ReplyData[].
|
||||
* Future owner: nwnds with normalized fragment state.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x03: /* Fragment Close
|
||||
* Request: byte SubFunctionCode=3, long FraggerHandle.
|
||||
* Reply: no payload, normal Completion.
|
||||
* Future owner: nwnds fragment-state cleanup.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x04: /* Return Bindery Context
|
||||
* Request: byte SubFunctionCode=4.
|
||||
* Reply: long length, unicode binderyContext.
|
||||
* Future owner: nwnds/libdirectory bindery-context
|
||||
* compatibility, not legacy flat bindery files.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x05: /* Monitor NDS Connection
|
||||
* Request: byte SubFunctionCode=5.
|
||||
* Reply: no documented payload in the local NDK table.
|
||||
* Future owner: nwnds connection/session monitor.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x06: /* Return NDS Statistics
|
||||
* Request: byte SubFunctionCode=6, Int4 RequestFlags.
|
||||
* Reply: variable Int4 statistics selected by flags.
|
||||
* Future owner: nwnds statistics provider.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x07: /* Clear Statistics
|
||||
* Request: byte SubFunctionCode=7.
|
||||
* Reply: no payload, normal Completion.
|
||||
* Future owner: nwnds statistics provider.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
case 0x08: /* Reload NDS Software
|
||||
* Request: byte SubFunctionCode=8.
|
||||
* Reply: status-oriented NDS software reload result.
|
||||
* Future owner: nwserv control plane plus nwnds, never
|
||||
* a direct payload route through nwserv.
|
||||
*/
|
||||
completition = 0xfb;
|
||||
break;
|
||||
|
||||
default: completition = 0xfb;
|
||||
break;
|
||||
}
|
||||
#else
|
||||
XDPRINTF((2,0, "INFO NDS 104 UNKNOWN reason=fragger_unsupported fn=0x68 result=0xfb"));
|
||||
nw_debug=0;
|
||||
completition = 0xfb; /* unknown request */
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
|
||||
default : completition = 0xfb; /* unknown request */
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user