Servers can export binding information (and interface identifiers) or objects or both by calling the rpc_ns_binding_export( ) routine. To export binding information associated with a given RPC interface, a server uses an interface handle. The interface handle is created by the IDL compiler as a reference to information about the interface that the compiler stores in an interface specification.
To refer to binding information, the application code obtains a list of server binding handles from the RPC runtime and passes the list to the export operation. The list contains binding handles for all the protocol sequence and endpoint combinations that the server has requested; it does this by calling the use-protocol-sequence operations. However, the server can remove any of those binding handles from the list before exporting it. This enables a server to export the binding information associated with a subset of its binding handles.
To export object UUIDs, a server application must provide a list of object UUIDs for the RPC objects it offers. The server can generate these object UUIDs itself or obtain them from some application-specific source such as an object-UUID database. All object UUIDs in a given server entry are associated with every interface UUID and server address in the entry.
The following figure illustrates how server binding handles in the application code refer to server binding information in the runtime, which is exported to the name service.
Exporting Server Binding Information
A server entry must belong exclusively to a server running on a given host. If there are identical, interchangeable instances of a server on the host, they can share a single set of server entries. However, if clients need to distinguish between coexisting instances of a server (for example, when each offers a different RPC object), each instance requires its own server entry.
Note: CDS databases are subject to access control. To access entries in a CDS database, you need access control list (ACL) permissions. Depending on the NSI operation, you need ACL permissions to the parent directory, the CDS object entry, or both. If you need ACL permissions, see your CDS administrator.
The ACL permissions are as follows:
· To create an entry, you need insert permission to the parent directory.
· To read an entry, you need read permission to the CDS object entry.
· To write to an entry, you need write permission to the CDS object entry.
· To delete an entry, you need delete permission either to the CDS object entry or to the parent directory.
· To test an entry, you need either test permission or read permission to the CDS object entry.
Note that write permission does not imply read permission.