SSLService specifies an interface to manage global SSL properties for a client component only.
Only one instance of the component needs to be instantiated. The URL string to instantiate the component is "SSLServiceProvider". After initializing the ORB, call the ORB.resolve_initial_references method to obtain the SSLServiceProvider context. The context is an object that implements the CtsSecurity::SSLService IDL interface. The context is used to set and get global SSL properties. Properties may be set only once.
Server components do not have permission to get the context. Only clients can get the context and configure the SSLServiceProvider. The EAServer server obtains the SSLServiceProvider context and sets global defaults. Server components can override "certificateLabel", "qop", and "pin" properties at the ORB level if the defaults are not acceptable.
Here is the Java sample code to obtain the global SSLServiceProvider context.
...
Properties props = new Properties();
props.put("org.omg.CORBA.ORBClass", "com.sybase.CORBA.ORB");
ORB orb = ORB.init(args, props);
SSLServiceProvider sslServiceProv = null;
org.omg.CORBA.object objRef = null;
try {
objRef = orb.resolve_initial_references("SSLServiceProvider");
sslServiceProv = SSLServiceProviderHelper.narrow(objRef);
catch (org.omg.CORBA.NO_PERMISSION np)
{
// do not have permission
to get the context if we are a server component instance.
}
// get and set properties now.
...
Here is the C++ sample code to get the global SSLProvider context..
...
CORBA::ORB_var orb = CORBA::ORB_init(argc, argv,
"");
CORBA::Object_var objRef;
CtsSecurity::SSLServiceProvider_var sslServiceProvider;
try {
objRef = orb->resolve_initial_references("SSLServiceProvider");
sslServiceProvider = CtsSecurity::SSLService::_narrow(objRef);
} catch (CORBA::NO_PERMISSION& np)
{
 
// if we are within the server, we
have no permission to retrieve the context.
}
// Now get and set the properties.
...
Returns value of any of the SSL global properties listed below (refer to Table. EAServer Security - SSL Properties for detailed descriptions).
Property |
---|
callbackImpl |
certificateLabel |
qop |
cacheSize |
SessLingerTime |
SessShareCount |
loginTimeout |
availableQop |
availableQopDesc |
availableVersions |
entrustReady |
userdata |
entrustIniFile |
entrustUserProfile |
useEntrustId |
CtsSecurity::StringSeq getGlobalProperty ( in string property ) raises (CtsSecurity::InvalidPropertyException);
Sets value of SSL property (with application wide scope) and returns the previous value of the property.
These settings will be used to establish a SSL session if
not overriden at the ORB level. Following properties are supported by this method (refer to Table. EAServer Security - SSL Properties for detailed descriptions).
Property |
---|
callbackImpl |
certificateLabel |
qop |
cacheSize |
SessLingerTime |
SessShareCount |
loginTimeout |
pin |
userdata |
entrustIniFile |
entrustUserProfile |
useEntrustId |
entrustPassword |
string setGlobalProperty ( in string property, in string value ) raises (CtsSecurity::InvalidPropertyException, CtsSecurity::InvalidValueException);