docs: audit namespace salvage metadata endpoints
This commit is contained in:
146
src/namspace.c
146
src/namspace.c
@@ -3313,7 +3313,17 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x10 : /* 87/16 Scan Salvageable Files */
|
||||
case 0x10 : /* SDK 87/16 Scan Salvageable Files.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace, reserved,
|
||||
* SearchAttributes, ReturnInfoMask, ScanSequence,
|
||||
* NWHandlePathStruct and path components.
|
||||
* Reply: NextScanSequence, deleted time/date, deletor ID,
|
||||
* volume/base IDs, then namespace information selected by
|
||||
* ReturnInfoMask. Current code uses MARS-NWE salvage
|
||||
* sidecar metadata and validates the path structure before
|
||||
* scanning.
|
||||
*/
|
||||
{
|
||||
uint8 *q = p - 1;
|
||||
int req_namespace;
|
||||
@@ -3399,7 +3409,15 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x11 : /* 87/17 Recover Salvageable File */
|
||||
case 0x11 : /* SDK 87/17 Recover Salvageable File.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace, reserved, ScanSequence,
|
||||
* VolumeNumber, DirectoryBase, and a new filename.
|
||||
* Reply: no payload, normal Completion response.
|
||||
* Difference: current code recovers using the trusted
|
||||
* salvage sidecar's original name instead of the supplied
|
||||
* new filename.
|
||||
*/
|
||||
{
|
||||
uint8 *q = p - 1;
|
||||
int req_namespace;
|
||||
@@ -3461,7 +3479,14 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x12 : /* 87/18 Purge Salvageable File */
|
||||
case 0x12 : /* SDK 87/18 Purge Salvageable File.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace, reserved, ScanSequence,
|
||||
* VolumeNumber, and DirectoryBase.
|
||||
* Reply: no payload, normal Completion response.
|
||||
* Current code purges the matching MARS-NWE salvage sidecar
|
||||
* entry from the target directory base.
|
||||
*/
|
||||
{
|
||||
uint8 *q = p - 1;
|
||||
int req_namespace;
|
||||
@@ -3511,7 +3536,31 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x14 : /* Search for File or Subdir Set */
|
||||
#if 0
|
||||
case 0x13 : /* SDK 87/19 Get NS Information.
|
||||
* Missing source slot for a 3.x/4.x namespace metadata
|
||||
* endpoint.
|
||||
* Request: SubFunction, SrcNameSpace, DstNameSpace,
|
||||
* VolumeNumber, DirectoryBase and NSInfoBitMask.
|
||||
* Reply: namespace-specific information selected by
|
||||
* NSInfoBitMask.
|
||||
* Future owner: filesystem/namespace provider.
|
||||
*/
|
||||
break;
|
||||
#endif
|
||||
|
||||
case 0x14 : /* SDK 87/20 Search for File or Subdirectory Set.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace, DataStream/reserved,
|
||||
* SearchAttributes, ReturnInfoMask, requested Count,
|
||||
* Volume, BaseHandle, SearchSequence, SearchPatternLen,
|
||||
* SearchPattern.
|
||||
* Reply: Volume, BaseHandle, NextSearchSequence,
|
||||
* MoreEntriesFlag, Count, then Count namespace information
|
||||
* structures.
|
||||
* Difference: current helper uses the same namespace as
|
||||
* DataStream and delegates to nw_search_file_dir().
|
||||
*/
|
||||
/* SIMPLE IMPLEMENTATION, needs more work !!!! */
|
||||
{
|
||||
struct OUTPUT {
|
||||
@@ -3550,7 +3599,13 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x15 : /* Get Path String from short dir new */
|
||||
case 0x15 : /* SDK 87/21 Get Path String from Short Directory Handle.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace, ShortDirectoryHandle.
|
||||
* Reply: PathLen followed by path bytes.
|
||||
* Current code maps the short handle through
|
||||
* nw_get_directory_path().
|
||||
*/
|
||||
{
|
||||
int dir_handle=(int) *(p+1);
|
||||
result=nw_get_directory_path(dir_handle, responsedata+1, 256);
|
||||
@@ -3561,7 +3616,14 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x16 : /* Generate Dir BASE and VolNumber */
|
||||
case 0x16 : /* SDK 87/22 Generate Directory Base and Volume Number.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace, DstNameSpace/dstNSIndicator,
|
||||
* reserved/flags, then NWHandlePathStruct.
|
||||
* Reply: namespace directory base, DOS directory base, and
|
||||
* VolumeNumber.
|
||||
* Current code delegates to nw_generate_dir_path().
|
||||
*/
|
||||
{
|
||||
NW_HPATH *nwpathstruct = (NW_HPATH *) (p+4);
|
||||
struct OUTPUT {
|
||||
@@ -3578,7 +3640,26 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x18 : /* Get Name Spaces Loaded */
|
||||
#if 0
|
||||
case 0x17 : /* SDK 87/23 Query NS Information Format.
|
||||
* Missing source slot for a 3.x/4.x namespace metadata
|
||||
* endpoint.
|
||||
* Request: SubFunction, SrcNameSpace, DstNameSpace,
|
||||
* VolumeNumber and NSInfoBitMask.
|
||||
* Reply: format description for the selected namespace
|
||||
* information bits.
|
||||
* Future owner: filesystem/namespace provider.
|
||||
*/
|
||||
break;
|
||||
#endif
|
||||
|
||||
case 0x18 : /* SDK 87/24 Get Name Spaces Loaded List from Volume Number.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, NameSpace/reserved, VolumeNumber.
|
||||
* Reply: CountOfNameSpaces (Lo-Hi) and NameSpaceList.
|
||||
* Current code reports configured DOS/OS2/NFS namespace
|
||||
* support for the target volume.
|
||||
*/
|
||||
{
|
||||
int volume=*(p+2);
|
||||
struct OUTPUT {
|
||||
@@ -3603,13 +3684,52 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x1a : /* Get Huge NS Info new*/
|
||||
#if 0
|
||||
case 0x19 : /* SDK 87/25 Set NS Information.
|
||||
* Missing source slot for a 3.x/4.x namespace metadata
|
||||
* endpoint.
|
||||
* Request: SubFunction, SrcNameSpace, DstNameSpace,
|
||||
* VolumeNumber, DirectoryBase, NSInfoBitMask and
|
||||
* namespace-specific information.
|
||||
* Reply: no payload, normal Completion response.
|
||||
* Future owner: filesystem/namespace provider.
|
||||
*/
|
||||
break;
|
||||
#endif
|
||||
|
||||
case 0x1a : /* SDK 87/26 Get Huge NS Information.
|
||||
* Coverage: source slot present but not implemented.
|
||||
* Request: SubFunction, SrcNameSpace, DstNameSpace,
|
||||
* VolumeNumber, DirectoryBase, NSInfoBitMask and HugeState.
|
||||
* Reply: huge namespace information selected by bit mask.
|
||||
* Current code falls through with the default 0xfb result.
|
||||
*/
|
||||
{
|
||||
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x1c : /* GetFullPathString new*/
|
||||
#if 0
|
||||
case 0x1b : /* SDK 87/27 Get Name Space Directory Entry.
|
||||
* Missing source slot for a 3.x/4.x namespace metadata
|
||||
* endpoint.
|
||||
* Request: SubFunction, NameSpace, VolumeNumber,
|
||||
* DirectoryBase and NSInfoBitMask.
|
||||
* Reply: namespace directory-entry information selected
|
||||
* by NSInfoBitMask.
|
||||
* Future owner: filesystem/namespace provider.
|
||||
*/
|
||||
break;
|
||||
#endif
|
||||
|
||||
case 0x1c : /* SDK 87/28 Get Full Path String.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, SrcNameSpace, DstNameSpace,
|
||||
* CookieFlags, Cookie1, Cookie2, then NWHandlePathStruct.
|
||||
* Reply: updated cookies, path size, component count and
|
||||
* component path data.
|
||||
* Current code delegates to nw_get_full_path_cookies().
|
||||
*/
|
||||
{ /* nw32 client needs it */
|
||||
/* SIMPLE IMPLEMENTATION, needs more work !!!! */
|
||||
int destnamspace = (int)*(p+1);
|
||||
@@ -3640,7 +3760,13 @@ static int code = 0;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x1d : /* GetEffDirRights new */
|
||||
case 0x1d : /* SDK 87/29 Get Effective Directory Rights.
|
||||
* Coverage: present.
|
||||
* Request: SubFunction, SrcNameSpace, DstNameSpace,
|
||||
* SearchAttributes, ReturnInfoMask, NWHandlePathStruct.
|
||||
* Reply: rights information selected by ReturnInfoMask.
|
||||
* Current code delegates to nsp_get_eff_rights().
|
||||
*/
|
||||
{
|
||||
int destnamspace = (int) *(p+1);
|
||||
int searchattrib = (int) GET_16(p+2); /* LOW-HI */
|
||||
|
||||
Reference in New Issue
Block a user