Commit Graph

11 Commits

Author SHA1 Message Date
Mario Fetka
3740e1450c ncpapi: rename c32ncp files to NCP API names
Finish the c32ncp.c/c32ncp.h to ncpapi.c/ncpapi.h rename.

Update the build files, include directives, dependency tracking, header guard,
README references and file-level comments to use the new ncpapi naming. This
matches the current split where ncpapi contains the ncpXX_YY_* protocol API
wrappers and ncpcall contains the lower-level requester/transport helpers.

No behavior change.
2026-05-29 11:48:03 +02:00
Mario Fetka
d7f2a6551f ncpcalls: rename probe helpers as requester calls
Rename the remaining Client32 transport helper symbols from Probe-style names
to request-style names.

These helpers are no longer only diagnostic probes; they are the low-level
requester paths used by the NCP API wrappers. Rename the raw5 helper to the
more general ncp_raw_request() name and update the MapVar/OpenRef helpers to
ncp_mapvar_request() and ncp_openref_request().

No behavior change.
2026-05-29 11:40:32 +02:00
Mario Fetka
40e7ebf939 ncpcalls: rename remaining C32 transport symbols
Rename the remaining C32-prefixed transport helpers, probe helpers, types and
constants to protocol-oriented NCP names.

This removes implementation-oriented c32/C32 naming from the shared NCP API and
transport layer while keeping the current c32ncp.c/c32ncp.h file names until
the later ncpapi.c/ncpapi.h rename. The new names avoid conflicts by using
ncp_* helper names and NCP_* type/constant prefixes.

No behavior change.
2026-05-29 11:32:09 +02:00
Mario Fetka
4a952b4c4c dosutils: align Novell-compatible tests and stage NCOPY work
Update the DOS utilities and test suite with the current Novell comparison
state.

Validated/updated tool behavior:
- improve CREATOR output by showing Novell-style attribute and rights masks
- extend FLAGDIR handling with old NCP22 directory attribute read/write
  fallback paths
- expand NDIR Novell-style formatting, filtering, /SUB handling, date output,
  DI/RI attribute display and richer metadata collection
- adjust REVOKE output/grammar, recursive /SUBDIRECTORIES behavior and trustee
  update/delete paths to better match Novell tools
- adjust SLIST header/output behavior for logged-in and logged-out cases
- update README status to reflect the currently green/tested tools

Test-suite changes:
- add/refresh Novell comparison tests for CREATOR, NDIR, REVOKE and SLIST
- update NCOPY tests and collection scripts for the current investigation state
- refresh per-tool README files and top-level test documentation
- keep MAP documented as still separately open

NCOPY:
- add the current NCOPY implementation and experimental NCP74/server-side-copy
  scaffolding
- build ncopy.c so it stays compile-tested
- keep NCOPY disabled in the NET multicall dispatch for now because the
  server-side-copy/open-handle path is still unsafe and needs further analysis

Build:
- include ncopy.c in the DOS utility build
- drop the temporary MARS_DOSUTILS_VERSION define wiring from CMake
2026-05-29 07:40:04 +02:00
Mario Fetka
0df41482c7 dosutils: add creator and supporting NCP helpers
Add the CREATOR utility and wire it into the DOS tools build and NET
command dispatch.

Extend the client-side NCP helpers with the calls needed by the new and
updated tools, including DOS namespace information and effective-rights
queries. Also update MAP handling for automatic drive mappings used by
the login script.

This commit contains the tool/source support only. The DOS baseline test
suite is kept separate and will be added in a follow-up commit.
2026-05-27 13:31:02 +02:00
Mario Fetka
6d2d3f367f dosutils: use NCP87 DOS info fields in NDIR
Add a Client32 NCP87 helper for obtaining DOS namespace file and
subdirectory information and use it in NDIR.

The new helper reads the classic NCP87 subfunction 6 RIM_ALL DOS info
block, including timestamps, inherited rights, directory identifiers and
size metadata.

Use the NCP87 inherited rights mask for the inherited-rights column while
keeping the existing Client32 effective-rights path for the effective
rights column.  Also use the NCP87 modify, archive, last-access and
creation date fields for the /DATES display, falling back to DOS
findfirst timestamps when the NCP87 info request is not available.

Tighten the /DATES layout so the full Created/Copied timestamp remains
within an 80-column DOS screen.
2026-05-25 09:17:56 +02:00
Mario Fetka
7117bfff68 dosutils: add Novell-style NDIR listing tool
Add an initial Novell-style NDIR implementation for the DOS utilities.

The new tool supports basic DOS namespace directory listings using
_dos_findfirst/_dos_findnext, including wildcard paths, current-directory
listing, files-only and directories-only modes, recursive /SUB listings,
continuous output and Novell-style help text.

NDIR separates file and directory output into Novell-like sections,
prints long NetWare-style attribute brackets, and reports both file bytes
and allocated bytes in blocks using a simple per-file 4 KiB block
approximation for the initial implementation.

Add initial /RIGHTS support.  The rights format displays rights columns
for files and directories, obtains effective rights through Client32
NCP87, and falls back to the older directory-handle effective-rights path
when needed.  For now the inherited-rights column uses the effective
rights value until a separate inherited-rights mask is available.

Add initial /DATES support with a Novell-style date column layout showing
Last Updated, Last Archived, Accessed and Created/Copied fields.  The
initial implementation uses the DOS findfirst update timestamp for the
available date values and placeholder archive/access values until full
NetWare namespace date fields are exposed.

Add /SHORT and /BRIEF as compact output modes for recursive listings and
manual testing.  These modes keep the useful values while suppressing the
large Novell-style section headers and empty recursive sections.

Wire NDIR into the multicall dispatcher, CMake build and install list,
and document the supported command forms in the README.

Owner display, true inherited-right masks, full namespace date fields,
sorting and restrictions remain future work.
2026-05-25 08:49:47 +02:00
Mario Fetka
c50202e93b dosutils: factor shared helpers and update README
Move common DOS utility helper code into tools.c and expose it through
net.h.  This removes duplicated command-local helpers from GRANT,
RIGHTS, FLAG, FLAGDIR and the trustee helper layer.

The shared helpers cover case-insensitive argument comparison, help and
option detection, /FILES and /SUBDIRS parsing, current network directory
handle lookup, current volume prefix formatting, uppercase DOS path
copying, basename/header-path handling, wildcard detection and simple
path joining/splitting.

Keep the command frontends smaller and less coupled so the current
multicall utility can later be split into smaller grouped multicall
binaries, such as trustee tools, login/session tools and file/flag
tools.

Update the DOS utilities README for the newer Client32 and trustee
commands.  Document RIGHTS, GRANT, REVOKE and REMOVE in the status,
feature, command and install sections.  Add command reference entries
for the trustee tools, including Novell-style syntax, supported rights,
recursive/file options and missing-trustee behavior.

Also mention the shared trustee helper layer and common tools.c helpers
used by the newer command frontends.
2026-05-24 20:45:56 +02:00
Mario Fetka
9ab65e2f00 dosutils: add RIGHTS and finish Novell-style display fixes
- add RIGHTS as a new multi-call DOS utility
- implement Client32 NCP87 effective-rights query helper
- map NCP effective-rights bits to Novell RIGHTS display order
- keep legacy directory-handle based rights lookup as fallback
- match Novell RIGHTS output for directories and files more closely
- remove hardcoded MARS/SYS and SYS display fallbacks from RIGHTS/FLAGDIR
- derive display prefixes from the active network drive where available
- adjust FLAGDIR output formatting to match Novell field alignment
- keep FLAG and SLIST unchanged after checking for hardcoded prefixes
2026-05-24 11:20:07 +02:00
Mario Fetka
f62ca19c50 Add Readme 2026-05-24 02:13:02 +02:00
Mario Fetka
b16fc3a64b docs: reorganize project files and README 2026-05-24 00:30:15 +02:00