Novell Home

TID102107 (XNCPEXT1) - Client version of NCP Extension written in Delphi

From Developer Community

ABSTRACT:

A Delphi application that accesses an NLM that is registered as an NCP Extension.

DETAILED DESCRIPTION

  • See XNCPExt2 for the NLM code *

The client application opens a connection and requests the NCP Ext which is written as an NLM. If the request is successful (the NLM must be loaded on the server the client is connected to) than the client sends a request buffer whose structure is determined by the NLM. In this case the NLM is just expecting an array whose first byte is one of the following options: 1 - Requesting a buffer that gives a why ask why question. 2 - Requesting information about all the mounted volumes on the server. 3 - Requesting to grep on the server using jgrep (a utility written by Adam Jerome). For the first request the NLM simply sends a reply (also in an array) containing a random quote. For the second request the NLM calls NWScanMountedVolumeList() which returns all the mounted volumes on the server. For the third request the server would need the search string, path, and wild card characters. The server would then read all the files within the given path and returns the line number and name of the file the search string was found in. Notice that the NCP request can be made several times with only one connection. Also notice that only a request and a reply is sent accross the wire, greatly reducing traffic.

xncpext1.exe

xncpext1.exe215.5 K2005-04-06

--Benjamin Fjeldsted

Novell® Making IT Work As One

© 2008 Novell, Inc. All Rights Reserved.