The CreateBootstrapFile method generates a bootstrap file that the Policy Server can use for connecting to a v5.x agent. The bootstrap file contains the settings specified by the method's parameters. Once the connection is made, the Policy Server can provide the remaining settings. SmHost.conf is an example of a bootstrap file.
Syntax
The CreateBootstrapFile method has the following format:
Netegrity::AgentAPI‑>CreateBootstrapFile(trustedHostName, ipAddress, hostConfigName, sharedSecret, registrationDataFileName)
Parameters
The CreateBootstrapFile method accepts the following parameters:
trustedHostName (string)
Specifies the name of the trusted host.
ipAddress (string)
Specifies the IP address of the Policy Server.
hostConfigName (string)
Specifies the name of the host configuration object.
sharedSecret (string)
Specifies the value of the shared secret used by the host.
registrationDataFileName (string)
Specifies the name of the bootstrap file generated by the method.
Return Value
The CreateBootstrapFile method returns one of the following values:
Specifies the name of the newly-created file.
Specifies that the method failed.
Example
The following code fragment is an example of how to use the CreateBootstrapFile method:
# A shared secret is not specified in the context of a v5.x agent. # A v5.x agent by the specified name needs to exist in the policy # store. Use Netegrity::AgentAPI. $agentapi = Netegrity::AgentAPI‑>New($agentname); # Create the bootstrap file. $agentapi‑>CreateBootstrapFile($thostname, $ipaddr, $hconfname, $secret, $fname); # Notice that in the v5.x context, the connect() method takes a filename. $agentapi‑>Connect($fname);
Copyright © 2010 CA. All rights reserved. | Email CA about this topic |