Incorporating Legacy Services
Legacy services are network services that predate the development and implementation of SLP. Solaris services such as the line printer daemon (lpsched), the NFS file service, and NIS/NIS+ name service, for example, do not contain internal SAs for SLP. This chapter describes when and how to advertise legacy services.
When to Advertise Legacy Services
With legacy service advertising, you can enable the SLP UAs to find devices and services such as the following on your network:
Hardware devices and software services that do that do not contain SLP SAs. When applications with SLP UAs need to find printers or databases that do not contain SLP SAs, for example, legacy advertising might be required.
Advertising Legacy Services
You use any of the following methods to advertise legacy services.
Modify the service to incorporate an SLP SA.
Write a small program that advertises on behalf of a service that is not SLP enabled.
Modifying the Service
If the source code for the software server is available, you can incorporate a SLP SA. The C and Java APIs for SLP are relatively straightforward to use. See the man pages for information on the C API and documentation on the Java API. If the service is a hardware device, the manufacturer might have an updated PROM that incorporates SLP. Contact the device manufacturer for more information.
Advertising a Service That Is Not SLP Enabled
If the source code or an updated PROM that contains SLP is not available, you can write a small application that uses the SLP client library to advertise the service. This application could function as a small daemon that you start or stop from the same shell script you use to start and stop the service.
SLP Proxy Registration
How to Enable SLP Proxy Registration
Determine if a service type template exists for the service.
The template is a description of the service URL and attributes of a service type. A template is used to define the components of an advertisement for a particular service type:
If a service type template exists, use the template to construct the proxy registration. See RFC 2609 for more information on service-type templates.
If a service type template is not available for the service, select a collection of attributes that precisely describe the service. Use a naming authority other than the default for the advertisement. The default naming authority is allowed only for service types that have been standardized. See RFC 2609 for more information on naming authorities.
For example, suppose a company that is called BizApp has a local database that is used to track software defects. To advertise the database, the company might use a URL with the service type service:bugdb.bizapp. The naming authority would then be bizapp.
Stop slpd and all SLP activity on the host.
Specify the location of the proxy registration file in the net.slp.serializedRegURL property of the /etc/inet/slp.conf file.
net.slp.net.slp.serializedRegURL=proxy registration file URL
For example, if the serialized registration file is /net/inet/slp.reg, you configure the property as shown in the following:
Save your changes and close the file.
Restart slpd to activate your changes.
Using SLP Proxy Registration to Advertise
A service advertisement consists of lines that identify the service URL, an optional scope, and a series of attribute definitions. The SLP daemon reads, registers, and maintains proxy advertisements exactly as an SA client would. The following is an example of an advertisement from a proxy registration file.
In the example, a legacy printer that supports LPR protocol and an FTP server are advertised. Line numbers have been added for description purposes and are not part of the file.
1#Advertise legacy printer. 2 3service:lpr://bizserver/mainspool,en,65535 4scope=eng,corp 5make-model=Laserwriter II 6location-description=B16-2345 7color-supported=monochromatic 8fonts-supported=Courier,Times,Helvetica 9 10 9 10#Advertise FTP server 11 12ftp://archive/usr/src/public,en,65535,src-server 13content=Source code for projects 14
Note - The proxy registration file supports the same convention for escaping non-ASCII characters as the configuration file does. For more information about the format of the proxy registration file, see RFC 2614.
Table 21-1 SLP Proxy Registration File Description