// with a HandshakeEndMessage sent from the server to the
// client. If the method throws an exception, then a
// HandshakeErrorMessage will be sent instead.
//
List profileNames = getProfilesByName(mc);
CheckProfiles np = (CheckProfiles)
env.get("com.sun.jmx.remote.profile.checker");
if (np != null) {
np.checkProfiles(env,
profileNames,
ccontext,
connectionId);
} else {
checkProfilesForEquality(serverProfiles,